Native Android client for Spotify, built with Jetpack Compose
Kotlin ad-freeadblockandroidjetpack-composekotlinlyricsmusic-playermusic-videomyspotispotifyspotify-adblockerspotify-clientspotify-connectspotui
Myspoti 2.0.0
kota-zo6b9252d9b399
diff --git a/.github/FUNDING.yml b/.github/FUNDING.ymlnew file mode 100644index 00000000..588a83ee--- /dev/null+++ b/.github/FUNDING.yml@@ -0,0 +1,2 @@+# Donation links shown by GitHub's "Sponsor" button.+ko_fi: kotazodiff --git a/.github/workflows/android.yml b/.github/workflows/android.ymlnew file mode 100644index 00000000..c6786180--- /dev/null+++ b/.github/workflows/android.yml@@ -0,0 +1,119 @@+# Builds and tests every push / pull request; a "v*" tag publishes a signed APK+# as a GitHub release (the app's update check reads those releases).+name: Android++on:+ push:+ branches: [master, main]+ tags: ["v*"]+ pull_request:++permissions:+ contents: read++defaults:+ run:+ working-directory: base++jobs:+ build:+ runs-on: ubuntu-latest+ steps:+ - uses: actions/checkout@v7++ - uses: actions/setup-java@v6+ with:+ distribution: temurin+ java-version: "21"++ - uses: android-actions/setup-android@v4+ with:+ packages: "platforms;android-37.0 build-tools;36.0.0"++ - uses: gradle/actions/setup-gradle@v6++ - name: Unit tests+ run: ./gradlew testDebugUnitTest++ - name: Debug APK+ if: ${{ !startsWith(github.ref, 'refs/tags/v') }}+ run: ./gradlew assembleDebug++ - uses: actions/upload-artifact@v7+ if: ${{ !startsWith(github.ref, 'refs/tags/v') }}+ with:+ name: myspoti-debug+ path: base/app/build/outputs/apk/debug/*.apk+ retention-days: 14++ release:+ if: startsWith(github.ref, 'refs/tags/v')+ needs: build+ runs-on: ubuntu-latest+ permissions:+ contents: write+ steps:+ - uses: actions/checkout@v7++ - uses: actions/setup-java@v6+ with:+ distribution: temurin+ java-version: "21"++ - uses: android-actions/setup-android@v4+ with:+ packages: "platforms;android-37.0 build-tools;36.0.0"++ - uses: gradle/actions/setup-gradle@v6++ # Secrets: MYSPOTI_KEYSTORE_BASE64 (base64 of the .jks), MYSPOTI_KEYSTORE_PASSWORD,+ # MYSPOTI_KEY_ALIAS, MYSPOTI_KEY_PASSWORD. Keep the same key for every release,+ # or installed apps cannot update.+ - name: Signing key+ env:+ KEYSTORE_BASE64: ${{ secrets.MYSPOTI_KEYSTORE_BASE64 }}+ run: |+ test -n "$KEYSTORE_BASE64" || { echo "::error::MYSPOTI_KEYSTORE_BASE64 secret missing"; exit 1; }+ echo "$KEYSTORE_BASE64" | base64 -d > "$RUNNER_TEMP/release.jks"++ - name: Release APK+ env:+ MYSPOTI_KEYSTORE: ${{ runner.temp }}/release.jks+ MYSPOTI_KEYSTORE_PASSWORD: ${{ secrets.MYSPOTI_KEYSTORE_PASSWORD }}+ MYSPOTI_KEY_ALIAS: ${{ secrets.MYSPOTI_KEY_ALIAS }}+ MYSPOTI_KEY_PASSWORD: ${{ secrets.MYSPOTI_KEY_PASSWORD }}+ run: |+ VERSION="${GITHUB_REF_NAME#v}"+ ./gradlew assembleRelease \+ -PappVersionName="$VERSION" \+ -PappVersionCode="$((1000 + GITHUB_RUN_NUMBER))" \+ -PupdateRepo="$GITHUB_REPOSITORY"+ mv app/build/outputs/apk/release/app-release.apk "app/build/outputs/apk/release/myspoti-$VERSION.apk"++ # This version's section of CHANGELOG.md becomes the release description.+ - name: Release notes+ run: |+ VERSION="${GITHUB_REF_NAME#v}"+ awk -v v="$VERSION" '$0 == "## " v {f=1; next} /^## / && f {exit} f' ../CHANGELOG.md > release-notes.md+ # A beta without its own section uses the section of the version it leads to.+ [ -s release-notes.md ] || awk -v v="${VERSION%%-*}" '$0 == "## " v {f=1; next} /^## / && f {exit} f' ../CHANGELOG.md > release-notes.md+ [ -s release-notes.md ] || echo "See the commits since the previous release." > release-notes.md+ cat release-notes.md++ - uses: softprops/action-gh-release@v3+ with:+ files: base/app/build/outputs/apk/release/myspoti-*.apk+ body_path: base/release-notes.md+ generate_release_notes: true+ # "v2.0.0-beta.1": a pre-release, offered only to beta builds.+ prerelease: ${{ contains(github.ref_name, '-') }}++ # Announces the release on Discord (secret DISCORD_WEBHOOK_URL; nothing posted without it).+ # A release created with GITHUB_TOKEN triggers no other workflow, hence this step here.+ - name: Discord announcement+ continue-on-error: true+ working-directory: .+ env:+ DISCORD_WEBHOOK_URL: ${{ secrets.DISCORD_WEBHOOK_URL }}+ GITHUB_TOKEN: ${{ github.token }}+ run: python3 tools/discord_release.py "$GITHUB_REF_NAME"diff --git a/.github/workflows/discord.yml b/.github/workflows/discord.ymlnew file mode 100644index 00000000..f6fe51ce--- /dev/null+++ b/.github/workflows/discord.yml@@ -0,0 +1,27 @@+# Posts (or re-posts) a release's announcement on Discord, by hand: Actions > Discord+# announcement > Run workflow. Releases published by the Android workflow announce+# themselves; this one is for an older release or a second try.+name: Discord announcement++on:+ workflow_dispatch:+ inputs:+ tag:+ description: "Release tag, e.g. v1.0.5 (empty = the latest release)"+ required: false+ default: ""++permissions:+ contents: read++jobs:+ announce:+ runs-on: ubuntu-latest+ steps:+ - uses: actions/checkout@v7+ - name: Discord announcement+ env:+ DISCORD_WEBHOOK_URL: ${{ secrets.DISCORD_WEBHOOK_URL }}+ GITHUB_TOKEN: ${{ github.token }}+ TAG: ${{ inputs.tag }}+ run: python3 tools/discord_release.py "$TAG"diff --git a/.gitignore b/.gitignorenew file mode 100644index 00000000..0055d0ed--- /dev/null+++ b/.gitignore@@ -0,0 +1,14 @@+# build outputs+build/+.gradle/+.kotlin/+*.apk+*.zip+dist/+local.properties+# device captures (logs can contain session data)+tools/captures/+base/tools/captures/+__pycache__/+.idea/+PROMPT-*.mddiff --git a/CHANGELOG.md b/CHANGELOG.mdnew file mode 100644index 00000000..11a015fb--- /dev/null+++ b/CHANGELOG.md@@ -0,0 +1,101 @@+# Changelog++Each release on GitHub shows its section below. The app shows it too when it offers the update.++## 2.0.0++A new engine, written from scratch, and a cleaner app on top of it.++- **New engine**: the app now talks to Spotify through its own API (`:api`), tested against the real Web Player on every change. Screens load faster: catalog, search, playlists and library come straight from Spotify's servers, in parallel, without waiting for the hidden player.+- **Playback works again on every phone**: Spotify silently ignored play commands sent by an Android WebView. They now leave from the app itself, so songs start and the sound plays.+- **Faster start**: the home feed, your library and Liked Songs show at once after a restart, from the last visit, then refresh. The library and Liked Songs load in the background as soon as Spotify is ready.+- **The player closes into the mini player**: pulled down, it uncovers the page you were on, with the mini player and the tabs already in place (no more grey area).+- **Right music videos**: a fan upload (lyrics, sped up, audio) is no longer taken for the artist's clip, even when YouTube Music files it as official. When in doubt, no clip.+- **Home screen widget** (4x1): the current song with previous, play / pause and next.+- **Songs no longer skipped in a partly downloaded list**: some networks (VPN, private DNS) made the app think it was offline, so only the downloaded songs played (#10). Offline, a message now says how many songs of the list are downloaded.+- The **Account** row in Your Library opens your Spotify account page (#7).+- **Playback goes on with the screen off**: the app no longer leaves the foreground between two songs, so Android stops freezing it after the first song.+- **Switching accounts works**: after a logout, signing in with another account shows that account, not the previous one.+- **Sort by** in playlists and Liked Songs: title, artist, album or duration.+- **Spotify keeps working after its updates**: the app picks up the Web Player's new operations by itself when Spotify ships a new version.+- **No ads**: the ad audio is refused, so the player skips the ad within a second, and nothing false is reported to Spotify.+- **Podcasts and audiobooks are back**: shows, episodes, chapters, **Your Episodes** in Your Library, and **playback speed** (from the song menu) for episodes.+- **New releases** in Search: what the artists you follow just released, then the latest releases.+- **Browse all** shows Spotify's real categories (pages of playlists and albums), not keyword searches.+- **Jam** in the Connect sheet: join a Jam with an invite link, share and leave. Spotify keeps starting one to Premium accounts.+- **Your recap** (profile menu): your top tracks, artists and albums over 30 days, 12 months or all time, counting Spotify, downloads and local files. It stays on the phone.+- **Spotify account** (profile menu): the account pages (plan, privacy, devices) open in the app, already signed in.+- **Song menu**: **Credits**, and **Exclude from your taste profile**.+- **More lyrics sources** (lyrics settings): Apple Music word by word, NetEase and Genius, when Spotify has no lyrics.+- **Fixes**: your top artists and tracks, the profile and new releases no longer fail when Spotify's public API limits the app; folders keep working after a rename; playlist details save reliably; the app language works on every Android version.+- **Removed for now**: crossfade, and Spotify's own music videos inside the player (YouTube clips still play).++## 1.1.1++- **Data saver** (profile menu): on mobile data Myspoti uses no data at all. Only downloaded songs and Local Files play, downloads wait for Wi-Fi, and the Spotify player comes back on its own on Wi-Fi.+- **Find in a list**: search inside Liked Songs, a playlist or Local Files (title, artist or album).+- **Your Library**: moving a playlist (hold, then drag) works, in the list and in the grid; the drag stopped as soon as it started.+- **Settings** open in full, so the list scrolls without moving the sheet.++## 1.1.0++- **Downloads**: download a song (from its menu), an album, a playlist or Liked Songs, and listen without a connection, from **Downloaded** in Your Library or from the album or playlist page.+ - The audio comes from YouTube Music, as YouTube serves it (no re-encoding). Each song is checked against the original recording; when none matches, the song is marked as not downloadable instead of saving the wrong one.+ - Files stay inside Myspoti. A downloaded album or playlist stays in step: songs added to it are downloaded, songs that left it (a renewed Blend, a removed song) are deleted, unless another downloaded list or your own download keeps them.+ - Once a list is downloaded, its button becomes a bin. In Downloaded, swipe a song from right to left to remove it, or remove everything from the profile menu.+- **Folders**: Your Library shows your Spotify folders and opens them level by level. The + at the top creates a playlist, a folder (a real Spotify folder) or a playlist on this device; a folder can be renamed.+- **Sort and reorder Your Library**: sort by custom order, alphabetical or creator; hold a playlist, then drag it to move it (kept on this phone). Liked Songs, Local Files and Downloaded stay on top.+- **Local files in playlists**: the + of a song in Local Files adds it to a playlist on this device, or to one of your Spotify playlists, under **Added on this device** (Spotify can't receive phone files, so they stay on the phone).+- **The + of a song**: the first tap saves it in Liked Songs; tapping the green check then opens **Saved in** to add it to your playlists. Saved in only lists the playlists you can change, and says so when Spotify refuses a change.+- **Player**: pull it down from the top to close it, like the back button.+- **Go to song radio** in every song's menu (player, search, playlists…).+- **Music videos**: a title with an apostrophe ("J'SAVAIS") no longer gets the clip of another song; instrumental uploads are skipped.+- **Home** in the bottom bar always opens Home.+- **Search**: playlists in the results, and filters for songs, artists, albums and playlists.+- **Podcasts and audiobooks are hidden for now**; they will come back in a later version.+- **Artist pages**: the whole discography, not only the releases Spotify highlights.+- **Language**: French on a French phone, English on any other, with no more mixed languages. **App language** in the profile menu picks another one (Spotify's labels are translated, Myspoti's own texts stay in English).+- **Steadier and lighter player**: the hidden Spotify player stays on a tested version kept on the phone, so a Spotify website update can no longer break the app overnight, and it no longer loads covers, Canvas loops and fonts nobody sees (about half the memory and a quarter of the requests at startup).+- **Restart the player** in the profile menu, for when the music stops responding.+- **Battery saver**: Myspoti's own saver is independent of Android's (which already lowers the screen rate) and only follows its switch. The AMOLED theme is its own choice too, and returning to the app no longer looks up a music video for nothing.+- **Crossfade**: no background work when it is off, and the setting is kept when the player reloads.+- **About** in the profile menu: the version, the [Discord server](https://discord.gg/jXKnGVFnGS) and the source code.+- **Support Myspoti**: Myspoti is free and has no ads; you can now support it on Ko-fi from the profile menu or About. A short reminder appears a day after installing this version, then every 2 weeks; "No thanks" closes it, and nothing is locked behind a donation.+- New versions are checked every 3 hours instead of once a day.+- Your Library still opens Local Files and Downloaded without a connection, and the notification shows the cover of local and downloaded songs.++## 1.0.4++- **Local Files**: a folder in Your Library, right under Liked Songs, with the music stored on your phone. It plays in the app like the rest (player, mini player, notification, lock screen, headset buttons).+- **Spotify Connect**: the notification now follows track changes on the other device; it could stay on the previous song.+- Fewer updates from the player while it plays on another device (less CPU and battery).+- No like button on local files.+- One more Spotify ad server blocked.+- The update window shows what's new.++## 1.0.3++- **Spotify Connect**: music no longer jumps back to the phone or stops by itself.+ - Playing from Liked Songs goes to the device that is actually playing.+ - Swiping the app away no longer pauses a Connect device.+ - A Connect session closed by the system no longer pulls playback back to the phone.+- **Crossfade** (Settings, 0–12 s): the end of a track fades out and the next one fades in.+- **Background playback**: Myspoti asks once to lift battery optimization, so music and Connect keep going with the screen off. Also in Settings.+- **Android Auto** works again: Liked Songs, playlists, albums, artists, search and voice play.+- **Android 10 and 11** are supported.+- The update window matches the app's style.++## 1.0.2++- New welcome screen before signing in, and a new crash screen.+- Every screen follows the phone's language (official labels in 73 languages, English and French for Myspoti's own texts).+- New icons, new notification icon, older screens removed.++## 1.0.1++- **Spotify Connect**: the notification keeps following the other device with the screen off.+- Reopening the app no longer moves playback back to the phone.++## 1.0.0++- First release: Spotify with a free account and no ads, native interface, synced lyrics, official music videos, Spotify Connect.diff --git a/LICENSE b/LICENSEnew file mode 100644index 00000000..f288702d--- /dev/null+++ b/LICENSE@@ -0,0 +1,674 @@+ GNU GENERAL PUBLIC LICENSE+ Version 3, 29 June 2007++ Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>+ Everyone is permitted to copy and distribute verbatim copies+ of this license document, but changing it is not allowed.++ Preamble++ The GNU General Public License is a free, copyleft license for+software and other kinds of works.++ The licenses for most software and other practical works are designed+to take away your freedom to share and change the works. By contrast,+the GNU General Public License is intended to guarantee your freedom to+share and change all versions of a program--to make sure it remains free+software for all its users. We, the Free Software Foundation, use the+GNU General Public License for most of our software; it applies also to+any other work released this way by its authors. You can apply it to+your programs, too.++ When we speak of free software, we are referring to freedom, not+price. Our General Public Licenses are designed to make sure that you+have the freedom to distribute copies of free software (and charge for+them if you wish), that you receive source code or can get it if you+want it, that you can change the software or use pieces of it in new+free programs, and that you know you can do these things.++ To protect your rights, we need to prevent others from denying you+these rights or asking you to surrender the rights. Therefore, you have+certain responsibilities if you distribute copies of the software, or if+you modify it: responsibilities to respect the freedom of others.++ For example, if you distribute copies of such a program, whether+gratis or for a fee, you must pass on to the recipients the same+freedoms that you received. You must make sure that they, too, receive+or can get the source code. And you must show them these terms so they+know their rights.++ Developers that use the GNU GPL protect your rights with two steps:+(1) assert copyright on the software, and (2) offer you this License+giving you legal permission to copy, distribute and/or modify it.++ For the developers' and authors' protection, the GPL clearly explains+that there is no warranty for this free software. For both users' and+authors' sake, the GPL requires that modified versions be marked as+changed, so that their problems will not be attributed erroneously to+authors of previous versions.++ Some devices are designed to deny users access to install or run+modified versions of the software inside them, although the manufacturer+can do so. This is fundamentally incompatible with the aim of+protecting users' freedom to change the software. The systematic+pattern of such abuse occurs in the area of products for individuals to+use, which is precisely where it is most unacceptable. Therefore, we+have designed this version of the GPL to prohibit the practice for those+products. If such problems arise substantially in other domains, we+stand ready to extend this provision to those domains in future versions+of the GPL, as needed to protect the freedom of users.++ Finally, every program is threatened constantly by software patents.+States should not allow patents to restrict development and use of+software on general-purpose computers, but in those that do, we wish to+avoid the special danger that patents applied to a free program could+make it effectively proprietary. To prevent this, the GPL assures that+patents cannot be used to render the program non-free.++ The precise terms and conditions for copying, distribution and+modification follow.++ TERMS AND CONDITIONS++ 0. Definitions.++ "This License" refers to version 3 of the GNU General Public License.++ "Copyright" also means copyright-like laws that apply to other kinds of+works, such as semiconductor masks.++ "The Program" refers to any copyrightable work licensed under this+License. Each licensee is addressed as "you". "Licensees" and+"recipients" may be individuals or organizations.++ To "modify" a work means to copy from or adapt all or part of the work+in a fashion requiring copyright permission, other than the making of an+exact copy. The resulting work is called a "modified version" of the+earlier work or a work "based on" the earlier work.++ A "covered work" means either the unmodified Program or a work based+on the Program.++ To "propagate" a work means to do anything with it that, without+permission, would make you directly or secondarily liable for+infringement under applicable copyright law, except executing it on a+computer or modifying a private copy. Propagation includes copying,+distribution (with or without modification), making available to the+public, and in some countries other activities as well.++ To "convey" a work means any kind of propagation that enables other+parties to make or receive copies. Mere interaction with a user through+a computer network, with no transfer of a copy, is not conveying.++ An interactive user interface displays "Appropriate Legal Notices"+to the extent that it includes a convenient and prominently visible+feature that (1) displays an appropriate copyright notice, and (2)+tells the user that there is no warranty for the work (except to the+extent that warranties are provided), that licensees may convey the+work under this License, and how to view a copy of this License. If+the interface presents a list of user commands or options, such as a+menu, a prominent item in the list meets this criterion.++ 1. Source Code.++ The "source code" for a work means the preferred form of the work+for making modifications to it. "Object code" means any non-source+form of a work.++ A "Standard Interface" means an interface that either is an official+standard defined by a recognized standards body, or, in the case of+interfaces specified for a particular programming language, one that+is widely used among developers working in that language.++ The "System Libraries" of an executable work include anything, other+than the work as a whole, that (a) is included in the normal form of+packaging a Major Component, but which is not part of that Major+Component, and (b) serves only to enable use of the work with that+Major Component, or to implement a Standard Interface for which an+implementation is available to the public in source code form. A+"Major Component", in this context, means a major essential component+(kernel, window system, and so on) of the specific operating system+(if any) on which the executable work runs, or a compiler used to+produce the work, or an object code interpreter used to run it.++ The "Corresponding Source" for a work in object code form means all+the source code needed to generate, install, and (for an executable+work) run the object code and to modify the work, including scripts to+control those activities. However, it does not include the work's+System Libraries, or general-purpose tools or generally available free+programs which are used unmodified in performing those activities but+which are not part of the work. For example, Corresponding Source+includes interface definition files associated with source files for+the work, and the source code for shared libraries and dynamically+linked subprograms that the work is specifically designed to require,+such as by intimate data communication or control flow between those+subprograms and other parts of the work.++ The Corresponding Source need not include anything that users+can regenerate automatically from other parts of the Corresponding+Source.++ The Corresponding Source for a work in source code form is that+same work.++ 2. Basic Permissions.++ All rights granted under this License are granted for the term of+copyright on the Program, and are irrevocable provided the stated+conditions are met. This License explicitly affirms your unlimited+permission to run the unmodified Program. The output from running a+covered work is covered by this License only if the output, given its+content, constitutes a covered work. This License acknowledges your+rights of fair use or other equivalent, as provided by copyright law.++ You may make, run and propagate covered works that you do not+convey, without conditions so long as your license otherwise remains+in force. You may convey covered works to others for the sole purpose+of having them make modifications exclusively for you, or provide you+with facilities for running those works, provided that you comply with+the terms of this License in conveying all material for which you do+not control copyright. Those thus making or running the covered works+for you must do so exclusively on your behalf, under your direction+and control, on terms that prohibit them from making any copies of+your copyrighted material outside their relationship with you.++ Conveying under any other circumstances is permitted solely under+the conditions stated below. Sublicensing is not allowed; section 10+makes it unnecessary.++ 3. Protecting Users' Legal Rights From Anti-Circumvention Law.++ No covered work shall be deemed part of an effective technological+measure under any applicable law fulfilling obligations under article+11 of the WIPO copyright treaty adopted on 20 December 1996, or+similar laws prohibiting or restricting circumvention of such+measures.++ When you convey a covered work, you waive any legal power to forbid+circumvention of technological measures to the extent such circumvention+is effected by exercising rights under this License with respect to+the covered work, and you disclaim any intention to limit operation or+modification of the work as a means of enforcing, against the work's+users, your or third parties' legal rights to forbid circumvention of+technological measures.++ 4. Conveying Verbatim Copies.++ You may convey verbatim copies of the Program's source code as you+receive it, in any medium, provided that you conspicuously and+appropriately publish on each copy an appropriate copyright notice;+keep intact all notices stating that this License and any+non-permissive terms added in accord with section 7 apply to the code;+keep intact all notices of the absence of any warranty; and give all+recipients a copy of this License along with the Program.++ You may charge any price or no price for each copy that you convey,+and you may offer support or warranty protection for a fee.++ 5. Conveying Modified Source Versions.++ You may convey a work based on the Program, or the modifications to+produce it from the Program, in the form of source code under the+terms of section 4, provided that you also meet all of these conditions:++ a) The work must carry prominent notices stating that you modified+ it, and giving a relevant date.++ b) The work must carry prominent notices stating that it is+ released under this License and any conditions added under section+ 7. This requirement modifies the requirement in section 4 to+ "keep intact all notices".++ c) You must license the entire work, as a whole, under this+ License to anyone who comes into possession of a copy. This+ License will therefore apply, along with any applicable section 7+ additional terms, to the whole of the work, and all its parts,+ regardless of how they are packaged. This License gives no+ permission to license the work in any other way, but it does not+ invalidate such permission if you have separately received it.++ d) If the work has interactive user interfaces, each must display+ Appropriate Legal Notices; however, if the Program has interactive+ interfaces that do not display Appropriate Legal Notices, your+ work need not make them do so.++ A compilation of a covered work with other separate and independent+works, which are not by their nature extensions of the covered work,+and which are not combined with it such as to form a larger program,+in or on a volume of a storage or distribution medium, is called an+"aggregate" if the compilation and its resulting copyright are not+used to limit the access or legal rights of the compilation's users+beyond what the individual works permit. Inclusion of a covered work+in an aggregate does not cause this License to apply to the other+parts of the aggregate.++ 6. Conveying Non-Source Forms.++ You may convey a covered work in object code form under the terms+of sections 4 and 5, provided that you also convey the+machine-readable Corresponding Source under the terms of this License,+in one of these ways:++ a) Convey the object code in, or embodied in, a physical product+ (including a physical distribution medium), accompanied by the+ Corresponding Source fixed on a durable physical medium+ customarily used for software interchange.++ b) Convey the object code in, or embodied in, a physical product+ (including a physical distribution medium), accompanied by a+ written offer, valid for at least three years and valid for as+ long as you offer spare parts or customer support for that product+ model, to give anyone who possesses the object code either (1) a+ copy of the Corresponding Source for all the software in the+ product that is covered by this License, on a durable physical+ medium customarily used for software interchange, for a price no+ more than your reasonable cost of physically performing this+ conveying of source, or (2) access to copy the+ Corresponding Source from a network server at no charge.++ c) Convey individual copies of the object code with a copy of the+ written offer to provide the Corresponding Source. This+ alternative is allowed only occasionally and noncommercially, and+ only if you received the object code with such an offer, in accord+ with subsection 6b.++ d) Convey the object code by offering access from a designated+ place (gratis or for a charge), and offer equivalent access to the+ Corresponding Source in the same way through the same place at no+ further charge. You need not require recipients to copy the+ Corresponding Source along with the object code. If the place to+ copy the object code is a network server, the Corresponding Source+ may be on a different server (operated by you or a third party)+ that supports equivalent copying facilities, provided you maintain+ clear directions next to the object code saying where to find the+ Corresponding Source. Regardless of what server hosts the+ Corresponding Source, you remain obligated to ensure that it is+ available for as long as needed to satisfy these requirements.++ e) Convey the object code using peer-to-peer transmission, provided+ you inform other peers where the object code and Corresponding+ Source of the work are being offered to the general public at no+ charge under subsection 6d.++ A separable portion of the object code, whose source code is excluded+from the Corresponding Source as a System Library, need not be+included in conveying the object code work.++ A "User Product" is either (1) a "consumer product", which means any+tangible personal property which is normally used for personal, family,+or household purposes, or (2) anything designed or sold for incorporation+into a dwelling. In determining whether a product is a consumer product,+doubtful cases shall be resolved in favor of coverage. For a particular+product received by a particular user, "normally used" refers to a+typical or common use of that class of product, regardless of the status+of the particular user or of the way in which the particular user+actually uses, or expects or is expected to use, the product. A product+is a consumer product regardless of whether the product has substantial+commercial, industrial or non-consumer uses, unless such uses represent+the only significant mode of use of the product.++ "Installation Information" for a User Product means any methods,+procedures, authorization keys, or other information required to install+and execute modified versions of a covered work in that User Product from+a modified version of its Corresponding Source. The information must+suffice to ensure that the continued functioning of the modified object+code is in no case prevented or interfered with solely because+modification has been made.++ If you convey an object code work under this section in, or with, or+specifically for use in, a User Product, and the conveying occurs as+part of a transaction in which the right of possession and use of the+User Product is transferred to the recipient in perpetuity or for a+fixed term (regardless of how the transaction is characterized), the+Corresponding Source conveyed under this section must be accompanied+by the Installation Information. But this requirement does not apply+if neither you nor any third party retains the ability to install+modified object code on the User Product (for example, the work has+been installed in ROM).++ The requirement to provide Installation Information does not include a+requirement to continue to provide support service, warranty, or updates+for a work that has been modified or installed by the recipient, or for+the User Product in which it has been modified or installed. Access to a+network may be denied when the modification itself materially and+adversely affects the operation of the network or violates the rules and+protocols for communication across the network.++ Corresponding Source conveyed, and Installation Information provided,+in accord with this section must be in a format that is publicly+documented (and with an implementation available to the public in+source code form), and must require no special password or key for+unpacking, reading or copying.++ 7. Additional Terms.++ "Additional permissions" are terms that supplement the terms of this+License by making exceptions from one or more of its conditions.+Additional permissions that are applicable to the entire Program shall+be treated as though they were included in this License, to the extent+that they are valid under applicable law. If additional permissions+apply only to part of the Program, that part may be used separately+under those permissions, but the entire Program remains governed by+this License without regard to the additional permissions.++ When you convey a copy of a covered work, you may at your option+remove any additional permissions from that copy, or from any part of+it. (Additional permissions may be written to require their own+removal in certain cases when you modify the work.) You may place+additional permissions on material, added by you to a covered work,+for which you have or can give appropriate copyright permission.++ Notwithstanding any other provision of this License, for material you+add to a covered work, you may (if authorized by the copyright holders of+that material) supplement the terms of this License with terms:++ a) Disclaiming warranty or limiting liability differently from the+ terms of sections 15 and 16 of this License; or++ b) Requiring preservation of specified reasonable legal notices or+ author attributions in that material or in the Appropriate Legal+ Notices displayed by works containing it; or++ c) Prohibiting misrepresentation of the origin of that material, or+ requiring that modified versions of such material be marked in+ reasonable ways as different from the original version; or++ d) Limiting the use for publicity purposes of names of licensors or+ authors of the material; or++ e) Declining to grant rights under trademark law for use of some+ trade names, trademarks, or service marks; or++ f) Requiring indemnification of licensors and authors of that+ material by anyone who conveys the material (or modified versions of+ it) with contractual assumptions of liability to the recipient, for+ any liability that these contractual assumptions directly impose on+ those licensors and authors.++ All other non-permissive additional terms are considered "further+restrictions" within the meaning of section 10. If the Program as you+received it, or any part of it, contains a notice stating that it is+governed by this License along with a term that is a further+restriction, you may remove that term. If a license document contains+a further restriction but permits relicensing or conveying under this+License, you may add to a covered work material governed by the terms+of that license document, provided that the further restriction does+not survive such relicensing or conveying.++ If you add terms to a covered work in accord with this section, you+must place, in the relevant source files, a statement of the+additional terms that apply to those files, or a notice indicating+where to find the applicable terms.++ Additional terms, permissive or non-permissive, may be stated in the+form of a separately written license, or stated as exceptions;+the above requirements apply either way.++ 8. Termination.++ You may not propagate or modify a covered work except as expressly+provided under this License. Any attempt otherwise to propagate or+modify it is void, and will automatically terminate your rights under+this License (including any patent licenses granted under the third+paragraph of section 11).++ However, if you cease all violation of this License, then your+license from a particular copyright holder is reinstated (a)+provisionally, unless and until the copyright holder explicitly and+finally terminates your license, and (b) permanently, if the copyright+holder fails to notify you of the violation by some reasonable means+prior to 60 days after the cessation.++ Moreover, your license from a particular copyright holder is+reinstated permanently if the copyright holder notifies you of the+violation by some reasonable means, this is the first time you have+received notice of violation of this License (for any work) from that+copyright holder, and you cure the violation prior to 30 days after+your receipt of the notice.++ Termination of your rights under this section does not terminate the+licenses of parties who have received copies or rights from you under+this License. If your rights have been terminated and not permanently+reinstated, you do not qualify to receive new licenses for the same+material under section 10.++ 9. Acceptance Not Required for Having Copies.++ You are not required to accept this License in order to receive or+run a copy of the Program. Ancillary propagation of a covered work+occurring solely as a consequence of using peer-to-peer transmission+to receive a copy likewise does not require acceptance. However,+nothing other than this License grants you permission to propagate or+modify any covered work. These actions infringe copyright if you do+not accept this License. Therefore, by modifying or propagating a+covered work, you indicate your acceptance of this License to do so.++ 10. Automatic Licensing of Downstream Recipients.++ Each time you convey a covered work, the recipient automatically+receives a license from the original licensors, to run, modify and+propagate that work, subject to this License. You are not responsible+for enforcing compliance by third parties with this License.++ An "entity transaction" is a transaction transferring control of an+organization, or substantially all assets of one, or subdividing an+organization, or merging organizations. If propagation of a covered+work results from an entity transaction, each party to that+transaction who receives a copy of the work also receives whatever+licenses to the work the party's predecessor in interest had or could+give under the previous paragraph, plus a right to possession of the+Corresponding Source of the work from the predecessor in interest, if+the predecessor has it or can get it with reasonable efforts.++ You may not impose any further restrictions on the exercise of the+rights granted or affirmed under this License. For example, you may+not impose a license fee, royalty, or other charge for exercise of+rights granted under this License, and you may not initiate litigation+(including a cross-claim or counterclaim in a lawsuit) alleging that+any patent claim is infringed by making, using, selling, offering for+sale, or importing the Program or any portion of it.++ 11. Patents.++ A "contributor" is a copyright holder who authorizes use under this+License of the Program or a work on which the Program is based. The+work thus licensed is called the contributor's "contributor version".++ A contributor's "essential patent claims" are all patent claims+owned or controlled by the contributor, whether already acquired or+hereafter acquired, that would be infringed by some manner, permitted+by this License, of making, using, or selling its contributor version,+but do not include claims that would be infringed only as a+consequence of further modification of the contributor version. For+purposes of this definition, "control" includes the right to grant+patent sublicenses in a manner consistent with the requirements of+this License.++ Each contributor grants you a non-exclusive, worldwide, royalty-free+patent license under the contributor's essential patent claims, to+make, use, sell, offer for sale, import and otherwise run, modify and+propagate the contents of its contributor version.++ In the following three paragraphs, a "patent license" is any express+agreement or commitment, however denominated, not to enforce a patent+(such as an express permission to practice a patent or covenant not to+sue for patent infringement). To "grant" such a patent license to a+party means to make such an agreement or commitment not to enforce a+patent against the party.++ If you convey a covered work, knowingly relying on a patent license,+and the Corresponding Source of the work is not available for anyone+to copy, free of charge and under the terms of this License, through a+publicly available network server or other readily accessible means,+then you must either (1) cause the Corresponding Source to be so+available, or (2) arrange to deprive yourself of the benefit of the+patent license for this particular work, or (3) arrange, in a manner+consistent with the requirements of this License, to extend the patent+license to downstream recipients. "Knowingly relying" means you have+actual knowledge that, but for the patent license, your conveying the+covered work in a country, or your recipient's use of the covered work+in a country, would infringe one or more identifiable patents in that+country that you have reason to believe are valid.++ If, pursuant to or in connection with a single transaction or+arrangement, you convey, or propagate by procuring conveyance of, a+covered work, and grant a patent license to some of the parties+receiving the covered work authorizing them to use, propagate, modify+or convey a specific copy of the covered work, then the patent license+you grant is automatically extended to all recipients of the covered+work and works based on it.++ A patent license is "discriminatory" if it does not include within+the scope of its coverage, prohibits the exercise of, or is+conditioned on the non-exercise of one or more of the rights that are+specifically granted under this License. You may not convey a covered+work if you are a party to an arrangement with a third party that is+in the business of distributing software, under which you make payment+to the third party based on the extent of your activity of conveying+the work, and under which the third party grants, to any of the+parties who would receive the covered work from you, a discriminatory+patent license (a) in connection with copies of the covered work+conveyed by you (or copies made from those copies), or (b) primarily+for and in connection with specific products or compilations that+contain the covered work, unless you entered into that arrangement,+or that patent license was granted, prior to 28 March 2007.++ Nothing in this License shall be construed as excluding or limiting+any implied license or other defenses to infringement that may+otherwise be available to you under applicable patent law.++ 12. No Surrender of Others' Freedom.++ If conditions are imposed on you (whether by court order, agreement or+otherwise) that contradict the conditions of this License, they do not+excuse you from the conditions of this License. If you cannot convey a+covered work so as to satisfy simultaneously your obligations under this+License and any other pertinent obligations, then as a consequence you may+not convey it at all. For example, if you agree to terms that obligate you+to collect a royalty for further conveying from those to whom you convey+the Program, the only way you could satisfy both those terms and this+License would be to refrain entirely from conveying the Program.++ 13. Use with the GNU Affero General Public License.++ Notwithstanding any other provision of this License, you have+permission to link or combine any covered work with a work licensed+under version 3 of the GNU Affero General Public License into a single+combined work, and to convey the resulting work. The terms of this+License will continue to apply to the part which is the covered work,+but the special requirements of the GNU Affero General Public License,+section 13, concerning interaction through a network will apply to the+combination as such.++ 14. Revised Versions of this License.++ The Free Software Foundation may publish revised and/or new versions of+the GNU General Public License from time to time. Such new versions will+be similar in spirit to the present version, but may differ in detail to+address new problems or concerns.++ Each version is given a distinguishing version number. If the+Program specifies that a certain numbered version of the GNU General+Public License "or any later version" applies to it, you have the+option of following the terms and conditions either of that numbered+version or of any later version published by the Free Software+Foundation. If the Program does not specify a version number of the+GNU General Public License, you may choose any version ever published+by the Free Software Foundation.++ If the Program specifies that a proxy can decide which future+versions of the GNU General Public License can be used, that proxy's+public statement of acceptance of a version permanently authorizes you+to choose that version for the Program.++ Later license versions may give you additional or different+permissions. However, no additional obligations are imposed on any+author or copyright holder as a result of your choosing to follow a+later version.++ 15. Disclaimer of Warranty.++ THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY+APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT+HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY+OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,+THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR+PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM+IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF+ALL NECESSARY SERVICING, REPAIR OR CORRECTION.++ 16. Limitation of Liability.++ IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS+THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY+GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE+USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF+DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD+PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),+EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF+SUCH DAMAGES.++ 17. Interpretation of Sections 15 and 16.++ If the disclaimer of warranty and limitation of liability provided+above cannot be given local legal effect according to their terms,+reviewing courts shall apply local law that most closely approximates+an absolute waiver of all civil liability in connection with the+Program, unless a warranty or assumption of liability accompanies a+copy of the Program in return for a fee.++ END OF TERMS AND CONDITIONS++ How to Apply These Terms to Your New Programs++ If you develop a new program, and you want it to be of the greatest+possible use to the public, the best way to achieve this is to make it+free software which everyone can redistribute and change under these terms.++ To do so, attach the following notices to the program. It is safest+to attach them to the start of each source file to most effectively+state the exclusion of warranty; and each file should have at least+the "copyright" line and a pointer to where the full notice is found.++ <one line to give the program's name and a brief idea of what it does.>+ Copyright (C) <year> <name of author>++ This program is free software: you can redistribute it and/or modify+ it under the terms of the GNU General Public License as published by+ the Free Software Foundation, either version 3 of the License, or+ (at your option) any later version.++ This program is distributed in the hope that it will be useful,+ but WITHOUT ANY WARRANTY; without even the implied warranty of+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the+ GNU General Public License for more details.++ You should have received a copy of the GNU General Public License+ along with this program. If not, see <https://www.gnu.org/licenses/>.++Also add information on how to contact you by electronic and paper mail.++ If the program does terminal interaction, make it output a short+notice like this when it starts in an interactive mode:++ <program> Copyright (C) <year> <name of author>+ This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.+ This is free software, and you are welcome to redistribute it+ under certain conditions; type `show c' for details.++The hypothetical commands `show w' and `show c' should show the appropriate+parts of the General Public License. Of course, your program's commands+might be different; for a GUI interface, you would use an "about box".++ You should also get your employer (if you work as a programmer) or school,+if any, to sign a "copyright disclaimer" for the program, if necessary.+For more information on this, and how to apply and follow the GNU GPL, see+<https://www.gnu.org/licenses/>.++ The GNU General Public License does not permit incorporating your program+into proprietary programs. If your program is a subroutine library, you+may consider it more useful to permit linking proprietary applications with+the library. If this is what you want to do, use the GNU Lesser General+Public License instead of this License. But first, please read+<https://www.gnu.org/licenses/why-not-lgpl.html>.diff --git a/README.md b/README.mdnew file mode 100644index 00000000..7399fe12--- /dev/null+++ b/README.md@@ -0,0 +1,101 @@+# Myspoti++[](https://github.com/kota-zo/myspoti/releases/latest)+[](LICENSE)+[](https://discord.gg/jXKnGVFnGS)++**Spotify on Android, free account, no ads.** A native Jetpack Compose client with synced lyrics and official music videos.++<p align="center">+ <img src="docs/screenshots/banner.jpg" alt="Myspoti: home, player, artist and album screens" width="100%">+</p>++<p align="center">+ <a href="https://github.com/kota-zo/myspoti/releases/latest"><b>⬇ Download the latest APK</b></a>+</p>++The official Spotify Web Player runs in a hidden WebView and does the actual playback, with the phone's DRM and Spotify's own reporting. The native UI drives it, so plays count on your account exactly as they do in a browser. You always sign in yourself, on Spotify's own login page.++<p align="center">+ <a href="https://ko-fi.com/kotazo"><img src="https://storage.ko-fi.com/cdn/kofi6.png?v=6" alt="Support Myspoti on Ko-fi" height="56"></a>+</p>++## Features++- **No ads.** The ad audio is refused, so the player skips each ad within a second. It works with a free account: no Premium, no patched Spotify app, and the DRM is left untouched.+- Home (with Music, Podcasts and Audiobooks filters), search (songs, artists, albums, playlists, podcasts, episodes), **New releases**, Spotify's real **Browse** categories, library (folders, sorting, drag to reorder), artist, album and playlist pages, with Spotify's official labels.+- **Podcasts and audiobooks**: shows, episodes, chapters, Your Episodes, playback speed.+- **Jam**: join a Jam with an invite link.+- Synced lyrics: Spotify first, then [LRCLIB](https://lrclib.net); optionally Apple Music (word by word), NetEase and Genius.+- **Your recap**: your top tracks, artists and albums, counting Spotify, downloads and local files. It stays on your phone.+- Official music videos, when one exists. The video plays muted, in sync with the song. The app only uses YouTube videos marked as official clips, and shows nothing when no clip exists.+- Spotify Connect, media notification, lock screen, Bluetooth and Android Auto.+- **Offline downloads.** Download a song, an album, a playlist or your Liked Songs, then play them without a connection. The audio comes from YouTube Music (Opus or AAC, as YouTube serves it, never re-encoded), not from Spotify. Each file is checked against the recording's official preview (looked up by ISRC), so a live take, a remix or a cover is rejected. Files stay in Myspoti's private storage.++## How it works++The app is split in two:++- **`:api`** is the contract the UI talks to: plain Kotlin models and interfaces (player, search, catalog, library, playlists, home, podcasts, users, lyrics, devices, Jam).+- **`:api-spotify`** implements it on Spotify's Web Player. Playback stays in the official player, in a hidden WebView (`:host-android`), driven by a small bridge script. Catalog, search and library calls go straight to Spotify's servers, which is faster. When Spotify ships a new Web Player, the app reads its new operation list from the public files by itself.+- **`:host-cdp`** runs the same API on desktop Chrome: the whole API is tested against the real Web Player, without a phone.++Details for developers: [`base/api-spotify/README.md`](base/api-spotify/README.md) and [`docs/api`](docs/api).++## Screenshots++| Home | Player | Artist | Album |+|:---:|:---:|:---:|:---:|+| <img src="docs/screenshots/home.jpg" width="200" alt="Home"> | <img src="docs/screenshots/player.jpg" width="200" alt="Player"> | <img src="docs/screenshots/artist.jpg" width="200" alt="Artist"> | <img src="docs/screenshots/album.jpg" width="200" alt="Album"> |++## Not included++- No DRM circumvention.+- No Spotify audio download or decryption. Offline downloads come from YouTube Music, not from Spotify or any other paid service.+- No altered listening events.++## Disclaimer++Blocking ads goes against Spotify's Terms of Use, and Spotify may suspend accounts that do it. Use this app at your own risk. If you can, support artists with Premium or by buying their music.++## Support++Myspoti is free, has no ads and is made in my spare time. If you enjoy it, you can support it on [Ko-fi](https://ko-fi.com/kotazo), also from **About** in the app's profile menu. Nothing in the app is locked behind a donation.++<p align="center">+ <a href="https://ko-fi.com/kotazo"><img src="https://storage.ko-fi.com/cdn/kofi6.png?v=6" alt="Support Myspoti on Ko-fi" height="56"></a>+</p>++News, help and ideas: join the [Discord server](https://discord.gg/jXKnGVFnGS). Bugs and requests are also welcome in [GitHub issues](https://github.com/kota-zo/myspoti/issues).++## Build++The Android project is in `base/`. Requirements: JDK 17+ and the Android SDK (compileSdk 37).++```bash+cd base+./gradlew assembleDebug+./gradlew testDebugUnitTest+```++Live API tests (desktop Chrome with a signed-in Web Player):++```bash+google-chrome --user-data-dir="$HOME/.myspoti-chrome" --remote-debugging-port=9222+./gradlew :host-cdp:test -Pcdp=http://localhost:9222+```++Every push builds and tests on GitHub Actions. A `v*` tag publishes a signed APK in Releases, which the app checks for updates.++## Credits++- UI derived from [Spotui](https://github.com/Spotui/Spotui) / [Metrolist](https://github.com/MetrolistGroup/Metrolist) (GPL-3.0).+- [NewPipeExtractor](https://github.com/TeamNewPipe/NewPipeExtractor) (GPL-3.0).+- [Material Icons](https://github.com/google/material-design-icons) (Apache 2.0).+- [Figtree](https://github.com/erikdkennedy/figtree) font (SIL OFL 1.1, see `base/licenses/`).++## License++GPL-3.0.++Not affiliated with or endorsed by Spotify. Spotify is a trademark of Spotify AB.diff --git a/base/.gitignore b/base/.gitignorenew file mode 100644index 00000000..fb765660--- /dev/null+++ b/base/.gitignore@@ -0,0 +1,41 @@+*.iml+.gradle+/.kotlin/+/local.properties+/.idea+.DS_Store+/build+/captures+.externalNativeBuild+.cxx+local.properties++# App build+app/build++# Gradle wrapper binary+# gradle-wrapper.jar is committed (CI runs ./gradlew)++# Firebase+app/google-services.json++# Keystore files+*.jks+*.keystore+*.p12+*.pem+keystore/++# OS files+Thumbs.db+Desktop.ini++# IDE+*.swp+*.swo+*~++# Logs+*.log++scripts/\ No newline at end of filediff --git a/base/api-spotify/README.md b/base/api-spotify/README.mdnew file mode 100644index 00000000..40769e44--- /dev/null+++ b/base/api-spotify/README.md@@ -0,0 +1,127 @@+# api-spotify++Spotify implementation of the Myspoti API (`:api`), on top of the official Web Player.++## Modules++| Module | Role |+|---|---|+| `:api` | Pure Kotlin contract the UI sees: models and interfaces, no Android, no Spotify details |+| `:api-spotify` | This module: `SpotifyApi` implements `:api` |+| `:host-cdp` | Desktop host (Chrome over CDP) and the live integration tests |++Reads go straight to Spotify over HTTP (`SpotifyHttp`: the page's web token plus a client+token minted here). Playback, library writes, folders, Connect and Jam go through the page's+own services via the bridge. `SpotifyApi.raw` reaches all 179 GraphQL operations+(`gql-ops.json`, variables in `gql-schema.json`) and the 89 page services for anything not typed.++## Coverage++All of these are exercised by `host-cdp` live tests against a free account:++| Domain | Methods |+|---|---|+| Player | play (any context), pause, resume, seek, next, previous, repeat, shuffle, queue add/remove/clear, volume, speed (podcasts only) |+| Search | all, tracks, artists, albums, playlists, shows, episodes, audiobooks, users, genres, suggestions, recent, clear recent |+| Catalog | track, album, album tracks, artist, top tracks, discography, related artists, appears on, similar albums |+| Library | contains/add/remove, library list with filters, sort and folders, liked songs, pin/unpin, create/rename/delete folders, move to folder |+| Playlists | playlist, tracks (paged, with row uids), mine, editable, create, rename, description, delete, follow/unfollow, add/remove/move tracks, recommended songs |+| Home | feed with filters, categories, category pages |+| Podcasts | show, episodes, episode, audiobook, chapters, saved episodes |+| Users | me, public profile, top artists/tracks, follow/unfollow/is following, history |+| Track extras | lyrics (line and word sync, colours), canvas, credits, radio for a track or artist, taste-profile exclusion |+| Devices | list, transfer, pull here |+| Jam | availability, session, start, join, leave, end, invite link, remove member, queue-only, participant volume |++Limits seen on the Web Player with a free account:+- Jam: Spotify answers `RESTRICTED`, so `start` fails; join and the rest are wired but unverified.+- Private session: not supported by the Web Player (`isSupported: false`).+- Friend activity: not implemented by the Web Player; `friendActivity()` returns an empty list.+- Device transfer: needs a second Connect device to verify.++Tools (`tools/`): `refresh_gql_ops.py` (operation hashes from the public bundles),+`extract_gql_variables.py` (variables from captures), `infer_gql_variables.py`,+`build_gql_schema.py` (required variables and types from the server), `capability_report.py`.++## Player bridge++[`src/main/resources/bridge/player-bridge.js`](src/main/resources/bridge/player-bridge.js) runs inside the+official Web Player page (open.spotify.com), which keeps doing the playback with the+browser's Widevine CDM. The bridge finds the page's service registry through React's+context tree and calls its `PlayerAPI`, `PlaybackAPI`, `LibraryAPI` and `TokenProvider`.+It patches nothing in the page.++The same file runs in the Android WebView and in desktop Chrome over CDP.++### Channels++| Direction | Android | Desktop (CDP) |+|---|---|---|+| Host → page | `evaluateJavascript("Myspoti.call(id, method, args)")` | `Runtime.evaluate`, same call |+| Page → host | `@JavascriptInterface MyspotiHost.post(json)` | `Runtime.addBinding("__mspHostPost")` |++`Myspoti.call` also returns a Promise, but hosts should rely on the `result` message:+Android's `evaluateJavascript` does not wait for Promises.++### Messages (page → host)++| `type` | Fields |+|---|---|+| `ready` | `version` |+| `state` | `state`: see below, or `null` when no playback session exists |+| `queue` | `queue`: `{current, queued[], nextUp[]}` of tracks |+| `result` | `id`, `ok`, `value` or `error` |+| `error` | `error` (boot failure) |++`state`: `{track, contextUri, isPaused, isBuffering, positionMs, timestamp, durationMs,+shuffle, repeat (0 off, 1 context, 2 track), speed, restrictions, playbackId}`.+`positionMs` is the position at `timestamp` (epoch ms). Extrapolate it while playing.++`track`: `{kind ("track", "episode" or "ad"), uri, uid, name, advertiser, durationMs, artists[{uri, name}],+album{uri, name}, image,+explicit, mediaType, provider}`. An ad has `kind: "ad"`, a `spotify:ad:` uri, an `advertiser`,+and restrictions that forbid skip and seek.++### Methods++| Method | Args | Returns |+|---|---|---|+| `bridge.version` | | `1` |+| `player.state` | | state or `null` |+| `player.queue` | | queue |+| `player.play` | `contextUri`, optional `trackUri`, `trackUid`, `index`, `positionMs` | |+| `player.pause` / `player.resume` | | |+| `player.seek` | `positionMs` | |+| `player.next` / `player.previous` | | |+| `player.setShuffle` | `on` | |+| `player.setRepeat` | `mode` (0, 1, 2) | |+| `queue.add` | `uris[]` | |+| `queue.remove` | `items[{uri, uid}]` | |+| `queue.clear` | | |+| `volume.get` / `volume.set` | `level` (0 to 1) | number |+| `library.contains` | `uris[]` | `boolean[]` |+| `library.add` / `library.remove` | `uris[]` (tracks, albums, artists) | |+| `token.get` | | `{accessToken, expiresAtMs}` for the HTTP API |++Notes:+- `player.previous` near the start of a track goes back. Later, it restarts the track.+- `queue.add` lands within about a second, and a `queue` message follows.+- A command can be refused by `restrictions`, for example while the next track loads. The error message says so.++### Tests++Kotlin live tests: `./gradlew :host-cdp:test -Pcdp=http://localhost:9222`.++The older Python harness [`bridge-tests/run_bridge_tests.py`](bridge-tests/run_bridge_tests.py) drives a logged-in Web Player in+desktop Google Chrome (Widevine included) over CDP. Each test restores what it changes.++```bash+google-chrome --user-data-dir="$HOME/.myspoti-chrome" --remote-debugging-port=9222+```++```bash+python run_bridge_tests.py # all tests+python run_bridge_tests.py -k queue # some tests (comma-separated)+```++Not covered yet: ads on free accounts, Connect (other devices), podcasts.diff --git a/base/api-spotify/bridge-tests/run_bridge_tests.py b/base/api-spotify/bridge-tests/run_bridge_tests.pynew file mode 100644index 00000000..263c9abb--- /dev/null+++ b/base/api-spotify/bridge-tests/run_bridge_tests.py@@ -0,0 +1,249 @@+"""Player bridge tests against a real, logged-in Web Player in desktop Chrome.++Needs Google Chrome (it ships Widevine) started with a dedicated profile:+ google-chrome --user-data-dir=<profile> --remote-debugging-port=9222+and Playwright (`pip install playwright`). Sign in once in that window, then run:+ python run_bridge_tests.py [--cdp http://localhost:9222]++The host side mirrors Android: page -> host messages go through one binding+(`__mspHostPost`), host -> page commands through `Myspoti.call`.+Every test restores what it changes (volume, queue, likes, pause state).+"""+import argparse, asyncio, itertools, json, sys, time+from pathlib import Path+from playwright.async_api import async_playwright++BRIDGE = Path(__file__).resolve().parents[1] / "src/main/resources/bridge/player-bridge.js"+TEST_CONTEXT = "spotify:playlist:37i9dQZF1DXcBWIGoYBM5M" # Today's Top Hits+++class Host:+ def __init__(self, page, cdp):+ self.page, self.cdp = page, cdp+ self.ids = itertools.count(1)+ self.pending = {}+ self.states = []+ self.queues = 0+ self.ready = asyncio.Event()++ def on_message(self, raw):+ msg = json.loads(raw)+ kind = msg["type"]+ if kind == "ready":+ self.ready.set()+ elif kind == "state":+ self.states.append(msg["state"])+ elif kind == "queue":+ self.queues += 1+ elif kind == "result":+ fut = self.pending.pop(msg["id"], None)+ if fut and not fut.done():+ fut.set_result(msg)+ elif kind == "error":+ print("bridge error:", msg["error"])++ async def attach(self):+ await self.cdp.send("Runtime.enable")+ await self.cdp.send("Runtime.addBinding", {"name": "__mspHostPost"})+ self.cdp.on("Runtime.bindingCalled", lambda e: e["name"] == "__mspHostPost" and self.on_message(e["payload"]))+ # A reload drops window.Myspoti: start fresh so the new binding is used.+ await self.page.reload()+ await self.page.wait_for_load_state("domcontentloaded")+ await self.page.evaluate(BRIDGE.read_text())+ await asyncio.wait_for(self.ready.wait(), 60)++ async def call(self, method, **args):+ cid = next(self.ids)+ fut = asyncio.get_running_loop().create_future()+ self.pending[cid] = fut+ # Fire and forget, like Android's evaluateJavascript: the answer comes back as a message.+ await self.page.evaluate(f"window.Myspoti.call({cid}, {json.dumps(method)}, {json.dumps(args)}).catch(() => {{}})")+ msg = await asyncio.wait_for(fut, 20)+ if not msg["ok"]:+ raise AssertionError(f"{method} failed: {msg['error']}")+ return msg["value"]++ async def wait_state(self, pred, timeout=15):+ end = time.monotonic() + timeout+ while time.monotonic() < end:+ s = await self.call("player.state")+ if s and pred(s):+ return s+ await asyncio.sleep(0.3)+ raise AssertionError("state condition not reached")+++async def _wait_queue(self, pred, timeout=10):+ end = time.monotonic() + timeout+ while time.monotonic() < end:+ hit = pred(await self.call("player.queue"))+ if hit:+ return hit+ await asyncio.sleep(0.3)+ raise AssertionError("queue condition not reached")+++Host.wait_queue = _wait_queue+++def position(s):+ """Live position, extrapolated from the snapshot like the UI will."""+ if s["isPaused"]:+ return s["positionMs"]+ return s["positionMs"] + (time.time() * 1000 - s["timestamp"]) * s["speed"]+++async def test_ready_and_state(h):+ v = await h.call("bridge.version")+ assert v == 1, f"version {v!r}"+ s = await h.call("player.state")+ assert s is None or "isPaused" in s, s # null until a playback session exists+++async def test_token(h):+ t = await h.call("token.get")+ assert t["accessToken"] and t["expiresAtMs"] > time.time() * 1000+++async def test_play_context(h):+ await h.call("player.play", contextUri=TEST_CONTEXT, index=0)+ s = await h.wait_state(lambda s: s["contextUri"] == TEST_CONTEXT and not s["isPaused"] and s["track"])+ await asyncio.sleep(4)+ s = await h.call("player.state")+ assert position(s) > 1000, f"not advancing: {s['positionMs']}"+++async def test_pause_resume(h):+ await h.call("player.pause")+ s = await h.wait_state(lambda s: s["isPaused"])+ p = s["positionMs"]+ await asyncio.sleep(2)+ assert abs((await h.call("player.state"))["positionMs"] - p) < 500+ await h.call("player.resume")+ await h.wait_state(lambda s: not s["isPaused"])+++async def test_seek(h):+ s = await h.call("player.state")+ target = int(s["durationMs"] * 0.5)+ await h.call("player.seek", positionMs=target)+ s = await h.wait_state(lambda s: abs(position(s) - target) < 3000)+++async def test_next_previous(h):+ first = (await h.call("player.state"))["track"]["uri"]+ await h.call("player.next")+ s = await h.wait_state(lambda s: s["track"]["uri"] != first)+ await h.call("player.previous") # restarts the track, or goes back when near the start+ await asyncio.sleep(1)+ s = await h.call("player.state")+ if s["track"]["uri"] != first:+ await h.wait_state(lambda s: s["restrictions"].get("canSkipPrevious"), timeout=5)+ await h.call("player.previous")+ await h.wait_state(lambda s: s["track"]["uri"] == first)+++async def test_queue(h):+ q = await h.call("player.queue")+ candidate = q["nextUp"][3]["uri"]+ before = h.queues+ await h.call("queue.add", uris=[candidate])+ added = await h.wait_queue(lambda q: [t for t in q["queued"] if t["uri"] == candidate])+ assert h.queues > before, "no queue event"+ await h.call("queue.remove", items=[{"uri": t["uri"], "uid": t["uid"]} for t in added])+ await h.wait_queue(lambda q: not [t for t in q["queued"] if t["uri"] == candidate] or None)+++async def test_volume(h):+ old = await h.call("volume.get")+ await h.call("volume.set", level=0.3)+ await asyncio.sleep(0.5)+ assert abs(await h.call("volume.get") - 0.3) < 0.02+ await h.call("volume.set", level=old)+++async def test_library(h):+ uri = (await h.call("player.state"))["track"]["uri"]+ [was] = await h.call("library.contains", uris=[uri])+ await (h.call("library.remove", uris=[uri]) if was else h.call("library.add", uris=[uri]))+ await asyncio.sleep(1.5)+ [now] = await h.call("library.contains", uris=[uri])+ assert now != was, "like did not toggle"+ await (h.call("library.add", uris=[uri]) if was else h.call("library.remove", uris=[uri]))+ await asyncio.sleep(1.5)+ assert (await h.call("library.contains", uris=[uri]))[0] == was+++SEARCH_TRACKS = "b02683192a98dde7966b5e6655a79eeb62713eab703eda9902c932818dd52751"+++async def test_gql_search(h):+ r = await h.call("gql.query", name="searchTracks", hash=SEARCH_TRACKS, variables={+ "searchTerm": "stromae", "offset": 0, "limit": 5, "numberOfTopResults": 5,+ "includeAudiobooks": True, "includeAuthors": True, "includePreReleases": False,+ "includeAlbumPreReleases": False, "includeEpisodeContentRatingsV2": True})+ items = r["data"]["searchV2"]["tracksV2"]["items"]+ assert len(items) == 5 and all(i["item"]["data"]["uri"].startswith("spotify:track:") for i in items)+++async def test_services(h):+ services = await h.call("service.list")+ for name in ("PlaylistAPI", "RootlistAPI", "LibraryAPI", "ShowAPI", "ConnectDevicesAPI", "UserAPI"):+ assert name in services, f"{name} missing"+ meta = await h.call("service.call", service="PlaylistAPI", method="getMetadata", args=[TEST_CONTEXT])+ assert meta["uri"] == TEST_CONTEXT and meta.get("name"), meta+ contents = await h.call("service.call", service="PlaylistAPI", method="getContents",+ args=[TEST_CONTEXT, {"limit": 5, "offset": 0}])+ assert len(contents["items"]) == 5 and contents["totalLength"] >= 5+ root = await h.call("service.call", service="RootlistAPI", method="getContents", args=[])+ assert "items" in root+ user = await h.call("service.call", service="UserAPI", method="getUser", args=[])+ assert user.get("username")+ devices = await h.call("service.call", service="ConnectDevicesAPI", method="getDevices", args=[])+ assert isinstance(devices, list)+++async def test_state_events(h):+ assert h.states, "no state event received"+ assert any(s and s["track"] for s in h.states)+++TESTS = [test_ready_and_state, test_token, test_play_context, test_pause_resume, test_seek,+ test_next_previous, test_queue, test_volume, test_library, test_gql_search, test_services, test_state_events]+++async def main():+ ap = argparse.ArgumentParser()+ ap.add_argument("--cdp", default="http://localhost:9222")+ ap.add_argument("-k", help="only run tests whose name contains one of these (comma-separated)")+ opts = ap.parse_args()+ async with async_playwright() as p:+ browser = await p.chromium.connect_over_cdp(opts.cdp)+ ctx = browser.contexts[0]+ page = next((pg for pg in ctx.pages if "open.spotify.com" in pg.url), None)+ if page is None:+ page = await ctx.new_page()+ await page.goto("https://open.spotify.com/")+ await page.bring_to_front()+ h = Host(page, await ctx.new_cdp_session(page))+ await h.attach()+ failed = 0+ for t in TESTS:+ if opts.k and not any(k in t.__name__ for k in opts.k.split(",")):+ continue+ t0 = time.monotonic()+ try:+ await t(h)+ print(f"PASS {t.__name__} ({time.monotonic() - t0:.1f}s)")+ except Exception as e:+ failed += 1+ print(f"FAIL {t.__name__}: {type(e).__name__}: {e}")+ try:+ await h.call("player.pause")+ except Exception:+ pass+ print(f"{len(TESTS) - failed if not opts.k else '-'} passed, {failed} failed")+ sys.exit(1 if failed else 0)+++asyncio.run(main())diff --git a/base/api-spotify/build.gradle.kts b/base/api-spotify/build.gradle.ktsnew file mode 100644index 00000000..2d7f9a42--- /dev/null+++ b/base/api-spotify/build.gradle.kts@@ -0,0 +1,23 @@+// Spotify implementation of :api. Plain JVM: it talks to the Web Player page through a+// BridgeHost (Android WebView or desktop Chrome) and to Spotify's HTTP API directly.+plugins {+ alias(libs.plugins.kotlin.jvm)+}++kotlin {+ jvmToolchain(17)+}++dependencies {+ api(project(":api"))+ api(libs.serialization.json)+ implementation(libs.okhttp)++ testImplementation(platform(libs.junit.bom))+ testImplementation(libs.junit.jupiter)+ testRuntimeOnly(libs.junit.launcher)+}++tasks.test {+ useJUnitPlatform()+}diff --git a/base/api-spotify/src/main/kotlin/app/myspoti/spotify/JsonPaths.kt b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/JsonPaths.ktnew file mode 100644index 00000000..901a5e4f--- /dev/null+++ b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/JsonPaths.kt@@ -0,0 +1,28 @@+package app.myspoti.spotify++import kotlinx.serialization.json.JsonArray+import kotlinx.serialization.json.JsonElement+import kotlinx.serialization.json.JsonNull+import kotlinx.serialization.json.JsonObject+import kotlinx.serialization.json.JsonPrimitive+import kotlinx.serialization.json.booleanOrNull+import kotlinx.serialization.json.doubleOrNull+import kotlinx.serialization.json.longOrNull++// Lenient reads over Spotify's JSON: a missing or null field gives null, never an exception.++/** Walks a dotted path such as `"data.searchV2.tracksV2"`. */+internal fun JsonElement?.at(path: String): JsonElement? =+ path.split('.').fold(this) { node, key -> (node as? JsonObject)?.get(key)?.takeUnless { it is JsonNull } }++internal fun JsonElement?.obj(path: String): JsonObject? = at(path) as? JsonObject+internal fun JsonElement?.list(path: String): List<JsonElement> = (at(path) as? JsonArray).orEmpty()+internal fun JsonElement?.str(path: String): String? = (at(path) as? JsonPrimitive)?.takeIf { it.isString }?.content+internal fun JsonElement?.long(path: String): Long? =+ (at(path) as? JsonPrimitive)?.let { it.longOrNull ?: it.doubleOrNull?.toLong() ?: it.content.toLongOrNull() }+internal fun JsonElement?.int(path: String): Int? = long(path)?.toInt()+internal fun JsonElement?.double(path: String): Double? = (at(path) as? JsonPrimitive)?.doubleOrNull+internal fun JsonElement?.bool(path: String): Boolean? = (at(path) as? JsonPrimitive)?.booleanOrNull++/** `__typename` of an entity, to tell `Track` from `NotFound`. */+internal fun JsonElement?.typename(): String? = str("__typename")diff --git a/base/api-spotify/src/main/kotlin/app/myspoti/spotify/Mappers.kt b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/Mappers.ktnew file mode 100644index 00000000..23a6f3e8--- /dev/null+++ b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/Mappers.kt@@ -0,0 +1,220 @@+package app.myspoti.spotify++import app.myspoti.api.Album+import app.myspoti.api.AlbumRef+import app.myspoti.api.Artist+import app.myspoti.api.ArtistRef+import app.myspoti.api.Image+import app.myspoti.api.ItemKind+import app.myspoti.api.NowPlaying+import app.myspoti.api.Page+import app.myspoti.api.PlayerRestrictions+import app.myspoti.api.PlayerState+import app.myspoti.api.Playlist+import app.myspoti.api.Queue+import app.myspoti.api.Repeat+import app.myspoti.api.Track+import kotlinx.serialization.json.JsonElement++// GraphQL entities (search, catalog, playlists) -> :api models.++internal fun images(sources: List<JsonElement>): List<Image> = sources.mapNotNull { s ->+ val url = s.str("url") ?: return@mapNotNull null+ Image(url, s.int("width") ?: s.int("maxWidth")?.takeIf { it > 0 }, s.int("height") ?: s.int("maxHeight")?.takeIf { it > 0 })+}++internal fun artistRefs(node: JsonElement?): List<ArtistRef> = node.list("items").mapNotNull { a ->+ val uri = a.str("uri") ?: return@mapNotNull null+ ArtistRef(uri, a.str("profile.name") ?: a.str("name") ?: "")+}++/** A `Track` entity from search, getTrack or a playlist row (`itemV2.data`). */+internal fun track(d: JsonElement?, uid: String? = null): Track? {+ val uri = d.str("uri") ?: return null+ if (!uri.startsWith("spotify:track:")) return null+ val album = d.obj("albumOfTrack")+ return Track(+ uri = uri,+ name = d.str("name") ?: "",+ durationMs = d.long("duration.totalMilliseconds") ?: d.long("trackDuration.totalMilliseconds") ?: 0,+ artists = artistRefs(d.obj("artists")).ifEmpty { artistRefs(d.obj("firstArtist")) + artistRefs(d.obj("otherArtists")) },+ album = album?.let { a ->+ AlbumRef(a.str("uri") ?: "", a.str("name") ?: "", images(a.list("coverArt.sources")))+ },+ explicit = d.str("contentRating.label") == "EXPLICIT",+ playable = d.bool("playability.playable") ?: true,+ uid = uid,+ )+}++internal fun artist(d: JsonElement?): Artist? {+ val uri = d.str("uri") ?: return null+ return Artist(+ uri = uri,+ name = d.str("profile.name") ?: "",+ images = images(d.list("visuals.avatarImage.sources")),+ followers = d.long("stats.followers"),+ monthlyListeners = d.long("stats.monthlyListeners"),+ verified = d.bool("profile.verified") ?: false,+ )+}++internal fun album(d: JsonElement?): Album? {+ val uri = d.str("uri") ?: return null+ return Album(+ uri = uri,+ name = d.str("name") ?: "",+ artists = artistRefs(d.obj("artists")),+ images = images(d.list("coverArt.sources")),+ type = d.str("type") ?: "ALBUM",+ releaseDate = d.str("date.isoString") ?: d.long("date.year")?.toString(),+ trackCount = d.int("tracksV2.totalCount") ?: d.int("tracks.totalCount") ?: 0,+ label = d.str("label"),+ )+}++internal fun playlist(d: JsonElement?): Playlist? {+ val uri = d.str("uri") ?: return null+ return Playlist(+ uri = uri,+ name = d.str("name") ?: "",+ description = d.str("description")?.takeIf { it.isNotBlank() },+ owner = d.str("ownerV2.data.name"),+ images = d.list("images.items").flatMap { images(it.list("sources")) },+ trackCount = d.int("content.totalCount") ?: 0,+ editable = d.bool("currentUserCapabilities.canEditItems") ?: false,+ ownerUri = d.str("ownerV2.data.uri"),+ ownerImages = images(d.list("ownerV2.data.avatar.sources")),+ followers = d.long("followers"),+ )+}++/** Search tab pages: `{items[], totalCount, pagingInfo{nextOffset}}`. */+internal fun <T> page(node: JsonElement?, offset: Int, map: (JsonElement) -> T?): Page<T> {+ val items = node.list("items").mapNotNull(map)+ val total = node.int("totalCount") ?: items.size+ val next = node.int("pagingInfo.nextOffset") ?: (offset + items.size).takeIf { items.isNotEmpty() && it < total }+ return Page(items, offset, total, next)+}++// Bridge player messages -> :api models.++internal fun nowPlaying(t: JsonElement?): NowPlaying? {+ val uri = t.str("uri") ?: return null+ val kind = when (t.str("kind")) {+ "ad" -> ItemKind.AD+ "episode" -> ItemKind.EPISODE+ else -> if (uri.startsWith("spotify:ad:")) ItemKind.AD else ItemKind.TRACK+ }+ return NowPlaying(+ kind = kind,+ uri = uri,+ uid = t.str("uid"),+ name = t.str("name") ?: "",+ artists = t.list("artists").mapNotNull { a -> a.str("uri")?.let { ArtistRef(it, a.str("name") ?: "") } },+ album = t.obj("album")?.let { AlbumRef(it.str("uri") ?: "", it.str("name") ?: "") },+ imageUrl = t.str("image"),+ durationMs = t.long("durationMs") ?: 0,+ explicit = t.bool("explicit") ?: false,+ )+}++internal fun playerState(s: JsonElement?): PlayerState? {+ if (s == null || s.obj("restrictions") == null && s.at("isPaused") == null) return null+ val r = s.obj("restrictions")+ return PlayerState(+ item = nowPlaying(s.obj("track")),+ contextUri = s.str("contextUri"),+ contextName = s.str("contextName"),+ previous = nowPlaying(s.obj("previous")),+ next = nowPlaying(s.obj("next")),+ isPaused = s.bool("isPaused") ?: true,+ isBuffering = s.bool("isBuffering") ?: false,+ positionMs = s.long("positionMs") ?: 0,+ timestampMs = s.long("timestamp") ?: System.currentTimeMillis(),+ speed = s.double("speed") ?: 1.0,+ shuffle = s.bool("shuffle") ?: false,+ repeat = when (s.int("repeat")) { 1 -> Repeat.CONTEXT; 2 -> Repeat.TRACK; else -> Repeat.OFF },+ restrictions = PlayerRestrictions(+ canPause = r.bool("canPause") ?: true,+ canResume = r.bool("canResume") ?: true,+ canSeek = r.bool("canSeek") ?: true,+ canSkipNext = r.bool("canSkipNext") ?: true,+ canSkipPrevious = r.bool("canSkipPrevious") ?: true,+ ),+ )+}++internal fun queue(q: JsonElement?): Queue? {+ if (q == null) return null+ return Queue(+ current = nowPlaying(q.obj("current")),+ queued = q.list("queued").mapNotNull(::nowPlaying),+ nextUp = q.list("nextUp").mapNotNull(::nowPlaying),+ )+}++// Cards and podcast entities.++/** Any `*ResponseWrapper` (or its `data`) -> a card for shelves and search tabs. */+internal fun card(wrapper: JsonElement?): app.myspoti.api.MediaCard? {+ val d = wrapper.obj("data") ?: wrapper+ val uri = d.str("uri") ?: wrapper.str("_uri") ?: wrapper.str("uri") ?: return null+ val type = d.typename()+ var kind = app.myspoti.api.MediaKind.of(uri)+ if (type == "Audiobook") kind = app.myspoti.api.MediaKind.AUDIOBOOK+ val title = d.str("name") ?: d.str("profile.name") ?: d.str("displayName") ?: d.str("title.transformedLabel") ?: d.str("title") ?: return null+ val subtitle = when (type) {+ "Playlist" -> d.str("ownerV2.data.name") ?: d.str("description")+ "Album" -> artistRefs(d.obj("artists")).joinToString(", ") { it.name }.ifBlank { null }+ "Track" -> artistRefs(d.obj("artists")).joinToString(", ") { it.name }.ifBlank { null }+ "Podcast" -> d.str("publisher.name")+ "Audiobook" -> d.list("authorsV2").mapNotNull { it.str("name") }.joinToString(", ").ifBlank { null }+ "Episode", "Chapter" -> d.str("podcastV2.data.name")+ "PseudoPlaylist" -> d.int("count")?.toString()+ else -> null+ }+ val images = images(+ d.list("coverArt.sources").ifEmpty { d.list("visuals.avatarImage.sources") }+ .ifEmpty { d.list("images.items").flatMap { it.list("sources") } }+ .ifEmpty { d.list("avatar.sources") }.ifEmpty { d.list("image.sources") }+ .ifEmpty { d.list("albumOfTrack.coverArt.sources") }+ )+ return app.myspoti.api.MediaCard(uri, kind, title, subtitle, images)+}++internal fun episode(d: JsonElement?): app.myspoti.api.Episode? {+ val uri = d.str("uri") ?: return null+ val show = d.obj("podcastV2.data")+ return app.myspoti.api.Episode(+ uri = uri,+ name = d.str("name") ?: "",+ description = d.str("description"),+ durationMs = d.long("duration.totalMilliseconds") ?: 0,+ releaseDate = d.str("releaseDate.isoString"),+ images = images(d.list("coverArt.sources")),+ show = show?.let { AlbumRef(it.str("uri") ?: "", it.str("name") ?: "", images(it.list("coverArt.sources"))) },+ playedPositionMs = d.long("playedState.playPositionMilliseconds") ?: 0,+ played = d.str("playedState.state") == "COMPLETED",+ explicit = d.str("contentRating.label") == "EXPLICIT",+ playable = d.bool("playability.playable") ?: true,+ previewUrl = d.str("previewPlayback.audioPreview.cdnUrl"),+ )+}++internal fun show(d: JsonElement?): app.myspoti.api.Show? {+ val uri = d.str("uri") ?: return null+ return app.myspoti.api.Show(+ uri = uri,+ name = d.str("name") ?: "",+ publisher = d.str("publisher.name") ?: "",+ description = d.str("description"),+ images = images(d.list("coverArt.sources")),+ saved = d.bool("saved") ?: false,+ rating = d.double("rating.averageRating.average"),+ topics = d.list("topics.items").mapNotNull { it.str("title") },+ )+}++/** Discography and "appears on" rows hold `releases.items[0]`. */+internal fun release(row: JsonElement?): Album? = album(row.list("releases.items").firstOrNull() ?: row)diff --git a/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyApi.kt b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyApi.ktnew file mode 100644index 00000000..b35731a5--- /dev/null+++ b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyApi.kt@@ -0,0 +1,83 @@+package app.myspoti.spotify++import app.myspoti.api.MyspotiApi+import app.myspoti.spotify.bridge.Bridge+import app.myspoti.spotify.bridge.BridgeHost+import app.myspoti.spotify.bridge.service+import app.myspoti.spotify.gql.BridgeGql+import app.myspoti.spotify.gql.Gql+import app.myspoti.spotify.gql.GqlOps+import app.myspoti.spotify.gql.HttpGql+import app.myspoti.spotify.gql.OpsSource+import app.myspoti.spotify.gql.SpotifyHttp+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.flow.StateFlow+import kotlinx.coroutines.flow.filter+import kotlinx.coroutines.flow.first+import kotlinx.coroutines.launch+import kotlinx.serialization.json.JsonElement+import kotlinx.serialization.json.JsonObject+import okhttp3.OkHttpClient++/**+ * [MyspotiApi] backed by the Spotify Web Player.+ *+ * Reads go straight to Spotify over HTTP (fast, parallel); playback, library writes, Connect,+ * Jam and the web token go through the page. The host must call [onPageLoaded] after every+ * page load.+ *+ * [raw] reaches every Web Player capability, typed or not.+ */+class SpotifyApi(+ host: BridgeHost,+ private val scope: CoroutineScope,+ http: OkHttpClient = OkHttpClient(),+ language: String = "en",+ val ops: GqlOps = GqlOps.bundled(),+) : MyspotiApi {+ val bridge = Bridge(host, scope)+ val http = SpotifyHttp(http, bridge, language)+ @Volatile private var currentOps: GqlOps = ops+ /** The operation table in use; [updateOps] swaps it when Spotify ships a new build. */+ val opsInUse: GqlOps get() = currentOps+ private val liveOps = object : OpsSource { override val ops: GqlOps get() = currentOps }+ val httpGql = HttpGql(this.http, liveOps, fallback = BridgeGql(bridge, liveOps))+ private val gql: Gql = httpGql++ fun updateOps(newOps: GqlOps) { currentOps = newOps }++ override val ready: StateFlow<Boolean> = bridge.ready+ override val player = SpotifyPlayer(bridge, scope)+ override val search = SpotifySearch(gql)+ override val catalog = SpotifyCatalog(gql, this.http)+ override val library = SpotifyLibrary(bridge, gql)+ override val playlists = SpotifyPlaylists(gql, bridge, this.http)+ override val home = SpotifyHome(gql)+ override val podcasts = SpotifyPodcasts(gql, bridge)+ override val users = SpotifyUsers(gql, bridge, this.http)+ override val extras = SpotifyTrackExtras(gql, bridge, this.http)+ override val devices = SpotifyDevices(bridge)+ override val jam = SpotifyJam(bridge)++ /** Escape hatch to the 179 GraphQL operations and 89 page services, for what is not typed yet. */+ val raw = Raw()++ inner class Raw {+ suspend fun gql(operation: String, variables: JsonObject): JsonElement = gql.query(operation, variables)+ val operations: Set<String> get() = currentOps.names+ suspend fun service(service: String, method: String, vararg args: JsonElement): JsonElement = bridge.service(service, method, *args)+ suspend fun get(url: String): JsonElement? = http.getJson(url)+ }++ init {+ scope.launch {+ // Each page load may be another account (logout, then a new sign-in): the next+ // direct call asks the page for its current token.+ ready.filter { it }.collect { [email protected](); runCatching { player.refresh() } }+ }+ }++ suspend fun onPageLoaded() = bridge.inject()++ suspend fun awaitReady() { ready.first { it } }+}diff --git a/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyContent.kt b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyContent.ktnew file mode 100644index 00000000..a24f29bc--- /dev/null+++ b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyContent.kt@@ -0,0 +1,199 @@+package app.myspoti.spotify++import app.myspoti.api.Album+import app.myspoti.api.AlbumRef+import app.myspoti.api.Artist+import app.myspoti.api.Catalog+import app.myspoti.api.Episode+import app.myspoti.api.MediaCard+import app.myspoti.api.Page+import app.myspoti.api.Playlist+import app.myspoti.api.Search+import app.myspoti.api.SearchResults+import app.myspoti.api.Track+import app.myspoti.api.Uri+import app.myspoti.spotify.gql.Gql+import app.myspoti.spotify.gql.GqlException+import kotlinx.coroutines.async+import kotlinx.coroutines.coroutineScope+import kotlinx.serialization.json.JsonArray+import kotlinx.serialization.json.JsonElement+import kotlinx.serialization.json.JsonNull+import kotlinx.serialization.json.JsonObject+import kotlinx.serialization.json.JsonPrimitive++/** Builds GraphQL variables from plain Kotlin values (maps and lists nest). */+internal fun vars(vararg pairs: Pair<String, Any?>): JsonObject = JsonObject(pairs.associate { (k, v) -> k to json(v) })++internal fun json(v: Any?): JsonElement = when (v) {+ null -> JsonNull+ is JsonElement -> v+ is String -> JsonPrimitive(v)+ is Number -> JsonPrimitive(v)+ is Boolean -> JsonPrimitive(v)+ is Map<*, *> -> JsonObject(v.entries.associate { (k, x) -> k.toString() to json(x) })+ is List<*> -> JsonArray(v.map(::json))+ else -> error("unsupported value $v")+}++/** The entity at [path], or an error when the server says it does not exist. */+internal fun JsonElement.entity(path: String, op: String): JsonElement {+ val e = at(path) ?: throw GqlException(op, "no $path")+ if (e.typename() == "NotFound") throw GqlException(op, "not found")+ return e+}++class SpotifySearch(private val gql: Gql) : Search {+ private fun tabVars(query: String, offset: Int, limit: Int) = vars(+ "searchTerm" to query, "offset" to offset, "limit" to limit, "numberOfTopResults" to limit,+ "includeAudiobooks" to true, "includeAuthors" to true, "includePreReleases" to false,+ "includeAlbumPreReleases" to false, "includeEpisodeContentRatingsV2" to true,+ )++ override suspend fun tracks(query: String, offset: Int, limit: Int): Page<Track> =+ page(gql.query("searchTracks", tabVars(query, offset, limit)).at("data.searchV2.tracksV2"), offset) { track(it.at("item.data")) }++ override suspend fun artists(query: String, offset: Int, limit: Int): Page<Artist> =+ page(gql.query("searchArtists", tabVars(query, offset, limit)).at("data.searchV2.artists"), offset) { artist(it.at("data")) }++ override suspend fun albums(query: String, offset: Int, limit: Int): Page<Album> =+ page(gql.query("searchAlbums", tabVars(query, offset, limit)).at("data.searchV2.albumsV2"), offset) { album(it.at("data")) }++ override suspend fun playlists(query: String, offset: Int, limit: Int): Page<Playlist> =+ page(gql.query("searchPlaylists", tabVars(query, offset, limit)).at("data.searchV2.playlists"), offset) { playlist(it.at("data")) }++ override suspend fun shows(query: String, offset: Int, limit: Int): Page<MediaCard> =+ page(gql.query("searchPodcasts", tabVars(query, offset, limit)).at("data.searchV2.podcasts"), offset, ::card)++ override suspend fun episodes(query: String, offset: Int, limit: Int): Page<Episode> =+ page(gql.query("searchFullEpisodes", vars(+ "searchTerm" to query, "offset" to offset, "limit" to limit, "includeEpisodeContentRatingsV2" to true,+ )).at("data.searchV2.episodes"), offset) { episode(it.at("data")) }++ override suspend fun audiobooks(query: String, offset: Int, limit: Int): Page<MediaCard> =+ page(gql.query("searchAudiobooks", tabVars(query, offset, limit)).at("data.searchV2.audiobooks"), offset, ::card)++ override suspend fun users(query: String, offset: Int, limit: Int): Page<MediaCard> =+ page(gql.query("searchUsers", tabVars(query, offset, limit)).at("data.searchV2.users"), offset, ::card)++ override suspend fun genres(query: String, offset: Int, limit: Int): Page<MediaCard> =+ page(gql.query("searchGenres", tabVars(query, offset, limit)).at("data.searchV2.genres"), offset, ::card)++ /** The four music tabs in parallel: one round trip of wall time. */+ override suspend fun all(query: String, limit: Int): SearchResults = coroutineScope {+ val t = async { tracks(query, 0, limit) }+ val ar = async { artists(query, 0, limit) }+ val al = async { albums(query, 0, limit) }+ val p = async { playlists(query, 0, limit) }+ SearchResults(t.await(), ar.await(), al.await(), p.await())+ }++ override suspend fun suggestions(query: String, limit: Int): List<String> {+ val r = gql.query("searchSuggestions", vars(+ "query" to query, "limit" to limit, "numberOfTopResults" to limit, "offset" to 0,+ "includeAuthors" to true, "includeAlbumPreReleases" to false, "includeEpisodeContentRatingsV2" to true,+ ))+ return r.list("data.searchV2.topResultsV2.itemsV2").mapNotNull { hit ->+ val item = hit.at("item")+ if (item.typename() == "SearchAutoCompleteEntity") item.str("text") ?: item.str("data.text") else null+ }+ }++ override suspend fun recent(): List<MediaCard> =+ gql.query("recentSearches", vars("limit" to 50, "includeAuthors" to true, "includeEpisodeContentRatingsV2" to true))+ .list("data.recentSearches.recentSearchesItems.items").mapNotNull(::card)++ override suspend fun clearRecent() {+ val uris = recent().map { it.uri }+ if (uris.isNotEmpty()) gql.query("removeRecentSearches", vars("uris" to uris))+ }+}++class SpotifyCatalog(private val gql: Gql, private val http: app.myspoti.spotify.gql.SpotifyHttp? = null) : Catalog {+ /** spclient metadata/4 knows the ISRC; the public Web API is rate-limited for web tokens. */+ override suspend fun isrc(trackUri: Uri): String? {+ val client = http ?: return null+ val hex = base62ToHex(trackUri.substringAfterLast(':'))+ val meta = client.getJson("https://spclient.wg.spotify.com/metadata/4/track/$hex?market=from_token") ?: return null+ return meta.list("external_id").firstOrNull { it.str("type") == "isrc" }?.str("id")+ }++ override suspend fun track(uri: Uri): Track =+ track(gql.query("getTrack", vars("uri" to uri, "includeVideoAssociationItems" to false)).entity("data.trackUnion", "getTrack"))+ ?: throw GqlException("getTrack", "bad track")++ private suspend fun albumUnion(uri: Uri, offset: Int, limit: Int) =+ gql.query("getAlbum", vars("uri" to uri, "locale" to "", "offset" to offset, "limit" to limit)).entity("data.albumUnion", "getAlbum")++ override suspend fun album(uri: Uri): Album =+ album(albumUnion(uri, 0, 1)) ?: throw GqlException("getAlbum", "bad album")++ override suspend fun albumTracks(uri: Uri, offset: Int, limit: Int): Page<Track> {+ val a = albumUnion(uri, offset, limit)+ val cover = album(a)+ return page(a.at("tracksV2"), offset) { row ->+ track(row.at("track"), row.str("uid"))?.let { t ->+ t.copy(album = t.album ?: cover?.let { AlbumRef(it.uri, it.name, it.images) })+ }+ }+ }++ private suspend fun artistUnion(uri: Uri) =+ gql.query("queryArtistOverview", vars("uri" to uri, "locale" to "", "preReleaseV2" to false)).entity("data.artistUnion", "queryArtistOverview")++ override suspend fun artist(uri: Uri): Artist {+ val a = artistUnion(uri)+ return artist(a)?.copy(verified = a.bool("onPlatformReputationTrait.verification.isVerified") ?: false)+ ?: throw GqlException("queryArtistOverview", "bad artist")+ }++ override suspend fun artistTopTracks(uri: Uri): List<Track> =+ artistUnion(uri).list("discography.topTracks.items").mapNotNull { track(it.at("track"), it.str("uid")) }++ override suspend fun artistPage(uri: Uri): app.myspoti.api.ArtistPage {+ val a = artistUnion(uri)+ val base = artist(a)?.copy(verified = a.bool("onPlatformReputationTrait.verification.isVerified") ?: false)+ ?: throw GqlException("queryArtistOverview", "bad artist")+ return app.myspoti.api.ArtistPage(+ artist = base,+ biography = a.str("profile.biography.text")?.let { stripTags(it) },+ headerImages = images(a.list("headerImage.data.sources")),+ topTracks = a.list("discography.topTracks.items").mapNotNull { row ->+ track(row.at("track"), row.str("uid"))?.let { app.myspoti.api.TopTrack(it, row.long("track.playcount")) }+ },+ popularReleases = a.list("discography.popularReleasesAlbums.items").mapNotNull { album(it) },+ appearsOn = a.list("relatedContent.appearsOn.items").mapNotNull(::release),+ related = a.list("relatedContent.relatedArtists.items").mapNotNull(::artist),+ )+ }++ private fun stripTags(html: String) = html.replace(Regex("<[^>]+>"), "").replace("&", "&").replace(""", "\"").replace("'", "'").trim()++ override suspend fun discography(uri: Uri, offset: Int, limit: Int): Page<Album> {+ val all = gql.query("queryArtistDiscographyAll", vars("uri" to uri, "offset" to offset, "limit" to limit, "order" to "DATE_DESC"))+ .entity("data.artistUnion", "queryArtistDiscographyAll").at("discography.all")+ return page(all, offset, ::release)+ }++ override suspend fun relatedArtists(uri: Uri): List<Artist> =+ gql.query("queryArtistRelated", vars("uri" to uri)).entity("data.artistUnion", "queryArtistRelated")+ .list("relatedContent.relatedArtists.items").mapNotNull(::artist)++ override suspend fun appearsOn(uri: Uri): List<Album> =+ gql.query("queryArtistAppearsOn", vars("uri" to uri)).entity("data.artistUnion", "queryArtistAppearsOn")+ .list("relatedContent.appearsOn.items").mapNotNull(::release)++ override suspend fun similarAlbums(trackUri: Uri, limit: Int): List<Album> =+ gql.query("similarAlbumsBasedOnThisTrack", vars("uri" to trackUri, "limit" to limit, "albumsOnly" to true))+ .list("data.seoRecommendedTrackAlbum.items").mapNotNull { album(it.at("data")) }+}++private const val BASE62 = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"++/** Spotify's base62 id -> the 32-char hex gid used by metadata/4. */+internal fun base62ToHex(id: String): String {+ var n = java.math.BigInteger.ZERO+ val radix = java.math.BigInteger.valueOf(62)+ for (c in id) n = n.multiply(radix).add(java.math.BigInteger.valueOf(BASE62.indexOf(c).toLong()))+ return n.toString(16).padStart(32, '0')+}diff --git a/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyLibrary.kt b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyLibrary.ktnew file mode 100644index 00000000..71e0e869--- /dev/null+++ b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyLibrary.kt@@ -0,0 +1,249 @@+package app.myspoti.spotify++import app.myspoti.api.Image+import app.myspoti.api.Library+import app.myspoti.api.LibraryFilter+import app.myspoti.api.LibraryItem+import app.myspoti.api.LibrarySort+import app.myspoti.api.MediaKind+import app.myspoti.api.Page+import app.myspoti.api.Playlist+import app.myspoti.api.Playlists+import app.myspoti.api.SavedTrack+import app.myspoti.api.Track+import app.myspoti.api.Uri+import app.myspoti.spotify.bridge.Bridge+import app.myspoti.spotify.bridge.service+import app.myspoti.spotify.gql.Gql+import app.myspoti.spotify.gql.GqlException+import app.myspoti.spotify.gql.SpotifyHttp+import kotlinx.coroutines.flow.MutableSharedFlow+import kotlinx.coroutines.flow.SharedFlow+import kotlinx.serialization.json.JsonArray+import kotlinx.serialization.json.JsonElement+import kotlinx.serialization.json.JsonPrimitive+import kotlinx.serialization.json.boolean+import kotlinx.serialization.json.jsonPrimitive++private fun uris(list: List<Uri>) = json(mapOf("uris" to list))++class SpotifyLibrary(private val bridge: Bridge, private val gql: Gql) : Library {+ private val _changes = MutableSharedFlow<Unit>(extraBufferCapacity = 8)+ override val changes: SharedFlow<Unit> = _changes+ private fun changed() { _changes.tryEmit(Unit) }++ override suspend fun contains(uris: List<Uri>): List<Boolean> =+ (bridge.call("library.contains", uris(uris) as kotlinx.serialization.json.JsonObject) as JsonArray).map { it.jsonPrimitive.boolean }++ override suspend fun add(uris: List<Uri>) {+ bridge.call("library.add", uris(uris) as kotlinx.serialization.json.JsonObject); changed()+ }++ override suspend fun remove(uris: List<Uri>) {+ bridge.call("library.remove", uris(uris) as kotlinx.serialization.json.JsonObject); changed()+ }++ override suspend fun items(filter: LibraryFilter, sort: LibrarySort, folderUri: Uri?, offset: Int, limit: Int): Page<LibraryItem> {+ val lib = gql.query("libraryV3", vars(+ "filters" to listOfNotNull(filter.id),+ "order" to sort.id,+ "textFilter" to "",+ "features" to listOf("LIKED_SONGS", "YOUR_EPISODES_V2", "PRERELEASES", "PRERELEASES_V2", "CLIPS", "EVENTS"),+ "limit" to limit, "offset" to offset,+ "flatten" to false, "expandedFolders" to emptyList<String>(),+ "folderUri" to folderUri, "includeFoldersWhenFlattening" to true,+ )).entity("data.me.libraryV3", "libraryV3")+ val items = lib.list("items").mapNotNull { row ->+ val c = card(row.at("item")) ?: return@mapNotNull null+ val d = row.at("item.data")+ val kind = if (d.typename() == "Folder") MediaKind.FOLDER else c.kind+ LibraryItem(+ uri = if (kind == MediaKind.FOLDER) stableFolderUri(c.uri) else c.uri, kind = kind, name = c.title, subtitle = c.subtitle, images = c.images,+ pinned = row.bool("pinned") ?: false, addedAt = row.str("addedAt.isoString"),+ count = d.int("playlistCount")?.plus(d.int("folderCount") ?: 0) ?: d.int("count"),+ )+ }+ val total = lib.int("totalCount") ?: items.size+ return Page(items, offset, total, (offset + items.size).takeIf { items.isNotEmpty() && it < total })+ }++ override suspend fun likedTracks(offset: Int, limit: Int): Page<SavedTrack> {+ val page = gql.query("fetchLibraryTracks", vars("offset" to offset, "limit" to limit)).at("data.me.library.tracks")+ val items = page.list("items").mapNotNull { row ->+ val data = row.at("track.data")+ val withUri = if (data.str("uri") == null) row.str("track._uri")?.let { u ->+ kotlinx.serialization.json.JsonObject((data as kotlinx.serialization.json.JsonObject) + ("uri" to JsonPrimitive(u)))+ } else data+ track(withUri)?.let { SavedTrack(it, row.str("addedAt.isoString")) }+ }+ val total = page.int("totalCount") ?: items.size+ return Page(items, offset, total, (offset + items.size).takeIf { items.isNotEmpty() && it < total })+ }++ override suspend fun pin(uri: Uri) { gql.query("pinLibraryItem", vars("pinnableItemUri" to uri)); changed() }+ override suspend fun unpin(uri: Uri) { gql.query("unpinLibraryItem", vars("pinnableItemUri" to uri)); changed() }++ /**+ * Folders have two uri forms: `…:folder:{hash}` (stable, used by the library list and this API)+ * and `…:folder:{hash}:{name}` in the rootlist, which changes on rename. Writes need the latter.+ */+ private fun stableFolderUri(uri: Uri): Uri {+ val i = uri.indexOf(":folder:")+ if (i < 0) return uri+ val rest = uri.substring(i + ":folder:".length)+ return uri.substring(0, i) + ":folder:" + rest.substringBefore(':')+ }++ private suspend fun rootlistFolderUri(uri: Uri): Uri {+ val stable = stableFolderUri(uri)+ fun find(items: List<JsonElement>): Uri? {+ for (item in items) {+ if (item.str("type") != "folder") continue+ val u = item.str("uri") ?: continue+ if (stableFolderUri(u) == stable) return u+ find(item.list("items"))?.let { return it }+ }+ return null+ }+ return find(bridge.service("RootlistAPI", "getContents").list("items")) ?: throw GqlException("folder", "no folder $stable")+ }++ override suspend fun createFolder(name: String, parentFolderUri: Uri?): Uri {+ val r = bridge.service("RootlistAPI", "createFolder", JsonPrimitive(name), json(mapOf("before" to "start")))+ val uri = stableFolderUri(r.str("uri") ?: throw GqlException("createFolder", "no uri"))+ if (parentFolderUri != null) moveToFolder(uri, parentFolderUri)+ changed()+ return uri+ }++ override suspend fun renameFolder(folderUri: Uri, name: String) {+ bridge.service("RootlistAPI", "renameFolder", json(mapOf("uri" to rootlistFolderUri(folderUri))), JsonPrimitive(name)); changed()+ }++ override suspend fun deleteFolder(folderUri: Uri) {+ bridge.service("RootlistAPI", "removeFolder", JsonPrimitive(rootlistFolderUri(folderUri))); changed()+ }++ /** Right after a folder's start marker is inside the folder; "start" is the top level. */+ override suspend fun moveToFolder(uri: Uri, folderUri: Uri?) {+ val to = json(folderUri?.let { mapOf("after" to mapOf("uri" to rootlistFolderUri(it))) } ?: mapOf("before" to "start"))+ if (":folder:" in uri) bridge.service("RootlistAPI", "moveFolder", json(mapOf("uri" to rootlistFolderUri(uri))), to)+ else bridge.service("RootlistAPI", "move", json(listOf(mapOf("uri" to uri))), to)+ changed()+ }+}++class SpotifyPlaylists(private val gql: Gql, private val bridge: Bridge, private val http: SpotifyHttp) : Playlists {+ override suspend fun playlist(uri: Uri): Playlist =+ playlist(gql.query("fetchPlaylist", vars(+ "uri" to uri, "offset" to 0, "limit" to 1, "enableWatchFeedEntrypoint" to false, "includeEpisodeContentRatingsV2" to true,+ )).entity("data.playlistV2", "fetchPlaylist")) ?: throw GqlException("fetchPlaylist", "bad playlist")++ override suspend fun tracks(uri: Uri, offset: Int, limit: Int): Page<Track> {+ val p = gql.query("fetchPlaylistContents", vars(+ "uri" to uri, "offset" to offset, "limit" to limit, "includeEpisodeContentRatingsV2" to true,+ )).entity("data.playlistV2", "fetchPlaylistContents")+ val content = p.at("content")+ val items = content.list("items").mapNotNull { track(it.at("itemV2.data"), it.str("uid")) }+ val total = content.int("totalCount") ?: items.size+ return Page(items, offset, total, (offset + limit).takeIf { it < total })+ }++ private fun rootPlaylists(root: JsonElement): List<Playlist> {+ val out = mutableListOf<Playlist>()+ fun walk(items: List<JsonElement>) {+ for (item in items) when (item.str("type")) {+ "folder" -> walk(item.list("items"))+ else -> item.str("uri")?.takeIf { it.startsWith("spotify:playlist:") }?.let { uri ->+ out += Playlist(+ uri = uri,+ name = item.str("name") ?: "",+ description = item.str("description")?.ifBlank { null },+ owner = item.str("owner.displayName") ?: item.str("owner.name"),+ images = item.list("images").mapNotNull { i -> i.str("url")?.let { Image(it, i.int("width"), i.int("height")) } },+ trackCount = item.int("totalLength") ?: 0,+ editable = item.bool("isOwnedBySelf") ?: item.bool("canAdd") ?: false,+ )+ }+ }+ }+ walk(root.list("items"))+ return out+ }++ override suspend fun mine(): List<Playlist> = rootPlaylists(bridge.service("RootlistAPI", "getContents"))++ override suspend fun editable(): List<Playlist> {+ val me = bridge.service("UserAPI", "getUser").str("username")+ return mine().filter { it.editable || (me != null && it.owner == me) }+ }++ override suspend fun create(name: String): Uri {+ val r = bridge.service("RootlistAPI", "createPlaylist", JsonPrimitive(name), json(mapOf("before" to "start")))+ return r.str("uri") ?: (r as? JsonPrimitive)?.content ?: throw GqlException("createPlaylist", "no uri")+ }++ override suspend fun rename(uri: Uri, name: String) = updateDetails(uri, "name", name)++ override suspend fun setDescription(uri: Uri, description: String) = updateDetails(uri, "description", description)++ /** Two updates sent back to back can lose the second one: check it landed, and resend once. */+ private suspend fun updateDetails(uri: Uri, field: String, value: String) {+ repeat(2) {+ bridge.service("PlaylistAPI", "updateDetails", JsonPrimitive(uri), json(mapOf(field to value)))+ repeat(10) {+ if (bridge.service("PlaylistAPI", "getMetadata", JsonPrimitive(uri)).str(field) == value) return+ kotlinx.coroutines.delay(300)+ }+ }+ throw GqlException("updateDetails", "$field not applied")+ }++ override suspend fun delete(uri: Uri) = unfollow(uri)++ override suspend fun follow(uri: Uri) {+ bridge.service("RootlistAPI", "add", json(listOf(uri)), json(mapOf("before" to "start")))+ }++ override suspend fun unfollow(uri: Uri) {+ bridge.service("RootlistAPI", "remove", json(listOf(mapOf("uri" to uri))))+ }++ override suspend fun addTracks(uri: Uri, trackUris: List<Uri>) {+ gql.query("addToPlaylist", vars(+ "playlistItemUris" to trackUris, "playlistUri" to uri,+ "newPosition" to mapOf("moveType" to "BOTTOM_OF_PLAYLIST", "fromUid" to null),+ ))+ }++ override suspend fun removeTracks(uri: Uri, uids: List<String>) {+ gql.query("removeFromPlaylist", vars("playlistUri" to uri, "uids" to uids))+ }++ override suspend fun moveTracks(uri: Uri, uids: List<String>, beforeUid: String?) {+ val position = if (beforeUid == null) mapOf("moveType" to "BOTTOM_OF_PLAYLIST", "fromUid" to null)+ else mapOf("moveType" to "BEFORE_UID", "fromUid" to beforeUid)+ gql.query("moveItemsInPlaylist", vars("playlistUri" to uri, "uids" to uids, "newPosition" to position))+ }++ /** The "Recommended songs" list under an own playlist (playlistextender). */+ override suspend fun recommended(uri: Uri, limit: Int): List<Track> {+ val body = json(mapOf("playlistURI" to uri, "trackSkipIDs" to emptyList<String>(), "numResults" to limit)).toString()+ val (code, text) = http.send("POST", "https://spclient.wg.spotify.com/playlistextender/extendp/", body, contentType = "application/json")+ if (code != 200) throw app.myspoti.spotify.gql.HttpException(code, text.take(200))+ return Bridge.json.parseToJsonElement(text).list("recommendedTracks").mapNotNull { t ->+ val uri = t.str("originalId") ?: t.str("id")?.let { "spotify:track:$it" } ?: return@mapNotNull null+ Track(+ uri = uri,+ name = t.str("name") ?: "",+ durationMs = t.long("duration") ?: 0,+ artists = t.list("artists").mapNotNull { a -> a.str("id")?.let { app.myspoti.api.ArtistRef("spotify:artist:$it", a.str("name") ?: "") } },+ album = t.obj("album")?.let { a ->+ app.myspoti.api.AlbumRef("spotify:album:" + (a.str("id") ?: ""), a.str("name") ?: "",+ listOfNotNull(a.str("largeImageUrl")?.let { Image(it, 640, 640) }, a.str("imageUrl")?.let { Image(it, 300, 300) }))+ },+ explicit = t.bool("explicit") ?: false,+ )+ }+ }+}diff --git a/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyMore.kt b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyMore.ktnew file mode 100644index 00000000..e211a4b9--- /dev/null+++ b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyMore.kt@@ -0,0 +1,390 @@+package app.myspoti.spotify++import app.myspoti.api.Account+import app.myspoti.api.Audiobook+import app.myspoti.api.BrowsePage+import app.myspoti.api.Canvas+import app.myspoti.api.Category+import app.myspoti.api.CreditRole+import app.myspoti.api.Credits+import app.myspoti.api.Device+import app.myspoti.api.Devices+import app.myspoti.api.Episode+import app.myspoti.api.FriendActivity+import app.myspoti.api.HistoryEntry+import app.myspoti.api.Home+import app.myspoti.api.HomeFeed+import app.myspoti.api.HomeFilter+import app.myspoti.api.Image+import app.myspoti.api.Jam+import app.myspoti.api.JamAvailability+import app.myspoti.api.JamMember+import app.myspoti.api.JamSession+import app.myspoti.api.Lyrics+import app.myspoti.api.LyricsLine+import app.myspoti.api.LyricsWord+import app.myspoti.api.MediaKind+import app.myspoti.api.Page+import app.myspoti.api.Podcasts+import app.myspoti.api.Shelf+import app.myspoti.api.Show+import app.myspoti.api.TimeRange+import app.myspoti.api.TopContent+import app.myspoti.api.TrackExtras+import app.myspoti.api.UserProfile+import app.myspoti.api.UserRef+import app.myspoti.api.Users+import app.myspoti.api.Uri+import app.myspoti.api.ArtistRef+import app.myspoti.spotify.bridge.Bridge+import app.myspoti.spotify.bridge.service+import app.myspoti.spotify.gql.Gql+import app.myspoti.spotify.gql.GqlException+import app.myspoti.spotify.gql.SpotifyHttp+import kotlinx.coroutines.async+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.StateFlow+import kotlinx.serialization.json.JsonArray+import kotlinx.serialization.json.JsonElement+import kotlinx.serialization.json.JsonPrimitive+import kotlinx.serialization.json.boolean+import kotlinx.serialization.json.jsonPrimitive+import java.net.URLEncoder+import java.util.TimeZone++private fun idOf(uri: Uri) = uri.substringAfterLast(':')++private fun shelf(section: JsonElement): Shelf? {+ val items = section.list("sectionItems.items").mapNotNull { card(it.at("content")) }+ if (items.isEmpty()) return null+ return Shelf(+ uri = section.str("uri"),+ title = section.str("data.title.transformedLabel") ?: section.str("data.title.text"),+ items = items,+ total = section.int("sectionItems.totalCount") ?: items.size,+ )+}++class SpotifyHome(private val gql: Gql) : Home {+ override suspend fun feed(filter: HomeFilter, itemsPerShelf: Int): HomeFeed {+ val home = gql.query("home", vars(+ "timeZone" to TimeZone.getDefault().id, "sp_t" to "", "facet" to filter.facet,+ "sectionItemsLimit" to itemsPerShelf, "homeEndUserIntegration" to "INTEGRATION_WEB_PLAYER",+ "includeEpisodeContentRatingsV2" to true, "includeHomeChapterVideoCards" to false,+ )).entity("data.home", "home")+ val filters = home.list("homeChips").mapNotNull { chip -> HomeFilter.entries.firstOrNull { it.facet == chip.str("id") } }+ return HomeFeed(+ greeting = home.str("greeting.transformedLabel") ?: "",+ filters = listOf(HomeFilter.ALL) + filters,+ shelves = home.list("sectionContainer.sections.items").mapNotNull(::shelf),+ )+ }++ override suspend fun categories(): List<Category> =+ gql.query("browseAll", vars(+ "pagePagination" to mapOf("offset" to 0, "limit" to 10),+ "sectionPagination" to mapOf("offset" to 0, "limit" to 99),+ "browseEndUserIntegration" to "INTEGRATION_WEB_PLAYER",+ )).list("data.browseStart.sections.items").flatMap { it.list("sectionItems.items") }.mapNotNull { item ->+ val c = item.obj("content.data.data.cardRepresentation") ?: item.obj("content.data.cardRepresentation") ?: return@mapNotNull null+ val uri = item.str("uri") ?: return@mapNotNull null+ Category(uri, c.str("title.transformedLabel") ?: "", images(c.list("artwork.sources")), c.str("backgroundColor.hex"))+ }++ override suspend fun whatsNew(offset: Int, limit: Int): Page<app.myspoti.api.Album> {+ val feed = gql.query("queryWhatsNewFeed", vars("offset" to offset, "limit" to limit, "onlyUnPlayedItems" to false))+ .at("data.whatsNewFeedItems")+ return page(feed, offset) { item ->+ val d = item.at("content.data")+ album(d)?.let { a -> if (a.type == "ALBUM" && d.str("albumType") != null) a.copy(type = d.str("albumType")!!) else a }+ }+ }++ override suspend fun category(uri: Uri): BrowsePage {+ val page = gql.query("browsePage", vars(+ "uri" to uri, "pagePagination" to mapOf("offset" to 0, "limit" to 10),+ "sectionPagination" to mapOf("offset" to 0, "limit" to 20),+ "browseEndUserIntegration" to "INTEGRATION_WEB_PLAYER", "includeEpisodeContentRatingsV2" to true,+ )).entity("data.browse", "browsePage")+ return BrowsePage(uri, page.str("header.title.transformedLabel") ?: "", page.list("sections.items").mapNotNull(::shelf))+ }+}++class SpotifyPodcasts(private val gql: Gql, private val bridge: Bridge) : Podcasts {+ private suspend fun showUnion(uri: Uri) = gql.query("queryShowMetadataV2", vars(+ "uri" to uri, "includeContentCapabilityTrait" to true, "includeEpisodeContentRatingsV2" to true,+ )).entity("data.podcastUnionV2", "queryShowMetadataV2")++ override suspend fun show(uri: Uri): Show = show(showUnion(uri)) ?: throw GqlException("queryShowMetadataV2", "bad show")++ override suspend fun episodes(uri: Uri, offset: Int, limit: Int): Page<Episode> {+ val e = gql.query("queryPodcastEpisodes", vars("uri" to uri, "offset" to offset, "limit" to limit, "includeEpisodeContentRatingsV2" to true))+ .entity("data.podcastUnionV2", "queryPodcastEpisodes").at("episodesV2")+ return page(e, offset) { episode(it.at("entity.data")) }+ }++ override suspend fun episode(uri: Uri): Episode =+ episode(gql.query("getEpisodeOrChapter", vars("uri" to uri, "includeEpisodeContentRatingsV2" to true))+ .entity("data.episodeUnionV2", "getEpisodeOrChapter")) ?: throw GqlException("getEpisodeOrChapter", "bad episode")++ override suspend fun audiobook(uri: Uri): Audiobook {+ val d = showUnion(uri)+ return Audiobook(+ uri = d.str("uri") ?: uri,+ name = d.str("name") ?: "",+ authors = d.list("authorsV2").mapNotNull { it.str("name") }.ifEmpty { d.list("authors").mapNotNull { it.str("name") } },+ narrators = d.list("narrators.items").mapNotNull { it.str("name") },+ description = d.str("description"),+ images = images(d.list("coverArt.sources")),+ chapterCount = d.int("chaptersV2.totalCount") ?: d.int("episodesV2.totalCount") ?: 0,+ )+ }++ override suspend fun chapters(uri: Uri, offset: Int, limit: Int): Page<Episode> {+ val d = gql.query("queryBookChapters", vars("uri" to uri, "offset" to offset, "limit" to limit))+ .entity("data.podcastUnionV2", "queryBookChapters")+ val list = d.at("chaptersV2") ?: d.at("episodesV2")+ return page(list, offset) { episode(it.at("entity.data") ?: it.at("data")) }+ }++ /** "Your Episodes" is the `listenlater` collection set; details are loaded in parallel. */+ override suspend fun savedEpisodes(offset: Int, limit: Int): Page<Episode> {+ // The page's own get() throws on an empty set: that means no saved episodes.+ val raw = runCatching { bridge.service("CollectionPlatformAPI", "get", JsonPrimitive("listenlater")) }.getOrNull()+ val saved = (raw as? JsonArray).orEmpty()+ .sortedByDescending { it.long("addTime") ?: 0 }+ .mapNotNull { it.str("uri") }+ val slice = saved.drop(offset).take(limit)+ val items = kotlinx.coroutines.coroutineScope {+ slice.map { uri -> async { runCatching { episode(uri) }.getOrNull() } }.map { it.await() }+ }.filterNotNull()+ return Page(items, offset, saved.size, (offset + slice.size).takeIf { it < saved.size })+ }+}++class SpotifyUsers(private val gql: Gql, private val bridge: Bridge, private val http: SpotifyHttp) : Users {+ override suspend fun me(): Account {+ val p = gql.query("profileAttributes", vars()).at("data.me.profile")+ val a = gql.query("accountAttributes", vars()).at("data.me.account")+ return Account(+ uri = p.str("uri") ?: "",+ username = p.str("username") ?: "",+ name = p.str("name") ?: p.str("username") ?: "",+ images = images(p.list("avatar.sources")),+ premium = a.str("product")?.equals("FREE", ignoreCase = true) == false,+ country = a.str("country"),+ )+ }++ override suspend fun profile(userUri: Uri): UserProfile {+ val id = URLEncoder.encode(idOf(userUri), "UTF-8")+ val p = http.getJson("https://spclient.wg.spotify.com/user-profile-view/v3/profile/$id?playlist_limit=50&artist_limit=10&episode_limit=10&market=from_token")+ ?: throw GqlException("user-profile-view", "not found")+ return UserProfile(+ uri = p.str("uri") ?: userUri,+ name = p.str("name") ?: idOf(userUri),+ images = listOfNotNull(p.str("image_url")?.let { Image(it) }),+ followers = p.int("followers_count"),+ following = p.int("following_count"),+ publicPlaylists = p.list("public_playlists").mapNotNull { pl ->+ val uri = pl.str("uri") ?: return@mapNotNull null+ app.myspoti.api.Playlist(uri, pl.str("name") ?: "", null, pl.str("owner_name"),+ listOfNotNull(pl.str("image_url")?.let { Image(it) }), 0)+ },+ )+ }++ override suspend fun top(range: TimeRange, limit: Int): TopContent {+ val input = mapOf("offset" to 0, "limit" to limit, "sortBy" to "AFFINITY", "timeRange" to range.name)+ val p = gql.query("userTopContent", vars(+ "includeTopArtists" to true, "topArtistsInput" to input, "includeTopTracks" to true, "topTracksInput" to input,+ )).at("data.me.profile")+ return TopContent(+ artists = p.list("topArtists.items").mapNotNull { artist(it.at("data")) },+ tracks = p.list("topTracks.items").mapNotNull { track(it.at("data")) },+ )+ }++ override suspend fun follow(userUris: List<Uri>) { gql.query("followUsers", vars("usernames" to userUris.map(::idOf))) }+ override suspend fun unfollow(userUris: List<Uri>) { gql.query("unfollowUsers", vars("usernames" to userUris.map(::idOf))) }++ override suspend fun isFollowing(userUris: List<Uri>): List<Boolean> {+ val r = gql.query("isFollowingUsers", vars("uris" to userUris))+ val list = r.list("data.users")+ return userUris.map { u -> list.firstOrNull { it.str("uri") == u }?.bool("following") ?: false }+ }++ /** The Web Player has no friend feed; this reads the desktop client's presence endpoint and returns nothing when refused. */+ override suspend fun friendActivity(): List<FriendActivity> {+ val r = runCatching { http.getJson("https://spclient.wg.spotify.com/presence-view/v1/buddylist") }.getOrNull() ?: return emptyList()+ return r.list("friends").mapNotNull { f ->+ val user = f.obj("user") ?: return@mapNotNull null+ val t = f.obj("track")+ FriendActivity(+ user = UserRef(user.str("uri") ?: "", user.str("name") ?: "", user.str("imageUrl")),+ track = t?.let { tr ->+ app.myspoti.api.Track(tr.str("uri") ?: "", tr.str("name") ?: "", 0,+ listOfNotNull(tr.obj("artist")?.let { ArtistRef(it.str("uri") ?: "", it.str("name") ?: "") }),+ tr.obj("album")?.let { app.myspoti.api.AlbumRef(it.str("uri") ?: "", it.str("name") ?: "") })+ },+ contextUri = t?.str("context.uri"),+ timestampMs = f.long("timestamp") ?: 0,+ )+ }+ }++ override suspend fun history(): List<HistoryEntry> =+ (bridge.service("RecentlyPlayedAPI", "getContexts") as? JsonArray).orEmpty().mapNotNull { c ->+ val uri = c.str("uri") ?: return@mapNotNull null+ HistoryEntry(uri, MediaKind.of(uri), c.str("name") ?: "",+ c.list("images").mapNotNull { i -> i.str("url")?.let { Image(it, i.int("width"), i.int("height")) } },+ c.long("timestampMs"))+ }++ override suspend fun setPrivateSession(on: Boolean) {+ val supported = bridge.service("PrivateSessionAPI", "getCapabilities").bool("isSupported") ?: false+ if (!supported) throw UnsupportedOperationException("private session is not available in the Web Player")+ bridge.service("PrivateSessionAPI", "setPrivateSession", JsonPrimitive(on))+ }+}++class SpotifyTrackExtras(private val gql: Gql, private val bridge: Bridge, private val http: SpotifyHttp) : TrackExtras {+ override suspend fun lyrics(trackUri: Uri): Lyrics? {+ val r = http.getJson("https://spclient.wg.spotify.com/color-lyrics/v2/track/${idOf(trackUri)}?format=json&vocalRemoval=false&market=from_token")+ ?: return null+ val l = r.obj("lyrics") ?: return null+ val synced = l.str("syncType") != "UNSYNCED"+ val lines = l.list("lines").map { line ->+ val start = line.long("startTimeMs") ?: 0+ LyricsLine(+ startMs = start,+ endMs = line.long("endTimeMs")?.takeIf { it > 0 },+ text = line.str("words") ?: "",+ words = line.list("syllables").mapNotNull { s -> s.str("words")?.let { LyricsWord(s.long("startTimeMs") ?: start, it) } }.ifEmpty { null },+ )+ }.filter { it.text.isNotBlank() || synced }+ return Lyrics(lines, synced, l.str("language"), l.str("providerDisplayName") ?: l.str("provider"),+ r.int("colors.background"), r.int("colors.text"), r.int("colors.highlightText"))+ }++ override suspend fun canvas(trackUri: Uri): Canvas? {+ val c = gql.query("canvas", vars("trackUri" to trackUri)).obj("data.trackUnion.canvas") ?: return null+ val url = c.str("url") ?: return null+ return Canvas(c.str("uri") ?: "", url, c.str("type") ?: "")+ }++ override suspend fun credits(trackUri: Uri): Credits {+ val contributors = gql.query("queryTrackCreditsGroupedModal", vars("trackUri" to trackUri))+ .list("data.trackUnion.creditsTrait.contributors.items")+ val roles = contributors.groupBy { it.str("role") ?: it.str("roleGroup.name") ?: "" }.map { (role, people) ->+ CreditRole(role, people.map { ArtistRef(it.str("uri") ?: "", it.str("name") ?: "") })+ }+ return Credits(roles)+ }++ override suspend fun radio(seedUri: Uri): Uri? =+ http.getJson("https://spclient.wg.spotify.com/inspiredby-mix/v2/seed_to_playlist/$seedUri?response-format=json")+ ?.list("mediaItems")?.firstOrNull()?.str("uri")++ override suspend fun setExcludedFromTaste(trackUri: Uri, excluded: Boolean) {+ bridge.service("CollectionPlatformAPI", if (excluded) "add" else "remove", JsonPrimitive("ignoreinrecs"), json(listOf(trackUri)))+ }++ /** Asks the server: the page's own contains() answers from a cache that removals do not clear. */+ override suspend fun isExcludedFromTaste(trackUris: List<Uri>): List<Boolean> {+ val username = bridge.service("UserAPI", "getUser").str("username") ?: throw GqlException("collection", "no user")+ val body = json(mapOf("username" to username, "set" to "ignoreinrecs", "items" to trackUris.map { mapOf("uri" to it) })).toString()+ val (code, text) = http.send("POST", "https://spclient.wg.spotify.com/collection/v2/contains?market=from_token", body, contentType = "application/json")+ if (code != 200) throw app.myspoti.spotify.gql.HttpException(code, text.take(200))+ return Bridge.json.parseToJsonElement(text).list("found").map { (it as? JsonPrimitive)?.content == "true" }+ }+}++class SpotifyDevices(private val bridge: Bridge) : Devices {+ private val _devices = MutableStateFlow<List<Device>>(emptyList())+ override val devices: StateFlow<List<Device>> = _devices++ override suspend fun refresh() {+ _devices.value = (bridge.service("ConnectDevicesAPI", "getDevices") as? JsonArray).orEmpty().mapNotNull { d ->+ Device(+ id = d.str("id") ?: return@mapNotNull null,+ name = d.str("name") ?: "",+ type = d.str("type") ?: "unknown",+ active = d.bool("isActive") ?: false,+ volume = d.double("volume"),+ local = d.bool("isLocal") ?: false,+ )+ }+ }++ override suspend fun transfer(deviceId: String, play: Boolean) {+ bridge.service("ConnectTransferAPI", "transferPlayback", JsonPrimitive(deviceId), json(mapOf("playOnTransfer" to play)))+ refresh()+ }++ override suspend fun pullHere() {+ bridge.service("ConnectTransferAPI", "pullToLocalDevice", json(mapOf<String, Any>()))+ refresh()+ }+}++/** Jam goes through the page's SocialConnectAPI. Free accounts get RESTRICTED from Spotify. */+class SpotifyJam(private val bridge: Bridge) : Jam {+ private val _session = MutableStateFlow<JamSession?>(null)+ override val session: StateFlow<JamSession?> = _session++ override suspend fun availability(): JamAvailability =+ when ((bridge.service("SocialConnectAPI", "getEnabled") as? JsonPrimitive)?.content) {+ "ENABLED", "AVAILABLE" -> JamAvailability.AVAILABLE+ "RESTRICTED", "DISABLED" -> JamAvailability.RESTRICTED+ else -> JamAvailability.UNKNOWN+ }++ private fun parse(s: JsonElement?): JamSession? {+ val id = s.str("session_id") ?: s.str("sessionId") ?: return null+ val members = (s.list("session_members").ifEmpty { s.list("sessionMembers") }).map { m ->+ JamMember(+ userUri = "spotify:user:" + (m.str("username") ?: m.str("id") ?: ""),+ name = m.str("display_name") ?: m.str("displayName") ?: m.str("username") ?: "",+ imageUrl = m.str("image_url") ?: m.str("imageUrl") ?: m.str("large_image_url"),+ host = m.bool("is_host") ?: m.bool("isHost") ?: (m.str("username") == s.str("session_owner_id")),+ )+ }+ return JamSession(+ id = id,+ joinToken = s.str("join_session_token") ?: s.str("joinSessionToken"),+ inviteLink = null,+ members = members,+ isHost = s.bool("is_session_owner") ?: s.bool("isSessionOwner") ?: false,+ queueOnly = s.bool("queue_only_mode") ?: s.bool("queueOnlyMode") ?: false,+ )+ }++ override suspend fun refresh() { _session.value = parse(bridge.service("SocialConnectAPI", "fetchCurrentSession")) }++ override suspend fun start(): JamSession {+ if (availability() == JamAvailability.RESTRICTED) throw UnsupportedOperationException("Jam is restricted on this account")+ val s = parse(bridge.service("SocialConnectAPI", "createSession")) ?: throw GqlException("jam", "no session")+ _session.value = s+ return s+ }++ override suspend fun join(joinToken: String): JamSession {+ bridge.service("SocialConnectAPI", "joinSession", JsonPrimitive(joinToken))+ refresh()+ return _session.value ?: throw GqlException("jam", "join failed")+ }++ override suspend fun leave() { bridge.service("SocialConnectAPI", "leaveSession"); _session.value = null }+ override suspend fun end() { bridge.service("SocialConnectAPI", "deleteSession"); _session.value = null }++ override suspend fun inviteLink(): String? {+ val id = _session.value?.id ?: return null+ val r = bridge.service("SocialConnectAPI", "getShortInviteLink", JsonPrimitive(id))+ return (r as? JsonPrimitive)?.content ?: r.str("shareUrl") ?: r.str("url")+ }++ override suspend fun removeMember(userUri: Uri) { bridge.service("SocialConnectAPI", "removeSessionMember", JsonPrimitive(idOf(userUri))); refresh() }+ override suspend fun setQueueOnly(on: Boolean) { bridge.service("SocialConnectAPI", "setQueueOnlyMode", JsonPrimitive(on)); refresh() }+ override suspend fun setParticipantVolumeControl(on: Boolean) { bridge.service("SocialConnectAPI", "setParticipantVolumeControl", JsonPrimitive(on)) }+}diff --git a/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyPlayer.kt b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyPlayer.ktnew file mode 100644index 00000000..10009477--- /dev/null+++ b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/SpotifyPlayer.kt@@ -0,0 +1,143 @@+package app.myspoti.spotify++import app.myspoti.api.ItemKind+import app.myspoti.api.NowPlaying+import app.myspoti.api.Player+import app.myspoti.api.PlayerState+import app.myspoti.api.Queue+import app.myspoti.api.Repeat+import app.myspoti.api.Uri+import app.myspoti.spotify.bridge.Bridge+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.Job+import kotlinx.coroutines.delay+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.StateFlow+import kotlinx.coroutines.launch+import kotlinx.serialization.json.JsonObject+import kotlinx.serialization.json.addJsonObject+import kotlinx.serialization.json.buildJsonObject+import kotlinx.serialization.json.double+import kotlinx.serialization.json.jsonPrimitive+import kotlinx.serialization.json.put+import kotlinx.serialization.json.putJsonArray++/**+ * The Web Player's own player, driven through the bridge.+ *+ * Ads: hosts refuse the ad audio, so the page skips an ad within a second. If an ad item+ * still stays current longer than [AD_GRACE_MS] (new ad host, video ad), the next real+ * track is played. Ads are never exposed in [state].+ */+class SpotifyPlayer(private val bridge: Bridge, private val scope: CoroutineScope) : Player {+ private val _state = MutableStateFlow<PlayerState?>(null)+ override val state: StateFlow<PlayerState?> = _state+ private val _queue = MutableStateFlow<Queue?>(null)+ override val queue: StateFlow<Queue?> = _queue++ private var lastTrackState: PlayerState? = null+ private var adWatch: Job? = null++ init {+ scope.launch {+ bridge.events.collect { (type, payload) ->+ when (type) {+ "state" -> onState(playerState(payload))+ "queue" -> queue(payload)?.let { q -> _queue.value = q.copy(nextUp = q.nextUp.filter { it.kind != ItemKind.AD }) }+ }+ }+ }+ }++ private fun onState(s: PlayerState?) {+ if (s?.item?.kind == ItemKind.AD) {+ // Keep showing the last real track, buffering, while the ad is being dropped.+ _state.value = lastTrackState?.copy(isBuffering = true) ?: s.copy(item = null)+ if (adWatch?.isActive != true) adWatch = scope.launch { skipAdIfStuck(s.contextUri) }+ return+ }+ adWatch?.cancel()+ lastTrackState = s+ _state.value = s+ }++ private suspend fun skipAdIfStuck(contextUri: Uri?) {+ delay(AD_GRACE_MS)+ val next = _queue.value?.nextUp?.firstOrNull { it.kind == ItemKind.TRACK } ?: return+ if (contextUri != null) runCatching { play(contextUri, trackUri = next.uri) }+ }++ override suspend fun play(contextUri: Uri, trackUri: Uri?, index: Int?, positionMs: Long?) {+ bridge.call("player.play", buildJsonObject {+ put("contextUri", contextUri)+ trackUri?.let { put("trackUri", it) }+ index?.let { put("index", it) }+ positionMs?.let { put("positionMs", it) }+ })+ }++ override suspend fun pause() { bridge.call("player.pause") }+ override suspend fun resume() { bridge.call("player.resume") }+ override suspend fun seek(positionMs: Long) { bridge.call("player.seek", buildJsonObject { put("positionMs", positionMs) }) }+ override suspend fun next() { bridge.call("player.next") }+ override suspend fun previous() { bridge.call("player.previous") }+ override suspend fun setShuffle(on: Boolean) { bridge.call("player.setShuffle", buildJsonObject { put("on", on) }) }++ override suspend fun setRepeat(mode: Repeat) {+ bridge.call("player.setRepeat", buildJsonObject { put("mode", mode.ordinal) })+ }++ override suspend fun addToQueue(uris: List<Uri>) {+ bridge.call("queue.add", buildJsonObject { putJsonArray("uris") { uris.forEach { add(kotlinx.serialization.json.JsonPrimitive(it)) } } })+ }++ override suspend fun removeFromQueue(items: List<NowPlaying>) {+ bridge.call("queue.remove", buildJsonObject {+ putJsonArray("items") {+ items.forEach { item -> addJsonObject { put("uri", item.uri); item.uid?.let { put("uid", it) } } }+ }+ })+ }++ override suspend fun clearQueue() { bridge.call("queue.clear") }++ private fun ref(item: NowPlaying) = buildJsonObject { put("uri", item.uri); item.uid?.let { put("uid", it) } }++ override suspend fun skipTo(item: NowPlaying) { bridge.call("queue.skipTo", ref(item)) }++ override suspend fun playNext(uris: List<Uri>) {+ val first = _queue.value?.queued?.firstOrNull()+ if (first == null) { addToQueue(uris); return }+ bridge.call("queue.insert", buildJsonObject {+ putJsonArray("uris") { uris.forEach { add(kotlinx.serialization.json.JsonPrimitive(it)) } }+ put("before", ref(first))+ })+ }++ override suspend fun moveInQueue(item: NowPlaying, target: NowPlaying, after: Boolean) {+ bridge.call("queue.reorder", buildJsonObject {+ putJsonArray("items") { add(ref(item)) }+ put(if (after) "after" else "before", ref(target))+ })+ }++ override suspend fun setSpeed(speed: Double) {+ bridge.call("player.setSpeed", buildJsonObject { put("speed", speed.coerceIn(0.5, 3.5)) })+ }++ override suspend fun volume(): Double = bridge.call("volume.get").jsonPrimitive.double++ override suspend fun setVolume(level: Double) {+ bridge.call("volume.set", buildJsonObject { put("level", level.coerceIn(0.0, 1.0)) })+ }++ /** Pulls the state once, e.g. right after the bridge is ready. */+ suspend fun refresh() {+ onState(playerState(bridge.call("player.state") as? JsonObject))+ _queue.value = queue(bridge.call("player.queue"))+ }++ companion object {+ const val AD_GRACE_MS = 1_000L+ }+}diff --git a/base/api-spotify/src/main/kotlin/app/myspoti/spotify/bridge/Bridge.kt b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/bridge/Bridge.ktnew file mode 100644index 00000000..775e8171--- /dev/null+++ b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/bridge/Bridge.kt@@ -0,0 +1,109 @@+package app.myspoti.spotify.bridge++import kotlinx.coroutines.CompletableDeferred+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.flow.MutableSharedFlow+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.SharedFlow+import kotlinx.coroutines.flow.StateFlow+import kotlinx.coroutines.launch+import kotlinx.coroutines.withTimeout+import kotlinx.serialization.json.Json+import kotlinx.serialization.json.JsonElement+import kotlinx.serialization.json.JsonNull+import kotlinx.serialization.json.JsonObject+import kotlinx.serialization.json.boolean+import kotlinx.serialization.json.int+import kotlinx.serialization.json.jsonObject+import kotlinx.serialization.json.jsonPrimitive+import java.util.concurrent.ConcurrentHashMap+import java.util.concurrent.atomic.AtomicInteger++class BridgeException(message: String) : Exception(message)++/** Request/response over a [BridgeHost], plus the page's pushed events. */+class Bridge(private val host: BridgeHost, scope: CoroutineScope) {+ private val ids = AtomicInteger(0)++ /** Diagnostics: receives one line per call, result and page message. */+ @Volatile var logger: ((String) -> Unit)? = null+ private val pending = ConcurrentHashMap<Int, CompletableDeferred<JsonElement>>()++ private val _ready = MutableStateFlow(false)+ val ready: StateFlow<Boolean> = _ready++ /** `state` and `queue` messages, raw payload of each. */+ private val _events = MutableSharedFlow<Pair<String, JsonElement>>(extraBufferCapacity = 64)+ val events: SharedFlow<Pair<String, JsonElement>> = _events++ init {+ scope.launch {+ host.messages.collect { raw -> handle(raw) }+ }+ }++ private fun handle(raw: String) {+ val msg = runCatching { json.parseToJsonElement(raw).jsonObject }.getOrNull() ?: return+ logger?.let { log ->+ val type = msg["type"]?.jsonPrimitive?.content+ if (type == "state") {+ val s = msg["state"] as? JsonObject+ log("page state: " + (s?.get("track") as? JsonObject)?.get("name") + " paused=" + s?.get("isPaused") + " buffering=" + s?.get("isBuffering"))+ } else if (type == "result") {+ // Results are logged by call(); never write their values (tokens) here.+ } else if (type != "queue") log("page $type: " + raw.take(300))+ }+ when (msg["type"]?.jsonPrimitive?.content) {+ "ready" -> _ready.value = true+ "result" -> {+ val id = msg["id"]?.jsonPrimitive?.int ?: return+ val waiter = pending.remove(id) ?: return+ if (msg["ok"]?.jsonPrimitive?.boolean == true) waiter.complete(msg["value"] ?: JsonNull)+ else waiter.completeExceptionally(BridgeException(msg["error"]?.jsonPrimitive?.content ?: "bridge error"))+ }+ "state" -> _events.tryEmit("state" to (msg["state"] ?: JsonNull))+ "queue" -> _events.tryEmit("queue" to (msg["queue"] ?: JsonNull))+ "error" -> _ready.value = false+ }+ }++ /** Injects the bridge into the current page. Hosts call this after each page load. */+ suspend fun inject() {+ _ready.value = false+ host.evaluate(BridgeScript.source)+ }++ suspend fun call(method: String, args: JsonObject = JsonObject(emptyMap()), timeoutMs: Long = 20_000): JsonElement {+ val id = ids.incrementAndGet()+ val waiter = CompletableDeferred<JsonElement>()+ pending[id] = waiter+ try {+ val started = System.currentTimeMillis()+ logger?.invoke("call #$id $method ${args.toString().take(200)}")+ host.evaluate("window.Myspoti && window.Myspoti.call($id, ${json.encodeToString(JsonElement.serializer(), kotlinx.serialization.json.JsonPrimitive(method))}, $args).catch(() => {})")+ return try {+ withTimeout(timeoutMs) { waiter.await() }.also {+ val shown = if (method == "token.get") "(token hidden)" else it.toString().take(200)+ logger?.invoke("call #$id $method ok in ${System.currentTimeMillis() - started} ms: $shown")+ }+ } catch (e: Exception) {+ logger?.invoke("call #$id $method FAILED after ${System.currentTimeMillis() - started} ms: ${e.message}")+ throw e+ }+ } finally {+ pending.remove(id)+ }+ }++ companion object {+ val json = Json { ignoreUnknownKeys = true }+ }+}++/** Calls `service.method(...args)` on one of the page's services and returns its JSON copy. */+suspend fun Bridge.service(service: String, method: String, vararg args: JsonElement): JsonElement =+ call("service.call", kotlinx.serialization.json.buildJsonObject {+ put("service", kotlinx.serialization.json.JsonPrimitive(service))+ put("method", kotlinx.serialization.json.JsonPrimitive(method))+ put("args", kotlinx.serialization.json.JsonArray(args.toList()))+ })diff --git a/base/api-spotify/src/main/kotlin/app/myspoti/spotify/bridge/BridgeHost.kt b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/bridge/BridgeHost.ktnew file mode 100644index 00000000..fdc5ac1d--- /dev/null+++ b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/bridge/BridgeHost.kt@@ -0,0 +1,35 @@+package app.myspoti.spotify.bridge++import kotlinx.coroutines.flow.Flow++/**+ * Where the Web Player page runs: an Android WebView or desktop Chrome over CDP.+ *+ * A host loads open.spotify.com with the user's session, injects [BridgeScript] after each+ * page load, blocks ad audio ([AdBlock.blockedHosts]) and relays the page's messages.+ */+interface BridgeHost {+ /** Runs [script] in the page. Fire and forget: answers come back through [messages]. */+ suspend fun evaluate(script: String)++ /** JSON strings posted by the bridge (`MyspotiHost.post` / `__mspHostPost`). */+ val messages: Flow<String>+}++/** The bridge's source, bundled as a resource of this module. */+object BridgeScript {+ val source: String by lazy {+ BridgeScript::class.java.getResourceAsStream("/bridge/player-bridge.js")!!+ .bufferedReader().use { it.readText() }+ }+}++/** Requests every host refuses. Blocking the ad audio makes the player skip the ad itself. */+object AdBlock {+ val blockedHosts = listOf("adstudio-assets.scdn.co")++ fun isBlocked(url: String): Boolean {+ val host = url.substringAfter("://").substringBefore('/').substringBefore(':')+ return blockedHosts.any { host == it || host.endsWith(".$it") }+ }+}diff --git a/base/api-spotify/src/main/kotlin/app/myspoti/spotify/gql/Gql.kt b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/gql/Gql.ktnew file mode 100644index 00000000..3a8b9847--- /dev/null+++ b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/gql/Gql.kt@@ -0,0 +1,192 @@+package app.myspoti.spotify.gql++import app.myspoti.spotify.bridge.Bridge+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.sync.Mutex+import kotlinx.coroutines.sync.withLock+import kotlinx.coroutines.withContext+import kotlinx.serialization.json.JsonElement+import kotlinx.serialization.json.JsonObject+import kotlinx.serialization.json.JsonPrimitive+import kotlinx.serialization.json.buildJsonObject+import kotlinx.serialization.json.jsonArray+import kotlinx.serialization.json.jsonObject+import kotlinx.serialization.json.jsonPrimitive+import kotlinx.serialization.json.long+import kotlinx.serialization.json.put+import kotlinx.serialization.json.putJsonObject+import okhttp3.MediaType.Companion.toMediaType+import okhttp3.OkHttpClient+import okhttp3.Request+import okhttp3.RequestBody.Companion.toRequestBody+import java.util.UUID++class GqlException(val operation: String, message: String) : Exception("$operation: $message")++/** Persisted GraphQL operations of the Web Player: name -> hash. */+class GqlOps(private val hashes: Map<String, String>) {+ fun hash(name: String): String = hashes[name] ?: throw GqlException(name, "unknown operation")+ val names: Set<String> get() = hashes.keys++ companion object {+ fun bundled(): GqlOps {+ val text = GqlOps::class.java.getResourceAsStream("/spotify/gql-ops.json")!!.bufferedReader().use { it.readText() }+ val ops = Bridge.json.parseToJsonElement(text).jsonObject["operations"]!!.jsonObject+ return GqlOps(ops.mapValues { it.value.jsonObject["hash"]!!.jsonPrimitive.content })+ }+ }+}++/** Where the current operation table comes from (it can change while the app runs). */+interface OpsSource { val ops: GqlOps }++/** Runs a persisted GraphQL operation and returns the whole `{data: ...}` response. */+interface Gql {+ suspend fun query(name: String, variables: JsonObject): JsonElement+}++/** Through the page's own loader: always works once the page is ready, a bit slower. */+class BridgeGql(private val bridge: Bridge, private val source: OpsSource) : Gql {+ private val ops get() = source.ops+ override suspend fun query(name: String, variables: JsonObject): JsonElement =+ bridge.call("gql.query", buildJsonObject {+ put("name", name)+ put("hash", ops.hash(name))+ put("variables", variables)+ })+}++class HttpException(val code: Int, message: String) : Exception("HTTP $code: $message")++/**+ * Direct HTTP to Spotify with the Web Player's credentials: the web token from the bridge,+ * and a client token minted here and kept about 14 days.+ */+class SpotifyHttp(+ private val http: OkHttpClient,+ private val bridge: Bridge,+ private val language: String = "en",+) {+ private data class WebToken(val access: String, val expiresAtMs: Long, val clientId: String, val appVersion: String)+ private data class ClientToken(val value: String, val expiresAtMs: Long)++ private val lock = Mutex()+ private var web: WebToken? = null+ private var client: ClientToken? = null+ private val deviceId = UUID.randomUUID().toString()++ /** Drops the cached web token (it belongs to one account); the client token is kept. */+ suspend fun forgetWebToken() = lock.withLock { web = null }++ /** Sends a request with browser headers. Returns the status and body text. */+ suspend fun send(method: String, url: String, body: String? = null, contentType: String = JSON_TYPE, accept: String = "application/json"): Pair<Int, String> {+ val (w, c) = tokens()+ val builder = Request.Builder().url(url)+ .header("authorization", "Bearer ${w.access}")+ .header("client-token", c.value)+ .header("app-platform", "WebPlayer")+ .header("spotify-app-version", w.appVersion)+ .header("accept", accept)+ .header("accept-language", language)+ .header("origin", "https://open.spotify.com")+ .header("referer", "https://open.spotify.com/")+ .header("user-agent", USER_AGENT)+ // Bytes keep the content type exactly as given (OkHttp appends a charset to String bodies,+ // which some Spotify endpoints reject with 400).+ builder.method(method, body?.toByteArray()?.toRequestBody(contentType.toMediaType()) ?: if (method == "GET" || method == "DELETE") null else ByteArray(0).toRequestBody(null))+ val result = withContext(Dispatchers.IO) { http.newCall(builder.build()).execute().use { it.code to it.body.string() } }+ if (result.first == 401) lock.withLock { web = null }+ return result+ }++ suspend fun getJson(url: String): JsonElement? {+ val (code, text) = send("GET", url)+ return when (code) {+ 200 -> Bridge.json.parseToJsonElement(text)+ 204, 404 -> null+ else -> throw HttpException(code, text.take(200))+ }+ }++ private suspend fun tokens(): Pair<WebToken, ClientToken> = lock.withLock {+ val now = System.currentTimeMillis()+ val w = web?.takeIf { it.expiresAtMs - now > 60_000 } ?: run {+ val t = bridge.call("token.get").jsonObject+ WebToken(+ access = t["accessToken"]!!.jsonPrimitive.content,+ expiresAtMs = t["expiresAtMs"]!!.jsonPrimitive.long,+ clientId = t["clientId"]!!.jsonPrimitive.content,+ appVersion = t["appVersion"]!!.jsonPrimitive.content,+ ).also { web = it }+ }+ val c = client?.takeIf { it.expiresAtMs - now > 3_600_000 } ?: mintClientToken(w).also { client = it }+ w to c+ }++ private suspend fun mintClientToken(w: WebToken): ClientToken {+ val body = buildJsonObject {+ putJsonObject("client_data") {+ put("client_version", w.appVersion)+ put("client_id", w.clientId)+ putJsonObject("js_sdk_data") {+ put("device_brand", "unknown")+ put("device_model", "unknown")+ put("os", "linux")+ put("os_version", "unknown")+ put("device_id", deviceId)+ put("device_type", "computer")+ }+ }+ }+ val request = Request.Builder()+ .url("https://clienttoken.spotify.com/v1/clienttoken")+ // Bytes, not a String: OkHttp would append "; charset=utf-8", which this endpoint rejects with 400.+ .post(body.toString().toByteArray().toRequestBody("application/json".toMediaType()))+ .header("accept", "application/json")+ .header("user-agent", USER_AGENT)+ .build()+ val (code, text) = withContext(Dispatchers.IO) { http.newCall(request).execute().use { it.code to it.body.string() } }+ val granted = runCatching { Bridge.json.parseToJsonElement(text).jsonObject["granted_token"]?.jsonObject }.getOrNull()+ ?: throw GqlException("clienttoken", "HTTP $code: ${text.take(200)}")+ val seconds = (granted["expires_after_seconds"] as? JsonPrimitive)?.long ?: 86_400+ return ClientToken(granted["token"]!!.jsonPrimitive.content, System.currentTimeMillis() + seconds * 1000)+ }++ companion object {+ const val JSON_TYPE = "application/json;charset=UTF-8"+ const val USER_AGENT =+ "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/155.0.0.0 Safari/537.36"+ }+}++/** GraphQL straight to api-partner: fastest, parallel, independent of the page. Falls back to [fallback]. */+class HttpGql(private val http: SpotifyHttp, private val source: OpsSource, private val fallback: Gql) : Gql {+ private val ops get() = source.ops+ /** Calls answered directly, and calls that had to go through [fallback]. */+ val direct = java.util.concurrent.atomic.AtomicInteger()+ val fellBack = java.util.concurrent.atomic.AtomicInteger()++ override suspend fun query(name: String, variables: JsonObject): JsonElement {+ val body = buildJsonObject {+ put("variables", variables)+ put("operationName", name)+ putJsonObject("extensions") {+ putJsonObject("persistedQuery") {+ put("version", 1)+ put("sha256Hash", ops.hash(name))+ }+ }+ }+ val (code, text) = runCatching { http.send("POST", "https://api-partner.spotify.com/pathfinder/v2/query", body.toString()) }+ .getOrElse { fellBack.incrementAndGet(); return fallback.query(name, variables) }+ if (code != 200) { fellBack.incrementAndGet(); return fallback.query(name, variables) }+ direct.incrementAndGet()+ val response = Bridge.json.parseToJsonElement(text)+ val errors = (response as? JsonObject)?.get("errors")+ if (errors != null && (response as JsonObject)["data"].let { it == null || it is kotlinx.serialization.json.JsonNull }) {+ val message = runCatching { errors.jsonArray.first().jsonObject["message"]!!.jsonPrimitive.content }.getOrDefault("error")+ throw GqlException(name, message)+ }+ return response+ }+}diff --git a/base/api-spotify/src/main/kotlin/app/myspoti/spotify/gql/GqlOpsUpdater.kt b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/gql/GqlOpsUpdater.ktnew file mode 100644index 00000000..1d17126a--- /dev/null+++ b/base/api-spotify/src/main/kotlin/app/myspoti/spotify/gql/GqlOpsUpdater.kt@@ -0,0 +1,85 @@+package app.myspoti.spotify.gql++import app.myspoti.spotify.bridge.Bridge+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.async+import kotlinx.coroutines.awaitAll+import kotlinx.coroutines.coroutineScope+import kotlinx.coroutines.sync.Semaphore+import kotlinx.coroutines.sync.withPermit+import kotlinx.coroutines.withContext+import kotlinx.serialization.json.JsonObject+import kotlinx.serialization.json.JsonPrimitive+import kotlinx.serialization.json.buildJsonObject+import kotlinx.serialization.json.jsonObject+import kotlinx.serialization.json.jsonPrimitive+import kotlinx.serialization.json.put+import kotlinx.serialization.json.putJsonObject+import okhttp3.OkHttpClient+import okhttp3.Request+import java.io.File+import java.util.Base64++/**+ * Keeps the operation table in step with Spotify's releases, from public files only:+ * the open.spotify.com page names its build and lists its JS bundles; each bundle+ * defines operations as `new X("name","query","hash")`. Runs only when the build changed.+ */+class GqlOpsUpdater(private val http: OkHttpClient, private val cache: File) {++ /** The cached table if any, else the bundled one. */+ fun load(): GqlOps = runCatching { parse(cache.readText()) }.getOrNull() ?: GqlOps.bundled()++ /** Fetches the current build; returns a new table when it changed, else null. */+ suspend fun refresh(current: GqlOps): GqlOps? = withContext(Dispatchers.IO) {+ val html = get("https://open.spotify.com/")+ val build = script(html, "appServerConfig")?.let { (it["buildVersion"] as? JsonPrimitive)?.content }+ val cachedBuild = runCatching { Bridge.json.parseToJsonElement(cache.readText()).jsonObject["buildVersion"]?.jsonPrimitive?.content }.getOrNull()+ if (build != null && build == cachedBuild) return@withContext null+ val urls = LinkedHashSet<String>()+ BUNDLE.findAll(html).forEach { urls += it.value }+ script(html, "__CDN_FILE_URLS__")?.values?.forEach { v ->+ (v as? JsonPrimitive)?.content?.takeIf { it.endsWith(".js") && it.contains("/web-player/") }?.let(urls::add)+ }+ if (urls.isEmpty()) return@withContext null+ val found = HashMap<String, String>()+ val gate = Semaphore(6)+ coroutineScope {+ urls.map { url -> async { gate.withPermit { runCatching { get(url) }.getOrNull() } } }.awaitAll()+ }.filterNotNull().forEach { body -> OP.findAll(body).forEach { m -> found[m.groupValues[1]] = m.groupValues[3] } }+ // A partial download must not drop operations: keep the known ones it did not see.+ if (found.size < current.names.size / 2) return@withContext null+ val merged = current.names.associateWith { current.hash(it) } + found+ val json = buildJsonObject {+ build?.let { put("buildVersion", it) }+ putJsonObject("operations") { merged.forEach { (name, hash) -> putJsonObject(name) { put("hash", hash) } } }+ }+ cache.parentFile?.mkdirs()+ cache.writeText(json.toString())+ GqlOps(merged)+ }++ private fun parse(text: String): GqlOps {+ val ops = Bridge.json.parseToJsonElement(text).jsonObject["operations"]!!.jsonObject+ return GqlOps(ops.mapValues { it.value.jsonObject["hash"]!!.jsonPrimitive.content })+ }++ private fun get(url: String): String =+ http.newCall(Request.Builder().url(url).header("user-agent", SpotifyHttp.USER_AGENT).build()).execute().use {+ check(it.isSuccessful) { "HTTP ${it.code} for $url" }+ it.body.string()+ }++ /** `<script id="...">base64 JSON</script>` blocks of the page. */+ private fun script(html: String, id: String): JsonObject? {+ val m = Regex("<script id=\"$id\"[^>]*>([^<]+)</script>").find(html) ?: return null+ val raw = m.groupValues[1].trim()+ return runCatching { Bridge.json.parseToJsonElement(String(Base64.getDecoder().decode(raw))).jsonObject }+ .recoverCatching { Bridge.json.parseToJsonElement(raw).jsonObject }.getOrNull()+ }++ companion object {+ private val BUNDLE = Regex("https://open\\.spotifycdn\\.com/cdn/build/web-player/[^\"']+?\\.js")+ private val OP = Regex("new [\\w$]+(?:\\.[\\w$]+)?\\(\"(\\w+)\",\"(query|mutation|subscription)\",\"([0-9a-f]{64})\"")+ }+}diff --git a/base/api-spotify/src/main/resources/bridge/player-bridge.js b/base/api-spotify/src/main/resources/bridge/player-bridge.jsnew file mode 100644index 00000000..43f0dae5--- /dev/null+++ b/base/api-spotify/src/main/resources/bridge/player-bridge.js@@ -0,0 +1,341 @@+/*+ * Myspoti player bridge.+ *+ * Runs inside the official Web Player page and exposes its player through one+ * small, host-agnostic contract. The same file is loaded by the Android WebView+ * and by desktop Chrome over CDP, so every command can be tested on a PC.+ *+ * Host -> page: window.Myspoti.call(id, method, args) (also returns a Promise)+ * Page -> host: one JSON string per message, sent to the first host channel found:+ * - window.MyspotiHost.post(json) Android @JavascriptInterface+ * - window.__mspHostPost(json) CDP Runtime.addBinding+ * Messages: {type: "ready"} | {type: "state", state} | {type: "queue", queue}+ * | {type: "result", id, ok, value | error} | {type: "error", error}+ *+ * The bridge only reads the page's own service registry; it patches nothing.+ */+(() => {+ // Injected again (each page load event): say ready again instead of staying silent.+ if (window.Myspoti && window.Myspoti.version) {+ if (window.Myspoti.announce) window.Myspoti.announce();+ return;+ }++ const VERSION = 1;+ const READY_TIMEOUT_MS = 60000;++ const post = msg => {+ const json = JSON.stringify(msg);+ try {+ if (window.MyspotiHost && window.MyspotiHost.post) return window.MyspotiHost.post(json);+ if (typeof window.__mspHostPost === 'function') return window.__mspHostPost(json);+ } catch (e) { /* host gone: nothing to report to */ }+ };++ // --- service lookup -------------------------------------------------------++ const findPlatform = () => {+ const host = document.getElementById('main') || document.body;+ const roots = [host, ...host.querySelectorAll('*')];+ for (const el of roots) {+ const key = Object.keys(el).find(k => k.startsWith('__reactContainer$'));+ if (!key) continue;+ const stack = [el[key]];+ while (stack.length) {+ const f = stack.pop();+ const v = f.memoizedProps && f.memoizedProps.value;+ if (v && typeof v === 'object' && typeof v.getRegistry === 'function') return v;+ if (f.sibling) stack.push(f.sibling);+ if (f.child) stack.push(f.child);+ }+ }+ return null;+ };++ let services = null;+ const resolveServices = () => {+ const platform = findPlatform();+ if (!platform) return null;+ const registry = platform.getRegistry();+ const byName = {};+ for (const key of registry._map.keys()) {+ if (key && key.description) byName[key.description] = key;+ }+ const get = name => {+ if (!byName[name]) throw new Error(`service ${name} not found`);+ return registry.resolve(byName[name]);+ };+ const player = get('PlayerAPI');+ if (!player || typeof player.getState !== 'function') return null;+ return {+ platform,+ player,+ playback: get('PlaybackAPI'),+ library: get('LibraryAPI'),+ token: get('TokenProvider'),+ graphql: platform.getGraphQLLoader(),+ byName,+ resolve: name => get(name),+ };+ };++ // --- state mapping --------------------------------------------------------++ const image = images => {+ if (!images || !images.length) return null;+ return [...images].sort((a, b) => (b.width || 0) - (a.width || 0))[0].url;+ };++ // Ads come in the same queue as tracks, with `type: "ad"` and a title instead of a name.+ const kind = item => item.type === 'ad' || /^spotify:ad:/.test(item.uri) ? 'ad'+ : /^spotify:episode:/.test(item.uri) ? 'episode' : 'track';++ const track = item => item && {+ kind: kind(item),+ uri: item.uri,+ uid: item.uid || null,+ name: item.name || item.title || '',+ advertiser: item.advertiser || null,+ durationMs: item.duration ? item.duration.milliseconds : null,+ artists: (item.artists || []).map(a => ({ uri: a.uri, name: a.name })),+ album: item.album ? { uri: item.album.uri, name: item.album.name } : null,+ image: image(item.images || (item.album && item.album.images)),+ explicit: !!item.isExplicit,+ mediaType: item.mediaType || 'audio',+ provider: item.provider || null,+ };++ const lastReal = items => (items || []).filter(i => kind(i) !== 'ad');+ const mapState = s => s && {+ track: track(s.item),+ contextUri: s.context ? s.context.uri : null,+ contextName: s.context && s.context.metadata ? s.context.metadata.context_description || null : null,+ previous: track(lastReal(s.previousItems).slice(-1)[0]),+ next: track(lastReal(s.nextItems)[0]),+ isPaused: !!s.isPaused,+ isBuffering: !!s.isBuffering,+ positionMs: s.positionAsOfTimestamp,+ timestamp: s.timestamp,+ durationMs: s.duration,+ shuffle: !!s.shuffle,+ repeat: s.repeat, // 0 off, 1 context, 2 track+ speed: s.speed,+ restrictions: s.restrictions || {},+ playbackId: s.playbackId || null,+ };++ const mapQueue = q => q && {+ current: track(q.current),+ queued: (q.queued || []).map(track),+ nextUp: (q.nextUp || []).map(track),+ };++ // --- serialization --------------------------------------------------------++ const methodsOf = obj => {+ const names = new Set();+ for (let p = obj; p && p !== Object.prototype; p = Object.getPrototypeOf(p)) {+ for (const n of Object.getOwnPropertyNames(p)) {+ if (n === 'constructor' || n.startsWith('_')) continue;+ try { if (typeof p[n] === 'function') names.add(n); } catch (e) { /* getter threw */ }+ }+ }+ return [...names].sort();+ };++ // Plain JSON copy of whatever a service returns: drops functions, breaks cycles,+ // turns Maps/Sets into objects/arrays and BigInts into strings.+ const toJson = (value, depth = 0, seen = new WeakSet()) => {+ if (value === null || value === undefined) return null;+ const t = typeof value;+ if (t === 'bigint') return value.toString();+ if (t === 'function' || t === 'symbol') return undefined;+ if (t !== 'object') return value;+ if (depth > 12 || seen.has(value)) return null;+ seen.add(value);+ if (value instanceof Date) return value.toISOString();+ if (value instanceof Map) value = Object.fromEntries(value);+ if (value instanceof Set) value = [...value];+ if (ArrayBuffer.isView(value)) return Array.from(value);+ if (Array.isArray(value)) return value.map(v => { const j = toJson(v, depth + 1, seen); return j === undefined ? null : j; });+ const out = {};+ for (const k of Object.keys(value)) {+ if (k.startsWith('_')) continue;+ const j = toJson(value[k], depth + 1, seen);+ if (j !== undefined) out[k] = j;+ }+ return out;+ };++ // --- commands -------------------------------------------------------------++ const need = () => {+ if (!services) throw new Error('not ready');+ return services;+ };++ const commands = {+ 'bridge.version': () => VERSION,++ 'player.state': () => mapState(need().player.getState()),+ 'player.queue': () => mapQueue(need().player.getQueue()),+ // {contextUri, trackUri?, trackUid?, index?, positionMs?}+ 'player.play': a => {+ const skipTo = {};+ if (a.trackUri) skipTo.uri = a.trackUri;+ if (a.trackUid) skipTo.uid = a.trackUid;+ if (Number.isInteger(a.index)) skipTo.index = a.index;+ const extra = {};+ if (Object.keys(skipTo).length) extra.skipTo = skipTo;+ if (a.positionMs) extra.seekTo = a.positionMs;+ return need().player.play({ uri: a.contextUri }, {}, extra);+ },+ 'player.pause': () => need().player.pause(),+ 'player.resume': () => need().player.resume(),+ 'player.seek': a => need().player.seekTo(a.positionMs),+ 'player.next': () => need().player.skipToNext(),+ 'player.previous': () => need().player.skipToPrevious(),+ 'player.setShuffle': a => need().player.setShuffle(!!a.on),+ 'player.setRepeat': a => need().player.setRepeat(a.mode),+ 'player.setSpeed': a => need().player.setSpeed(a.speed),+ 'queue.add': a => need().player.addToQueue(a.uris.map(uri => ({ uri }))),+ 'queue.remove': a => need().player.removeFromQueue(a.items),+ 'queue.clear': () => need().player.clearQueue(),+ // Jumps to a queued or upcoming item.+ 'queue.skipTo': a => need().player.skipToNext({ uri: a.uri, uid: a.uid }),+ // {uris, before: {uri, uid}} : "play next" puts the tracks before the first queued item.+ 'queue.insert': a => need().player.insertIntoQueue(a.uris.map(uri => ({ uri })), { before: a.before }),+ // {items: [{uri, uid}], before | after: {uri, uid}}+ 'queue.reorder': a => need().player.reorderQueue(a.items, a.after ? { after: a.after } : { before: a.before }),++ 'volume.get': () => need().playback.getVolume(),+ 'volume.set': a => need().playback.setVolume(a.level),++ 'library.contains': a => need().library.contains(...a.uris),+ 'library.add': a => need().library.add({ uris: a.uris }),+ 'library.remove': a => need().library.remove({ uris: a.uris }),++ // Generic access to the page's services (PlaylistAPI, RootlistAPI, ShowAPI, ConnectAPI...).+ // Typed wrappers live on the host side; this keeps the bridge small.+ 'service.list': () => {+ const out = {};+ for (const name of Object.keys(need().byName)) {+ let v;+ try { v = need().resolve(name); } catch (e) { continue; }+ if (v && typeof v === 'object') out[name] = methodsOf(v);+ }+ return out;+ },+ // {service, method, args[]}+ 'service.call': async a => {+ const svc = need().resolve(a.service);+ if (!svc || typeof svc[a.method] !== 'function' || a.method.startsWith('_')) {+ throw new Error(`no method ${a.service}.${a.method}`);+ }+ return toJson(await svc[a.method](...(a.args || [])));+ },++ // Any persisted GraphQL operation of the Web Player, sent by the page's own loader+ // (its auth, client token and retries). {name, hash, variables}+ 'gql.query': async a => {+ const def = { name: a.name, operation: a.operation || 'query', sha256Hash: a.hash, value: null };+ return need().graphql(def, a.variables || {});+ },++ // Web token for the HTTP API, refreshed by the page itself.+ 'token.get': async () => {+ const t = await need().token.getToken();+ // clientId and appVersion let the host mint its own client token for direct HTTP calls.+ return t && {+ accessToken: t.accessToken,+ expiresAtMs: t.accessTokenExpirationTimestampMs,+ clientId: t.clientId,+ appVersion: need().platform.version,+ isAnonymous: !!t.isAnonymous,+ };+ },+ };++ const call = async (id, method, args) => {+ try {+ const fn = commands[method];+ if (!fn) throw new Error(`unknown method ${method}`);+ const value = await fn(args || {});+ const out = value === undefined ? null : value;+ post({ type: 'result', id, ok: true, value: out });+ return out;+ } catch (e) {+ post({ type: 'result', id, ok: false, error: String(e && e.message || e) });+ throw e;+ }+ };++ // --- events ---------------------------------------------------------------++ let lastState = '';+ const pushState = () => {+ if (!services) return;+ const state = mapState(services.player.getState());+ const json = JSON.stringify(state);+ if (json === lastState) return;+ lastState = json;+ post({ type: 'state', state });+ };++ const pushQueue = () => {+ if (services) post({ type: 'queue', queue: mapQueue(services.player.getQueue()) });+ };++ const attach = () => {+ const events = services.player.getEvents();+ events.addListener('update', pushState);+ events.addListener('queue_update', pushQueue);+ };++ // --- boot -----------------------------------------------------------------++ // --- diagnostics (read-only) ----------------------------------------------+ // Playback requests with their status and body size, and uncaught page errors,+ // so the host log shows why a play command did nothing.+ const PLAYBACK = /player\/command|track-playback|connect-state\/v1\/devices|widevine-license|storage-resolve|audio-.*\.scdn\.co|apresolve/;+ try {+ new PerformanceObserver(list => {+ for (const e of list.getEntries()) {+ if (!PLAYBACK.test(e.name)) continue;+ post({ type: 'net', url: e.name.split('?')[0].slice(0, 160), status: e.responseStatus || 0, bytes: e.encodedBodySize || e.transferSize || 0, ms: Math.round(e.duration) });+ }+ }).observe({ type: 'resource', buffered: true });+ } catch (e) { /* no resource timing */ }+ window.addEventListener('error', e => post({ type: 'jserror', error: String(e.message || e.error || '').slice(0, 300) }));+ window.addEventListener('unhandledrejection', e => post({ type: 'jserror', error: String((e.reason && (e.reason.stack || e.reason.message)) || e.reason || '').slice(0, 300) }));++ const announce = () => {+ if (!services) return;+ post({ type: 'ready', version: VERSION });+ lastState = '';+ pushState();+ };++ window.Myspoti = { version: VERSION, call, announce, methods: Object.keys(commands) };++ const started = Date.now();+ const boot = () => {+ try {+ services = resolveServices();+ } catch (e) {+ services = null;+ }+ if (services) {+ attach();+ post({ type: 'ready', version: VERSION });+ pushState();+ return;+ }+ if (Date.now() - started > READY_TIMEOUT_MS) {+ post({ type: 'error', error: 'player services not found' });+ return;+ }+ setTimeout(boot, 250);+ };+ boot();+})();diff --git a/base/api-spotify/src/main/resources/spotify/gql-ops.json b/base/api-spotify/src/main/resources/spotify/gql-ops.jsonnew file mode 100644index 00000000..63f1ab77--- /dev/null+++ b/base/api-spotify/src/main/resources/spotify/gql-ops.json@@ -0,0 +1,723 @@+{+ "buildVersion": "web-player_2026-10-15_1792099594925_61b9bcdb1ef2",+ "clientVersion": "1.3.6.1874.g61b9bcdb1ef2",+ "bundles": 182,+ "operations": {+ "ArtistConcerts": {+ "kind": "query",+ "hash": "ef53c43b865496b9890b7167eab1dc614a8949ef9451b3c41184ea888de8bd2b"+ },+ "ArtistConcertsPageLocation": {+ "kind": "query",+ "hash": "320698465a352f0d0247ec8ed02471244106d4199820f99de4d0a785561c2b03"+ },+ "ConcertCampaign": {+ "kind": "query",+ "hash": "c7d2e205f8e9a86ff591b04dec97785769b403f8b936a0826c936d2ea0c4add9"+ },+ "ConcertGallery": {+ "kind": "query",+ "hash": "2712501d317e8fb585b74dfdbaeaf4f36f9d7d49fc8620b29e307b2fe0f053f7"+ },+ "SetItemsStateInWhatsNewFeed": {+ "kind": "mutation",+ "hash": "d889c8c936ab192af8ced595427f5ba2acdf63478fdc0a181c8d477f8322630e"+ },+ "accountAttributes": {+ "kind": "query",+ "hash": "d48062d0df0a256ff78ed9e232b83d238dcd710b371efd304b0e178b62595582"+ },+ "addComment": {+ "kind": "mutation",+ "hash": "504a54dcb144fc345869c93887152f53450bd41298b6edb57d9e3b1c5aae92e6"+ },+ "addCommentReaction": {+ "kind": "mutation",+ "hash": "0af9821ff5cc680412c61c470d55493fe26e6cf938101a93b18c7cc8e5590acb"+ },+ "addCommentReply": {+ "kind": "mutation",+ "hash": "d4046f61457dad19e9315f8829a92e6d162592729d08ed0f9fe70f4c04cd09ae"+ },+ "addToLibrary": {+ "kind": "mutation",+ "hash": "896ebcb47815681340860d121cb5d494e157e2a78d3950385cd54e0393c67148"+ },+ "addToPlaylist": {+ "kind": "mutation",+ "hash": "b907ad6b088d5bf7680fa81198996d58398c2d55dfcdf59fcc959e0be98a418a"+ },+ "addVenueToLibrary": {+ "kind": "mutation",+ "hash": "353cc0ecbf123f4166f6887a1478520dab08fc1de527aaca8d72c9851693620c"+ },+ "albumPreRelease": {+ "kind": "query",+ "hash": "e1a5537a42c3b8a687f10ae865c3b6776d6d797f8c0c272b2d40dc159a8e1a94"+ },+ "albumPreReleaseTracks": {+ "kind": "query",+ "hash": "dfbdcf2688995adc2c2196fcdd7802b2a5137a2549b361aa7fb23cd6493f4672"+ },+ "applyCurations": {+ "kind": "mutation",+ "hash": "05b739a3a73091c213385233b9d3ed8a857c2ca29d2eebadb3d04ed12e288697"+ },+ "applyCurationsV2": {+ "kind": "mutation",+ "hash": "8d106cadf80dbe8dfaf62746b254b8e90aff782ba50c14a3c451b528b527a382"+ },+ "areEntitiesInLibrary": {+ "kind": "query",+ "hash": "134337999233cc6fdd6b1e6dbf94841409f04a946c5c7b744b09ba0dfe5a85ed"+ },+ "assistedCurationSearch": {+ "kind": "query",+ "hash": "f78953bf9207d73493c27284103f5aeb6e728876d5793851bf79bc706127ff70"+ },+ "assistedCurationSearchAlbum": {+ "kind": "query",+ "hash": "e33489c81fdab1986d8b785fb9bf13993a2d5ff171190c575963f97e525870fe"+ },+ "assistedCurationSearchArtist": {+ "kind": "query",+ "hash": "a562324cea8976b4d51f08cee971bb180ce9279c947d27e0814675220b160cf7"+ },+ "browseAll": {+ "kind": "query",+ "hash": "dbd8b55e09a58afc52eab438bc228ba28fd72ac2f2148c6c26354980e4579001"+ },+ "browsePage": {+ "kind": "query",+ "hash": "f5c4e6d668f5716464a231c1cc8b22c1cbf6ad68b09929fd7de813a30581298b"+ },+ "browseSection": {+ "kind": "query",+ "hash": "b13c1cccbfcb6947753c2613411b3566485c21fd5f36d80a80bb64be61ba2d51"+ },+ "canvas": {+ "kind": "query",+ "hash": "575138ab27cd5c1b3e54da54d0a7cc8d85485402de26340c2145f0f6bb5e7a9f"+ },+ "centralisedStatePlayerOptions": {+ "kind": "query",+ "hash": "e2dcfcab470854d4d1c7cb1a851438f14fe0a94d57db7f0b9dde492559d5395d"+ },+ "changeAttributes": {+ "kind": "mutation",+ "hash": "c51f514c143b5a4ff830bb2e85c3bef7441814ae4e3392a671f476c903c487ac"+ },+ "concert": {+ "kind": "query",+ "hash": "9b582a69061f6648858515c2aa6d4a2273ac49b74eb5dbc612bc1299a9f2f13e"+ },+ "concertConcepts": {+ "kind": "query",+ "hash": "a409c1eb39b6345e7993d424d2408b65a6699bafc2b8a03217033e517cd76b72"+ },+ "concertCount": {+ "kind": "query",+ "hash": "29be9d486e073a49268e13ed9e2d2180187e669fcb7a19b98011aca7ab61b141"+ },+ "concertFeed": {+ "kind": "query",+ "hash": "9cae2dbee3f47904c60bab45256260b3ddb9844d5ef25038c17112619d14ce9a"+ },+ "concertLocationDetails": {+ "kind": "query",+ "hash": "b13f195349f188fee25480ae889d782852d68663bf07743c654244454750d681"+ },+ "concertLocationsByLatLon": {+ "kind": "query",+ "hash": "8a059d072a17a1199feb21fe846271f1680eda87010c832852ced0c55c6c7c96"+ },+ "concertNotInterestedSet": {+ "kind": "mutation",+ "hash": "81c188764fbf5c76d6b10a47c7b3623b46d9d13d69663a3774cfeae89d52e16e"+ },+ "concertNotInterestedUndo": {+ "kind": "mutation",+ "hash": "6e7189ddd2537fa7f9700324986c1f062790746df9183066077952e5ca13494c"+ },+ "concertRoutingCardVisuals": {+ "kind": "query",+ "hash": "a69f1a97f02c81533bd4e4ac2fed4669cb35a44a294e36a02c14df892d63ff0f"+ },+ "countryHubContent": {+ "kind": "query",+ "hash": "0e82bf24f321731e43423d9cdce71aa154ee876cd12b055e7c3af4dcb44c9225"+ },+ "countryHubsPage": {+ "kind": "query",+ "hash": "6c2e4b04d8836507c2ad09c954f27a6c98d8b0a761f99ef6f4dc9bbe7834ba55"+ },+ "curateItems": {+ "kind": "mutation",+ "hash": "7ec153d699355ef54da22366723b66b11aae0c288b166dc6813b70ac91901af1"+ },+ "decorateContextEpisodesOrChapters": {+ "kind": "query",+ "hash": "383de00240775c39a6afe0b1055dc562b2a3930894201f9762f3fc32a74971c7"+ },+ "decorateContextTracks": {+ "kind": "query",+ "hash": "383de00240775c39a6afe0b1055dc562b2a3930894201f9762f3fc32a74971c7"+ },+ "decorateQueuedByUsers": {+ "kind": "query",+ "hash": "33fe7085b4a9dde404955eeee4f8f93aa7a8e55028058354bc707727d8a7890d"+ },+ "deleteComment": {+ "kind": "mutation",+ "hash": "9ecb2804fc1c8f85f8112ffc962b038a31a1c63d59bcf8b5fb23cb2765b8b6d9"+ },+ "deleteCommentReaction": {+ "kind": "mutation",+ "hash": "b93a40eaa470fcaaa886352e3268e3e5c6e303e11e8b849490e98ba158796cca"+ },+ "deleteCommentReply": {+ "kind": "mutation",+ "hash": "5cef2a525100a08976bf6079771d5b88b1ec8b0fe5eee402185a7449e53d494c"+ },+ "deleteLocation": {+ "kind": "mutation",+ "hash": "2f681a7c30da3bc905c469374aa2983d0d00a1b6ba88e5fdd6a23caa02057971"+ },+ "editablePlaylists": {+ "kind": "query",+ "hash": "d5c4b8096437dcc2ac9528c91dfcd299e35b747cda2f8f75d28f41f49c5092ba"+ },+ "episodeSponsoredContent": {+ "kind": "query",+ "hash": "a5c1fe722b60c29ad247ea3df57ace52043382a7f080d525f58745db78a42618"+ },+ "fetchEntitiesForRecentlyPlayed": {+ "kind": "query",+ "hash": "cf5d2e94ffd82788470788ae1f6090cc3e9e774fb8fd383580634c6e6f50f7be"+ },+ "fetchExtractedColorAndImageForAlbumEntity": {+ "kind": "query",+ "hash": "b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f"+ },+ "fetchExtractedColorAndImageForArtistEntity": {+ "kind": "query",+ "hash": "b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f"+ },+ "fetchExtractedColorAndImageForEpisodeEntity": {+ "kind": "query",+ "hash": "b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f"+ },+ "fetchExtractedColorAndImageForPlaylistEntity": {+ "kind": "query",+ "hash": "b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f"+ },+ "fetchExtractedColorAndImageForPodcastEntity": {+ "kind": "query",+ "hash": "b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f"+ },+ "fetchExtractedColorAndImageForTrackEntity": {+ "kind": "query",+ "hash": "b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f"+ },+ "fetchExtractedColorForAlbumEntity": {+ "kind": "query",+ "hash": "b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f"+ },+ "fetchExtractedColorForArtistEntity": {+ "kind": "query",+ "hash": "b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f"+ },+ "fetchExtractedColorForEpisodeEntity": {+ "kind": "query",+ "hash": "b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f"+ },+ "fetchExtractedColorForPlaylistEntity": {+ "kind": "query",+ "hash": "b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f"+ },+ "fetchExtractedColorForPodcastEntity": {+ "kind": "query",+ "hash": "b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f"+ },+ "fetchExtractedColorForTrackEntity": {+ "kind": "query",+ "hash": "b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f"+ },+ "fetchExtractedColors": {+ "kind": "query",+ "hash": "36e90fcaea00d47c695fce31874efeb2519b97d4cd0ee1abfb4f8dc9348596ea"+ },+ "fetchLibraryTracks": {+ "kind": "query",+ "hash": "087278b20b743578a6262c2b0b4bcd20d879c503cc359a2285baf083ef944240"+ },+ "fetchPlaylist": {+ "kind": "query",+ "hash": "21ea11a6ac75a5f3e01fd365d29c18e0a4a8b7dc09f89bbb5d73910190c6acaf"+ },+ "fetchPlaylistContents": {+ "kind": "query",+ "hash": "21ea11a6ac75a5f3e01fd365d29c18e0a4a8b7dc09f89bbb5d73910190c6acaf"+ },+ "fetchPlaylistMetadata": {+ "kind": "query",+ "hash": "21ea11a6ac75a5f3e01fd365d29c18e0a4a8b7dc09f89bbb5d73910190c6acaf"+ },+ "followUsers": {+ "kind": "mutation",+ "hash": "c00e0cb6c7766e7230fc256cf4fe07aec63b53d1160a323940fce7b664e95596"+ },+ "getAlbum": {+ "kind": "query",+ "hash": "11c9cad9cb24c4f9e25ef9456f68621cfd6006a90f679e729c1d2f2fd70dfe16"+ },+ "getAlbumNameAndTracks": {+ "kind": "query",+ "hash": "8628ad33de3267d7bef516c76a746979a5f98891a2c9eaff3dfec828abdcd983"+ },+ "getArtistNameAndTracks": {+ "kind": "query",+ "hash": "0adaf1a1a8a94c7ed095639c4d9456d2b1cfac16ac511d5dd2b01b6dd89f748a"+ },+ "getAudiobooksMetadata": {+ "kind": "query",+ "hash": "523c71c64749a628f83e6b31a122c76663243730bf02df01fd64abf0f62f572f"+ },+ "getCommentsForEntity": {+ "kind": "query",+ "hash": "5075cb710c32d369eb5b67f6abdfd11a48d58214795064181a7da830b5fc84b6"+ },+ "getDynamicColors": {+ "kind": "query",+ "hash": "f0f112945d6d745bd8ff790317bbf8d310036da75df33130490e9d6dc96c59d9"+ },+ "getDynamicColorsByUris": {+ "kind": "query",+ "hash": "f0f112945d6d745bd8ff790317bbf8d310036da75df33130490e9d6dc96c59d9"+ },+ "getEpisodeName": {+ "kind": "query",+ "hash": "508f9db2e7dc340c338950dc67a6045ee1406703646f23b760986fa689c239b1"+ },+ "getEpisodeOrChapter": {+ "kind": "query",+ "hash": "5f77db47e5a2ce6680330bb61317aa09e17ddd1d189513cb218e7cd3e43288be"+ },+ "getLists": {+ "kind": "query",+ "hash": "130589ef0ac5ffc096b08ab11c031292812f91620665af1a339112ca3016c5c1"+ },+ "getListsContents": {+ "kind": "query",+ "hash": "130589ef0ac5ffc096b08ab11c031292812f91620665af1a339112ca3016c5c1"+ },+ "getListsMetadata": {+ "kind": "query",+ "hash": "130589ef0ac5ffc096b08ab11c031292812f91620665af1a339112ca3016c5c1"+ },+ "getPodcastOrBookName": {+ "kind": "query",+ "hash": "631676b4cf1eb7c93d1133e3f1f17e5bfe8d6a5e2fb9560148bac61f1531f267"+ },+ "getReactions": {+ "kind": "query",+ "hash": "0d209bf9507779887fe2b3032d1afd8f35de8425b01aead094698ff1abecda71"+ },+ "getReplies": {+ "kind": "query",+ "hash": "4c45f55fdfd691e08ad983d5c914baf5581824a81b2da1cdb8a9dad747c012bf"+ },+ "getTrack": {+ "kind": "query",+ "hash": "a8ef9e9f02b836feb0da3003c31dbb30decc6f4b473ef89ca88c882386d668de"+ },+ "getTrackName": {+ "kind": "query",+ "hash": "3dee761788854e8dd9239e13ce0d712da031fb8c2036f096a1c765062b410660"+ },+ "getVideoTrackAssociatedAlbum": {+ "kind": "query",+ "hash": "e9ecdc49f7777062fc841415262d47c3927e09ab6e6845b420a373caec602812"+ },+ "home": {+ "kind": "query",+ "hash": "5fb7da7a03ee2776c0670856609cb85a189a3cecc36cc160b91cde79063b9cf1"+ },+ "homePinnedSections": {+ "kind": "query",+ "hash": "5fb7da7a03ee2776c0670856609cb85a189a3cecc36cc160b91cde79063b9cf1"+ },+ "homeSection": {+ "kind": "query",+ "hash": "5fb7da7a03ee2776c0670856609cb85a189a3cecc36cc160b91cde79063b9cf1"+ },+ "inferredUserLocation": {+ "kind": "query",+ "hash": "5db4c507ea735d2a1f37bd1166eca2c1a0e3387bb875ebca5d6031b6eccceeba"+ },+ "internalLinkRecommenderEpisode": {+ "kind": "query",+ "hash": "122f5c777aae5c0918baec11cd646b7034b8f213f260097b4d229ad947ec7f93"+ },+ "internalLinkRecommenderShow": {+ "kind": "query",+ "hash": "6c369ff272a666b31fef1629c169925a1bd80f372195396c82304142cacd89e8"+ },+ "internalLinkRecommenderTrack": {+ "kind": "query",+ "hash": "c77098ee9d6ee8ad3eb844938722db60570d040b49f41f5ec6e7be9160a7c86b"+ },+ "isCurated": {+ "kind": "query",+ "hash": "e4ed1f91a2cc5415befedb85acf8671dc1a4bf3ca1a5b945a6386101a22e28a6"+ },+ "isCuratedEntities": {+ "kind": "query",+ "hash": "af6bb0d2691f78f9169e1ba2dfed34a414bb4994e858f81487d6a26b95280566"+ },+ "isFollowingUsers": {+ "kind": "query",+ "hash": "c00e0cb6c7766e7230fc256cf4fe07aec63b53d1160a323940fce7b664e95596"+ },+ "libraryV3": {+ "kind": "query",+ "hash": "390c78e5b951029bad359785e69b07b536a509c581cbcd0aded5e5067f187455"+ },+ "lookupChildEntities": {+ "kind": "query",+ "hash": "91ce02e32b19123de231dc8de91fe4b9ab84eca087d4c015549308d77fbb6d10"+ },+ "lookupDebug": {+ "kind": "query",+ "hash": "6953237e41493792c4e838ebe9532a4cad6a6c11d77229fb524a5e966b855fef"+ },+ "lookupEntityImages": {+ "kind": "query",+ "hash": "35e3dfa923e93cd4840a8f7847058d08d0f5a7862c158644a32a59ca28b6122c"+ },+ "moveItemsInPlaylist": {+ "kind": "mutation",+ "hash": "b907ad6b088d5bf7680fa81198996d58398c2d55dfcdf59fcc959e0be98a418a"+ },+ "npvPageContent": {+ "kind": "query",+ "hash": "6e58365b05723c3f917b0df611cbd11dae31d36cc3e71a8dd73d72300b663b46"+ },+ "npvV2TrackSupplementalSections": {+ "kind": "query",+ "hash": "3268e307f08330b620de5c161a03b48acf66ec57164eac446e0653694a485764"+ },+ "pinLibraryItem": {+ "kind": "mutation",+ "hash": "896ebcb47815681340860d121cb5d494e157e2a78d3950385cd54e0393c67148"+ },+ "playlistPermissions": {+ "kind": "query",+ "hash": "e43d1d35f231cf289c23c9d9c489f4a4f502e4eda09839c530608f107b6556b8"+ },+ "playlistSection": {+ "kind": "query",+ "hash": "2615df403a9043c1d7d3094fbeb4c9653b07b11a33d8081fbd31f0f7959ff4a1"+ },+ "profileAttributes": {+ "kind": "query",+ "hash": "08ffb4730af3746e04a8301396f20875dbbce10c75243803091a9274eacc8ac0"+ },+ "queryAlbumMerch": {+ "kind": "query",+ "hash": "3ef44ed6f17be67299538fe77faffab4075aeaf9e1085f10fc835592266711b5"+ },+ "queryAlbumTrackUris": {+ "kind": "query",+ "hash": "a2a17981f8439ca1798f56260277d9d7800ec0ca7040053b564e0f975d8aa344"+ },+ "queryAlbumTracks": {+ "kind": "query",+ "hash": "11c9cad9cb24c4f9e25ef9456f68621cfd6006a90f679e729c1d2f2fd70dfe16"+ },+ "queryArtistAboutModal": {+ "kind": "query",+ "hash": "702e29a866e0b4b4fabdf974454512a2c32d93643b1969b7a3a0dd92084f05f6"+ },+ "queryArtistAppearsOn": {+ "kind": "query",+ "hash": "9a4bb7a20d6720fe52d7b47bc001cfa91940ddf5e7113761460b4a288d18a4c1"+ },+ "queryArtistDiscographyAlbums": {+ "kind": "query",+ "hash": "5e07d323febb57b4a56a42abbf781490e58764aa45feb6e3dc0591564fc56599"+ },+ "queryArtistDiscographyAll": {+ "kind": "query",+ "hash": "5e07d323febb57b4a56a42abbf781490e58764aa45feb6e3dc0591564fc56599"+ },+ "queryArtistDiscographyCompilations": {+ "kind": "query",+ "hash": "5e07d323febb57b4a56a42abbf781490e58764aa45feb6e3dc0591564fc56599"+ },+ "queryArtistDiscographyOverview": {+ "kind": "query",+ "hash": "5e07d323febb57b4a56a42abbf781490e58764aa45feb6e3dc0591564fc56599"+ },+ "queryArtistDiscographySingles": {+ "kind": "query",+ "hash": "5e07d323febb57b4a56a42abbf781490e58764aa45feb6e3dc0591564fc56599"+ },+ "queryArtistDiscoveredOn": {+ "kind": "query",+ "hash": "71c2392e4cecf6b48b9ad1311ae08838cbdabcfd189c6bf0c66c2430b8dcfdb1"+ },+ "queryArtistFeaturing": {+ "kind": "query",+ "hash": "20842d6d9d2d28ef945984b68cb927bb33edd00eab84a8da1667def21f1f2c54"+ },+ "queryArtistMinimal": {+ "kind": "query",+ "hash": "53d3f76582c49ad0a05dc685955f20dc2a5f2209b192e5446e5e4e623ce23a48"+ },+ "queryArtistOverview": {+ "kind": "query",+ "hash": "9f8134ef565e78621f1e1793555bd6633c5ac144ae0f89604ed3ae3f80b3c8e6"+ },+ "queryArtistPlaylists": {+ "kind": "query",+ "hash": "54f7e5a5a2af05b7dc98526df376a46c6b15c05440c8dfdc8f6cecb1a807eca7"+ },+ "queryArtistRelated": {+ "kind": "query",+ "hash": "3d031d6cb22a2aa7c8d203d49b49df731f58b1e2799cc38d9876d58771aa66f3"+ },+ "queryArtistRelatedVideos": {+ "kind": "query",+ "hash": "e4bbb4f420ad5786caa7028e2943542f13c8138f5c40736292b8499ac9672ce6"+ },+ "queryBookChapters": {+ "kind": "query",+ "hash": "8f342d1c624755901657fa65cbb80dd3bacbcca2f6d802f570ae3269d59a403e"+ },+ "queryInlineCurationSearchAlbum": {+ "kind": "query",+ "hash": "122fd4817f7e9cd7b944c3103d9c81a950668423ba9d2008413b5291f9d7e547"+ },+ "queryInlineCurationSearchArtist": {+ "kind": "query",+ "hash": "be42f25d92bdadac4082e6581d35b771c3b5e8bbdd1b76c279d0924a5975f12e"+ },+ "queryInlineCurationSearchV2": {+ "kind": "query",+ "hash": "331ddd828a4db217046345833863f59f907d269947dd6f924009f6ab35743b70"+ },+ "queryInlineCurationSearchV2Booklists": {+ "kind": "query",+ "hash": "331ddd828a4db217046345833863f59f907d269947dd6f924009f6ab35743b70"+ },+ "queryMoreByArtist": {+ "kind": "query",+ "hash": "24c137a56995c042eef9d23b14539a6d9b9b154aff12ce77230f652c9e4d6b64"+ },+ "queryNpvArtist": {+ "kind": "query",+ "hash": "e1ae46a21911a3075c1aa29bf09a6c60f9a45b6a2b1132429f10ad06c299b5d7"+ },+ "queryNpvEpisode": {+ "kind": "query",+ "hash": "5704293e4a52b987c87bc11afe210aaca52813405c85ff8d0632e7587ebc6e18"+ },+ "queryPodcastEpisodes": {+ "kind": "query",+ "hash": "3539d746cf882f3909660de40b4ef472b3f5893a0761d617c282541de5d412c5"+ },+ "queryShowMetadataV2": {+ "kind": "query",+ "hash": "b475447846f37cc426add800b995a7859c169c53c72b62de6338c0c40a5dacea"+ },+ "queryTrackArtists": {+ "kind": "query",+ "hash": "ee2b038198f5e62c679c3996584d9249bbee55fe69fc212271c56492a022c798"+ },+ "queryTrackCreditsGroupedModal": {+ "kind": "query",+ "hash": "f135fb9be58a72d041ab5d214d817021a272405d883860468e2627afb01a3ca9"+ },+ "queryWhatsNewFeed": {+ "kind": "query",+ "hash": "d889c8c936ab192af8ced595427f5ba2acdf63478fdc0a181c8d477f8322630e"+ },+ "recentSearches": {+ "kind": "query",+ "hash": "ece96d7b82c820fb9938dd1df50dee3e53737d808c3883e3d01c467c423601b0"+ },+ "recents": {+ "kind": "query",+ "hash": "698be5892a3cc95331deebeff463d05dfdd5febf5254bea30b895b5a93dfb584"+ },+ "removeFromLibrary": {+ "kind": "mutation",+ "hash": "896ebcb47815681340860d121cb5d494e157e2a78d3950385cd54e0393c67148"+ },+ "removeFromPlaylist": {+ "kind": "mutation",+ "hash": "b907ad6b088d5bf7680fa81198996d58398c2d55dfcdf59fcc959e0be98a418a"+ },+ "removeRecentSearches": {+ "kind": "mutation",+ "hash": "ece96d7b82c820fb9938dd1df50dee3e53737d808c3883e3d01c467c423601b0"+ },+ "removeVenueFromLibrary": {+ "kind": "mutation",+ "hash": "353cc0ecbf123f4166f6887a1478520dab08fc1de527aaca8d72c9851693620c"+ },+ "requestPromoCode": {+ "kind": "mutation",+ "hash": "e90e712768b6041ed97f49184289f5fe0d8841134dd715f1f79c704994cd0ac7"+ },+ "saveLocation": {+ "kind": "mutation",+ "hash": "5502351e9f201ae29014ca55d3b24b755ba261a1a9eb35fb498cb4c7df419353"+ },+ "saveRecentSearches": {+ "kind": "mutation",+ "hash": "ece96d7b82c820fb9938dd1df50dee3e53737d808c3883e3d01c467c423601b0"+ },+ "searchAlbums": {+ "kind": "query",+ "hash": "202cb3305e31e5a0767ba7925f28bd728cf8f8b0217e6da43909056071cd70e9"+ },+ "searchArtists": {+ "kind": "query",+ "hash": "7bf95d754fdbe32c8b161fbbe54d1ae50974900df4dce4c8f1afcbcad153224d"+ },+ "searchAudiobooks": {+ "kind": "query",+ "hash": "e05ac765d02c084f8783d3c1572b23d57761c43f47eb8b87ce2f9ccced3fa068"+ },+ "searchAuthors": {+ "kind": "query",+ "hash": "4a9d403a7cbc7e19da5520d619a865472b35382b043bfa458154e73a5c6f46bd"+ },+ "searchConcertLocations": {+ "kind": "query",+ "hash": "43ededefcba8b3f519fd0c2d6c025dfeec9f742cf47d04a3c3711d95b27deda3"+ },+ "searchDesktop": {+ "kind": "query",+ "hash": "eef7cc54888d91bdd6802623477873caa3948ae173a0c34fd86827b267e94c03"+ },+ "searchEpisodes": {+ "kind": "query",+ "hash": "dbc56e15e7c1254f11d499e8647343bbf28a5594e14a8f5c8b1e7eee67a55740"+ },+ "searchFullEpisodes": {+ "kind": "query",+ "hash": "397a4e93a21d140d088cfd26641133c5146a2f5f08e420654868153e720f5571"+ },+ "searchGenres": {+ "kind": "query",+ "hash": "9e1c0e056c46239dd1956ea915b988913c87c04ce3dadccdb537774490266f46"+ },+ "searchModalEntityPage": {+ "kind": "query",+ "hash": "25d73ce01f3011ff8b37f44c23ebbad18610db1a2cec2c84f20c1e822c748524"+ },+ "searchModalResults": {+ "kind": "query",+ "hash": "9a79751378a306d87d9789fa0c4a8f7c7213891c47a3993a0d0b58ff26514e59"+ },+ "searchPlaylists": {+ "kind": "query",+ "hash": "d520014e748f9ea44f7707d8df1819867ac1205e8b7f3e28f22fe5fc858921b1"+ },+ "searchPodcasts": {+ "kind": "query",+ "hash": "0195d9f61b43606d490bca64c3456e3593528cea6cc05c7e822c7c42beed0f4e"+ },+ "searchSuggestions": {+ "kind": "query",+ "hash": "f244254b94c0e824d458ac216e0f8406a73f2f69a9ff52831a2f78fa774ff6ce"+ },+ "searchTopResultsList": {+ "kind": "query",+ "hash": "dd78eaff943eba629ed70ee25517b9cea0dcaa41193e2592ae2727660b21892c"+ },+ "searchTopResultsOnly": {+ "kind": "query",+ "hash": "cb32d0ff697131db6d34f174f7d2fa931c6a8b6be22aabc8c6cc086da4a0f744"+ },+ "searchTracks": {+ "kind": "query",+ "hash": "b02683192a98dde7966b5e6655a79eeb62713eab703eda9902c932818dd52751"+ },+ "searchUsers": {+ "kind": "query",+ "hash": "8f358dd82e62f61dd4ceaa9f8cd0889e644c9b707f1b724fbfb356a757cb7e5a"+ },+ "seoRecommendedTrackPlaylistDesktop": {+ "kind": "query",+ "hash": "2121830f81030dea46648d65a05c430cd822f08db6aaa18c7f35cc9b93c22396"+ },+ "showItemsPlayedState": {+ "kind": "query",+ "hash": "4a070b9bfab2e8537a5271e6839bc3ef51501dcac8170b5fb69a98f967c5fb60"+ },+ "similarAlbumsBasedOnThisTrack": {+ "kind": "query",+ "hash": "1d1f93a737498adca2c892c73af87fc0b052afe4e1a33c989540c32413dfae17"+ },+ "similarAudiobooks": {+ "kind": "query",+ "hash": "d62da1bbf5859e5a156da1f52ce21a73a642f925db717a179fd89626b27a80b8"+ },+ "smartShuffle": {+ "kind": "query",+ "hash": "3384085be84fbf2f855b024f99bc06cded1c0fd71af3a8fb8abb84e9656faba2"+ },+ "thisisPlaylistExtension": {+ "kind": "query",+ "hash": "906c2e14927400c8a71645c647576ce032f837a112d5e6f9375b19c80445c8cf"+ },+ "trackPreview": {+ "kind": "query",+ "hash": "fc26ffc7a1a4f93bd4c2d705649f7dba1de34005b3dc2915549847a9959405d8"+ },+ "undoConcertCampaignNotInterested": {+ "kind": "mutation",+ "hash": "efb05c3c9a617885cbce2c90a5cc758ec79dc13807d988489a2fe5b83739bfe1"+ },+ "unfollowUsers": {+ "kind": "mutation",+ "hash": "c00e0cb6c7766e7230fc256cf4fe07aec63b53d1160a323940fce7b664e95596"+ },+ "unpinLibraryItem": {+ "kind": "mutation",+ "hash": "896ebcb47815681340860d121cb5d494e157e2a78d3950385cd54e0393c67148"+ },+ "userAccountId": {+ "kind": "query",+ "hash": "c56c2b33c2ded49960530771844ed482ffc1518169fb3d0dda91ac1608b019e2"+ },+ "userLocation": {+ "kind": "query",+ "hash": "079939378ca79b67c6d047be9152ea940d21f10bbfa2f5d4cf4d8320d87774c2"+ },+ "userTopContent": {+ "kind": "query",+ "hash": "61b7353d3625780022dbc63d459eb64cd609e7e5e2a820f9160d65030efe2e15"+ },+ "venue": {+ "kind": "query",+ "hash": "6c55ebc91fc13a25d7df590c4a9031dd1dcdc25716192d7f848a8270f49d2c13"+ },+ "watchFeedEntity": {+ "kind": "query",+ "hash": "d1a805f815ee0c20281330317d8c00c8fce9026686a86c38bc700ccaefb9ac5c"+ },+ "watchFeedView": {+ "kind": "query",+ "hash": "ce10864fccc53ca77c422143ee027bacf220f9d714e27ec592905334079ad743"+ },+ "whatsNewFeedNewItems": {+ "kind": "query",+ "hash": "d889c8c936ab192af8ced595427f5ba2acdf63478fdc0a181c8d477f8322630e"+ }+ }+}diff --git a/base/api-spotify/src/main/resources/spotify/gql-schema.json b/base/api-spotify/src/main/resources/spotify/gql-schema.jsonnew file mode 100644index 00000000..46ee571d--- /dev/null+++ b/base/api-spotify/src/main/resources/spotify/gql-schema.json@@ -0,0 +1,2313 @@+{+ "ArtistConcerts": {+ "kind": "query",+ "required": {+ "includeNearby": "Boolean!",+ "artistUri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "ArtistConcertsPageLocation": {+ "kind": "query",+ "required": {},+ "optional": [],+ "example": {},+ "probed": true+ },+ "ConcertCampaign": {+ "kind": "query",+ "required": {+ "includeNearby": "Boolean!",+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "ConcertGallery": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "SetItemsStateInWhatsNewFeed": {+ "kind": "mutation",+ "required": {+ "items": "SetItemsStateInWhatsNewFeedInput!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "accountAttributes": {+ "kind": "query",+ "required": {},+ "optional": [],+ "example": {},+ "probed": true+ },+ "addComment": {+ "kind": "mutation",+ "required": {+ "text": "String!",+ "entityUri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "addCommentReaction": {+ "kind": "mutation",+ "required": {+ "reactionUnicode": "String!",+ "commentUri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "addCommentReply": {+ "kind": "mutation",+ "required": {+ "commentUri": "ID!",+ "text": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "addToLibrary": {+ "kind": "mutation",+ "required": {+ "libraryItemUris": "[String!]!"+ },+ "optional": [+ "interactionId"+ ],+ "example": {+ "libraryItemUris": [+ "spotify:artist:1McMsnEElThX1knmY4oliG"+ ],+ "interactionId": "{uuid}"+ },+ "probed": true+ },+ "addToPlaylist": {+ "kind": "mutation",+ "required": {+ "playlistUri": "String!",+ "playlistItemUris": "[String!]!",+ "newPosition": "PlaylistItemPositionInput!"+ },+ "optional": [+ "interactionId"+ ],+ "example": {+ "playlistItemUris": [+ "spotify:track:70cHKK8bHAfJrOGVnfRG9J"+ ],+ "playlistUri": "spotify:playlist:52t4IPlr6627H1STRh2FGW",+ "newPosition": {+ "moveType": "BOTTOM_OF_PLAYLIST",+ "fromUid": null+ },+ "interactionId": "{uuid}"+ },+ "probed": true+ },+ "addVenueToLibrary": {+ "kind": "mutation",+ "required": {+ "venueUri": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "albumPreRelease": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "albumPreReleaseTracks": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "limit",+ "offset"+ ],+ "example": {},+ "probed": true+ },+ "applyCurations": {+ "kind": "mutation",+ "required": {+ "input": "ApplyCurationsInput!"+ },+ "optional": [],+ "example": {+ "input": {+ "curations": [+ {+ "contextUri": "spotify:playlist:37i9dQZF1F5p3rmiWPIYgZ",+ "curationType": "UNCURATE"+ }+ ],+ "itemUris": [+ "spotify:track:4EoJ151oQ5jY48z4RhSE96"+ ]+ }+ },+ "probed": true+ },+ "applyCurationsV2": {+ "kind": "mutation",+ "required": {+ "input": "ApplyCurationsInputV2!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "areEntitiesInLibrary": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [],+ "example": {+ "uris": [+ "spotify:episode:7kDlpm1xDML49QuzV4Hbs2",+ "spotify:episode:3KNbJvoYkXN9hgfeUXYigS",+ "spotify:episode:5Ayc3yoBQ9OaGD3sSLVvMi",+ "spotify:episode:53iR7S2IWbKAOXEVVEnagR",+ "spotify:episode:3zYi5sHNNcdkDyPaIiRcI4",+ "spotify:episode:2HLbu2WV35q1RbvBnNiMhb",+ "spotify:episode:1R1SJeNffUTr9iILWo3dxy",+ "spotify:episode:1amTi28juSptAkSJsASBBH",+ "spotify:episode:2Fcp88MiSafUs7Yl1Y4vdE",+ "spotify:episode:4YT81bGQeeqYz4hJeUygTb",+ "spotify:episode:3fpHVxurRyluUe6MfKPtuJ",+ "spotify:episode:6PwAQQh30IXdo5WaclPunu",+ "spotify:episode:0CWZGCQb4YVzmiNVE8Pifk",+ "spotify:episode:6YxqbXZXUbwEyYnFtJ15kS",+ "spotify:episode:5X3Vy1L4OThzBHOZRdNO09",+ "spotify:episode:6JYEre5sEc74iYYe0ZTVh6",+ "spotify:episode:41Li1M34WY9cVxtJx6jLax",+ "spotify:episode:0tnkdp6hDPCPQqqY0wdkdy",+ "spotify:episode:2yOfsFdSqAWanRXJmaIBSs",+ "spotify:episode:6ZpTA2OLRsgBV3G1uN4pYC",+ "spotify:episode:5oyGgLLKJIn6VnDS1VLE7D",+ "spotify:episode:0vKWNw6P3xwHZ38WX6Yfax",+ "spotify:episode:1kuZLSHJX1z6Skt1TMvylC",+ "spotify:episode:6SC8ZvVLN3CeTwuVVuknSr",+ "spotify:episode:754xT5eYoIcrkAK7xCMTZt",+ "spotify:episode:7nk9DgyoB6zcPCdYohJ1F3",+ "spotify:episode:0LHIqeO20ni8JNtxH43MgM",+ "spotify:episode:1fPQFzXXsWqH22ewAmTZJF",+ "spotify:episode:2SAplEelVg0yH1ktmjjc1V",+ "spotify:episode:1CqBVw0GntNd4FLMCLEjWl"+ ]+ },+ "probed": true+ },+ "assistedCurationSearch": {+ "kind": "query",+ "required": {+ "term": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "assistedCurationSearchAlbum": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [+ "limit",+ "offset"+ ],+ "example": {},+ "probed": true+ },+ "assistedCurationSearchArtist": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [+ "limit",+ "offset",+ "topTracksLimit"+ ],+ "example": {},+ "probed": true+ },+ "browseAll": {+ "kind": "query",+ "required": {+ "sectionPagination": "PaginationInput!",+ "browseEndUserIntegration": "BrowseEndUserIntegration!",+ "pagePagination": "PaginationInput!"+ },+ "optional": [],+ "example": {+ "pagePagination": {+ "offset": 0,+ "limit": 10+ },+ "sectionPagination": {+ "offset": 0,+ "limit": 99+ },+ "browseEndUserIntegration": "INTEGRATION_WEB_PLAYER"+ },+ "probed": true+ },+ "browsePage": {+ "kind": "query",+ "required": {+ "sectionPagination": "PaginationInput!",+ "uri": "ID!",+ "browseEndUserIntegration": "BrowseEndUserIntegration!",+ "pagePagination": "PaginationInput!"+ },+ "optional": [+ "includeEpisodeContentRatingsV2"+ ],+ "example": {+ "pagePagination": {+ "offset": 0,+ "limit": 10+ },+ "sectionPagination": {+ "offset": 0,+ "limit": 10+ },+ "uri": "spotify:page:0JQ5DAqbMKFSi39LMRT0Cy",+ "browseEndUserIntegration": "INTEGRATION_WEB_PLAYER",+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "browseSection": {+ "kind": "query",+ "required": {+ "pagination": "PaginationInput!",+ "uri": "ID!",+ "browseEndUserIntegration": "BrowseEndUserIntegration!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "canvas": {+ "kind": "query",+ "required": {+ "trackUri": "ID!"+ },+ "optional": [],+ "example": {+ "trackUri": "spotify:track:55vPnuXfuzXNW75JpuSczF"+ },+ "probed": true+ },+ "centralisedStatePlayerOptions": {+ "kind": "query",+ "required": {+ "uri": "ID!",+ "deviceInfo": "PlayerOptionsDeviceInfo!"+ },+ "optional": [],+ "example": {+ "uri": "spotify:list:popular-release-segments-main-roles:artist_1McMsnEElThX1knmY4oliG",+ "deviceInfo": {+ "deviceId": "c7e057a5c00d8662d2f203890086709b4bdc1745",+ "deviceType": "computer",+ "clientId": "d8a5ed958d274c2e8ee717e6a4b0971d",+ "clientVersion": "1.3.6.1858.gc66299947cb4",+ "productId": "1"+ }+ },+ "probed": true+ },+ "changeAttributes": {+ "kind": "mutation",+ "required": {+ "input": "ChangeUserAccountAttributesInput!"+ },+ "optional": [+ "children"+ ],+ "example": {},+ "probed": true+ },+ "concert": {+ "kind": "query",+ "required": {+ "authenticated": "Boolean!",+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "concertConcepts": {+ "kind": "query",+ "required": {+ "geohash": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "concertCount": {+ "kind": "query",+ "required": {+ "radiusInKm": "Int!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "concertFeed": {+ "kind": "query",+ "required": {},+ "optional": [],+ "example": {},+ "probed": true+ },+ "concertLocationDetails": {+ "kind": "query",+ "required": {+ "isAnonymous": "Boolean!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "concertLocationsByLatLon": {+ "kind": "query",+ "required": {},+ "optional": [],+ "example": {},+ "probed": true+ },+ "concertNotInterestedSet": {+ "kind": "mutation",+ "required": {},+ "optional": [],+ "example": {},+ "probed": true+ },+ "concertNotInterestedUndo": {+ "kind": "mutation",+ "required": {},+ "optional": [],+ "example": {},+ "probed": true+ },+ "concertRoutingCardVisuals": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "countryHubContent": {+ "kind": "query",+ "required": {+ "countryCode": "String!",+ "contentId": "CountryHubContentId!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "countryHubsPage": {+ "kind": "query",+ "required": {+ "countryCode": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "curateItems": {+ "kind": "mutation",+ "required": {+ "input": "CurateItemsInput!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "decorateContextEpisodesOrChapters": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [+ "includeEpisodeContentRatingsV2"+ ],+ "example": {},+ "probed": true+ },+ "decorateContextTracks": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [],+ "example": {+ "uris": [+ "spotify:track:55vPnuXfuzXNW75JpuSczF",+ "spotify:track:0T1CzbjyOEU60cL5G244di",+ "spotify:track:6AoOzPhqx5LbtYfKBlBrEG",+ "spotify:track:0tlpV1zgFg5iFrj1cIwQhn",+ "spotify:track:4frYOVaMfQ7iyvKLehnARi",+ "spotify:track:7heoPFrtuH6JU6AcfzjWHp",+ "spotify:track:5TVOGVhEQNEdnkVYCtE5p5",+ "spotify:track:6FAoIVpBja2wbmPEP6gKat",+ "spotify:track:30RmEyZdIYdYpSTkMtgtKt",+ "spotify:track:2toEys3zZ8rRB242Na7FZh",+ "spotify:track:3cWjdZ42pKynP9yOt6xlnA",+ "spotify:track:3CBjC9bcb5MzAnP4Hu9SVL",+ "spotify:track:0frABA1e4eX0HKmEFxtkEC",+ "spotify:track:6QEvbmv2euCQxX54gjlarO",+ "spotify:track:0FbNxtUbetsjF7s42pkOIS",+ "spotify:track:7xWvRVssTTECvWCDNgCzSH",+ "spotify:track:5rKSFzy6TQtPX71xTw6k9P",+ "spotify:track:656vbT8JKkVx7g1yG12L89",+ "spotify:track:2TL8q8EO60b9lWeozfqYnG",+ "spotify:track:0p1jyG640jfYCes1EagSsU",+ "spotify:track:5nODbxjT7KZt9cUX0xJwQs",+ "spotify:track:7p6NSzWnUxZCkae3UIj0aY",+ "spotify:track:3nq3hIQOwKHRgd44Y06Ijq",+ "spotify:track:5xYNLzZzgN3r6YPcQgNcJD",+ "spotify:track:0doFYnqgcStWu1Emh8DTVo",+ "spotify:track:3nR6ytbSKOF4NxsgqrYG9u",+ "spotify:track:4cSHMHSTRhetAtT1iDP2zO",+ "spotify:track:6YG2IJB93if1Cv8QxNHesA",+ "spotify:track:7gmwFiZtsPyBT8wI2u6mGN",+ "spotify:track:3fXieGSDq0uwQP7vM7zoZH",+ "spotify:track:3ReDT1HLea9eTWEPtwE7fP",+ "spotify:track:6nkFbmDY84a9rejFSbIMdj",+ "spotify:track:4jgj7dTIByN8OXmX4s9QHI",+ "spotify:track:1IrZSqnG09Mtfe2L399cNj",+ "spotify:track:7CUAGxYmpmSJv9pbLgqVjy",+ "spotify:track:4sLFiAxqRm0DYjUfdWznXI",+ "spotify:track:48aYpdLDRq1aJKHRhineq6",+ "spotify:track:5pZJSiwMzuiwP4AIlNbRDZ",+ "spotify:track:6qvyN6NTUpdfOJRYjtSSd7",+ "spotify:track:3Lgri1rcCPb99ezlE0SWTB",+ "spotify:track:2oe4ERf40Mx8PWH9gtEfP0",+ "spotify:track:1aLHvqPB5CxGYzhJB7Hzo1",+ "spotify:track:0EudwuzwEbV7YA1LLwwIbv",+ "spotify:track:4cLspfLk7lebgQMDoZgSKD",+ "spotify:track:3gAEAmxdP1GIjgQ3Zud2mE",+ "spotify:track:22NVP1etEr1pJEBQMk7E0C",+ "spotify:track:7MqfFNdKFJMgLrmDXE7rAK",+ "spotify:track:50MqZttaClW6PjgsugWGlg",+ "spotify:track:7J9bfRJYMHLAWpAvwSxCxG",+ "spotify:track:1pqKCnjkTBcAX6NyzSDahf"+ ]+ },+ "probed": true+ },+ "decorateQueuedByUsers": {+ "kind": "query",+ "required": {+ "userUris": "[ID!]!"+ },+ "optional": [],+ "example": {+ "userUris": [+ "spotify:user:{user}"+ ]+ },+ "probed": true+ },+ "deleteComment": {+ "kind": "mutation",+ "required": {+ "commentUri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "deleteCommentReaction": {+ "kind": "mutation",+ "required": {+ "commentUri": "ID!"+ },+ "optional": [+ "fallback"+ ],+ "example": {},+ "probed": true+ },+ "deleteCommentReply": {+ "kind": "mutation",+ "required": {+ "replyUri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "deleteLocation": {+ "kind": "mutation",+ "required": {},+ "optional": [],+ "example": {},+ "probed": true+ },+ "editablePlaylists": {+ "kind": "query",+ "required": {},+ "optional": [+ "features",+ "folderUri",+ "limit",+ "offset",+ "textFilter",+ "uris"+ ],+ "example": {+ "offset": 0,+ "limit": 50,+ "textFilter": "",+ "uris": [+ "spotify:track:4EoJ151oQ5jY48z4RhSE96"+ ]+ },+ "probed": true+ },+ "episodeSponsoredContent": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "fetchEntitiesForRecentlyPlayed": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [],+ "example": {+ "uris": [+ "spotify:playlist:37i9dQZF1EIZKQBmjpvc47"+ ]+ },+ "probed": true+ },+ "fetchExtractedColorAndImageForAlbumEntity": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "fetchExtractedColorAndImageForArtistEntity": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "fetchExtractedColorAndImageForEpisodeEntity": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "fetchExtractedColorAndImageForPlaylistEntity": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "fetchExtractedColorAndImageForPodcastEntity": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "fetchExtractedColorAndImageForTrackEntity": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "fetchExtractedColorForAlbumEntity": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "fetchExtractedColorForArtistEntity": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "fetchExtractedColorForEpisodeEntity": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "fetchExtractedColorForPlaylistEntity": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "fetchExtractedColorForPodcastEntity": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "fetchExtractedColorForTrackEntity": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "fetchExtractedColors": {+ "kind": "query",+ "required": {+ "imageUris": "[ID!]!"+ },+ "optional": [],+ "example": {+ "imageUris": [+ "https://pickasso.spotifycdn.com/image/ab67c0de0000deef/dt/v1/img/artistmix/7rz6ZZErn5YFDteXKhyf3g/fr",+ "https://pickasso.spotifycdn.com/image/ab67c0de0000deef/dt/v1/img/radio/artist/7rz6ZZErn5YFDteXKhyf3g/fr"+ ]+ },+ "probed": true+ },+ "fetchLibraryTracks": {+ "kind": "query",+ "required": {},+ "optional": [+ "limit",+ "offset"+ ],+ "example": {},+ "probed": true+ },+ "fetchPlaylist": {+ "kind": "query",+ "required": {+ "enableWatchFeedEntrypoint": "Boolean!",+ "uri": "ID!"+ },+ "optional": [+ "includeEpisodeContentRatingsV2",+ "limit",+ "offset"+ ],+ "example": {+ "uri": "spotify:playlist:37i9dQZF1EIZKQBmjpvc47",+ "offset": 0,+ "limit": 25,+ "enableWatchFeedEntrypoint": true,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "fetchPlaylistContents": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "includeEpisodeContentRatingsV2",+ "limit",+ "offset"+ ],+ "example": {+ "uri": "spotify:playlist:37i9dQZF1EIZKQBmjpvc47",+ "offset": 25,+ "limit": 50,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "fetchPlaylistMetadata": {+ "kind": "query",+ "required": {+ "uri": "ID!",+ "enableWatchFeedEntrypoint": "Boolean!"+ },+ "optional": [+ "limit",+ "offset"+ ],+ "example": {+ "uri": "spotify:playlist:37i9dQZF1EYkqdzj48dyYq",+ "offset": 0,+ "limit": 100,+ "enableWatchFeedEntrypoint": true+ },+ "probed": true+ },+ "followUsers": {+ "kind": "mutation",+ "required": {+ "usernames": "[String!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "getAlbum": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "limit",+ "locale",+ "offset"+ ],+ "example": {+ "uri": "spotify:album:6zme2NwcaBxbn3mWOcMY8y",+ "locale": "intl-fr",+ "offset": 0,+ "limit": 50+ },+ "probed": true+ },+ "getAlbumNameAndTracks": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "getArtistNameAndTracks": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "getAudiobooksMetadata": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "getCommentsForEntity": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "token"+ ],+ "example": {+ "uri": "spotify:episode:3bJKyYG8VZdVW8nH5petM3",+ "token": null+ },+ "probed": true+ },+ "getDynamicColors": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "getDynamicColorsByUris": {+ "kind": "query",+ "required": {+ "imageUris": "[ID!]!"+ },+ "optional": [],+ "example": {+ "imageUris": [+ "https://i.scdn.co/image/ab67616d0000b273db29800222c202ae748cba1b"+ ]+ },+ "probed": true+ },+ "getEpisodeName": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "getEpisodeOrChapter": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "includeEpisodeContentRatingsV2"+ ],+ "example": {+ "uri": "spotify:episode:3bJKyYG8VZdVW8nH5petM3",+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "getLists": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [+ "limit",+ "offset"+ ],+ "example": {},+ "probed": true+ },+ "getListsContents": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [+ "limit",+ "offset"+ ],+ "example": {},+ "probed": true+ },+ "getListsMetadata": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "getPodcastOrBookName": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "getReactions": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "reactionUnicode",+ "token"+ ],+ "example": {},+ "probed": true+ },+ "getReplies": {+ "kind": "query",+ "required": {+ "commentUri": "ID!"+ },+ "optional": [+ "pageToken"+ ],+ "example": {},+ "probed": true+ },+ "getTrack": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "includeVideoAssociationItems"+ ],+ "example": {+ "uri": "spotify:track:30RmEyZdIYdYpSTkMtgtKt",+ "includeVideoAssociationItems": true+ },+ "probed": true+ },+ "getTrackName": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "getVideoTrackAssociatedAlbum": {+ "kind": "query",+ "required": {+ "trackUri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "home": {+ "kind": "query",+ "required": {+ "timeZone": "String!",+ "homeEndUserIntegration": "HomeEndUserIntegration!"+ },+ "optional": [+ "facet",+ "includeEpisodeContentRatingsV2",+ "includeHomeChapterVideoCards",+ "sectionItemsLimit",+ "sp_t"+ ],+ "example": {+ "includeHomeChapterVideoCards": false,+ "homeEndUserIntegration": "INTEGRATION_WEB_PLAYER",+ "timeZone": "Europe/Zurich",+ "sp_t": "{sp_t}",+ "facet": "",+ "sectionItemsLimit": 10,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "homePinnedSections": {+ "kind": "query",+ "required": {+ "timeZone": "String!",+ "homeEndUserIntegration": "HomeEndUserIntegration!",+ "uris": "[String!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "homeSection": {+ "kind": "query",+ "required": {+ "homeEndUserIntegration": "HomeEndUserIntegration!",+ "timeZone": "String!",+ "uri": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "inferredUserLocation": {+ "kind": "query",+ "required": {},+ "optional": [],+ "example": {},+ "probed": true+ },+ "internalLinkRecommenderEpisode": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "children",+ "includeEpisodeContentRatingsV2"+ ],+ "example": {+ "uri": "spotify:episode:3bJKyYG8VZdVW8nH5petM3",+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "internalLinkRecommenderShow": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {+ "uri": "spotify:show:3vS7gWYpz4ry0yRnQ345hU"+ },+ "probed": true+ },+ "internalLinkRecommenderTrack": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "creator",+ "isSmallIcon",+ "leading",+ "limit",+ "onClick",+ "prefix",+ "suffix"+ ],+ "example": {+ "uri": "spotify:track:30RmEyZdIYdYpSTkMtgtKt",+ "limit": 5+ },+ "probed": true+ },+ "isCurated": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [],+ "example": {+ "uris": [+ "spotify:episode:7kDlpm1xDML49QuzV4Hbs2",+ "spotify:episode:3KNbJvoYkXN9hgfeUXYigS",+ "spotify:episode:5Ayc3yoBQ9OaGD3sSLVvMi",+ "spotify:episode:53iR7S2IWbKAOXEVVEnagR",+ "spotify:episode:3zYi5sHNNcdkDyPaIiRcI4",+ "spotify:episode:2HLbu2WV35q1RbvBnNiMhb",+ "spotify:episode:1R1SJeNffUTr9iILWo3dxy",+ "spotify:episode:1amTi28juSptAkSJsASBBH",+ "spotify:episode:2Fcp88MiSafUs7Yl1Y4vdE",+ "spotify:episode:4YT81bGQeeqYz4hJeUygTb",+ "spotify:episode:3fpHVxurRyluUe6MfKPtuJ",+ "spotify:episode:6PwAQQh30IXdo5WaclPunu",+ "spotify:episode:0CWZGCQb4YVzmiNVE8Pifk",+ "spotify:episode:6YxqbXZXUbwEyYnFtJ15kS",+ "spotify:episode:5X3Vy1L4OThzBHOZRdNO09",+ "spotify:episode:6JYEre5sEc74iYYe0ZTVh6",+ "spotify:episode:41Li1M34WY9cVxtJx6jLax",+ "spotify:episode:0tnkdp6hDPCPQqqY0wdkdy",+ "spotify:episode:2yOfsFdSqAWanRXJmaIBSs",+ "spotify:episode:6ZpTA2OLRsgBV3G1uN4pYC",+ "spotify:episode:5oyGgLLKJIn6VnDS1VLE7D",+ "spotify:episode:0vKWNw6P3xwHZ38WX6Yfax",+ "spotify:episode:1kuZLSHJX1z6Skt1TMvylC",+ "spotify:episode:6SC8ZvVLN3CeTwuVVuknSr",+ "spotify:episode:754xT5eYoIcrkAK7xCMTZt",+ "spotify:episode:7nk9DgyoB6zcPCdYohJ1F3",+ "spotify:episode:0LHIqeO20ni8JNtxH43MgM",+ "spotify:episode:1fPQFzXXsWqH22ewAmTZJF",+ "spotify:episode:2SAplEelVg0yH1ktmjjc1V",+ "spotify:episode:1CqBVw0GntNd4FLMCLEjWl"+ ]+ },+ "probed": true+ },+ "isCuratedEntities": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "isFollowingUsers": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "libraryV3": {+ "kind": "query",+ "required": {},+ "optional": [+ "expandedFolders",+ "features",+ "flatten",+ "folderUri",+ "includeFoldersWhenFlattening",+ "limit",+ "offset",+ "order",+ "textFilter"+ ],+ "example": {+ "order": null,+ "textFilter": "",+ "features": [+ "LIKED_SONGS",+ "YOUR_EPISODES_V2",+ "PRERELEASES",+ "PRERELEASES_V2",+ "CLIPS",+ "EVENTS"+ ],+ "limit": 50,+ "offset": 0,+ "flatten": false,+ "expandedFolders": [],+ "folderUri": null,+ "includeFoldersWhenFlattening": true+ },+ "probed": true+ },+ "lookupChildEntities": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [],+ "example": {+ "uris": [+ "spotify:track:70cHKK8bHAfJrOGVnfRG9J",+ "spotify:playlist:37i9dQZF1F5p3rmiWPIYgZ"+ ]+ },+ "probed": true+ },+ "lookupDebug": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "lookupEntityImages": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "moveItemsInPlaylist": {+ "kind": "mutation",+ "required": {+ "newPosition": "PlaylistItemPositionInput!",+ "playlistUri": "String!",+ "uids": "[String!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "npvPageContent": {+ "kind": "query",+ "required": {+ "endUserIntegration": "EndUserIntegration!",+ "nowPlayingUri": "ID!",+ "playContextUri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "npvV2TrackSupplementalSections": {+ "kind": "query",+ "required": {+ "enableRelatedVideos": "Boolean!",+ "trackUri": "ID!"+ },+ "optional": [],+ "example": {+ "trackUri": "spotify:track:55vPnuXfuzXNW75JpuSczF",+ "enableRelatedVideos": true+ },+ "probed": true+ },+ "pinLibraryItem": {+ "kind": "mutation",+ "required": {+ "pinnableItemUri": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "playlistPermissions": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {+ "uri": "spotify:playlist:37i9dQZF1EIZKQBmjpvc47"+ },+ "probed": true+ },+ "playlistSection": {+ "kind": "query",+ "required": {+ "sectionUri": "String!",+ "playlistUri": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "profileAttributes": {+ "kind": "query",+ "required": {},+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryAlbumMerch": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {+ "uri": "spotify:album:6zme2NwcaBxbn3mWOcMY8y"+ },+ "probed": true+ },+ "queryAlbumTrackUris": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryAlbumTracks": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "limit",+ "offset"+ ],+ "example": {+ "uri": "spotify:album:2g6XbbyPIPRMa2P1ildhza",+ "offset": 0,+ "limit": 300+ },+ "probed": true+ },+ "queryArtistAboutModal": {+ "kind": "query",+ "required": {+ "artistUri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryArtistAppearsOn": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryArtistDiscographyAlbums": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "limit",+ "offset",+ "order"+ ],+ "example": {},+ "probed": true+ },+ "queryArtistDiscographyAll": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "limit",+ "offset",+ "order"+ ],+ "example": {+ "uri": "spotify:artist:1McMsnEElThX1knmY4oliG",+ "offset": 0,+ "limit": 20,+ "order": "DATE_DESC"+ },+ "probed": true+ },+ "queryArtistDiscographyCompilations": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "limit",+ "offset",+ "order"+ ],+ "example": {},+ "probed": true+ },+ "queryArtistDiscographyOverview": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {+ "uri": "spotify:artist:1McMsnEElThX1knmY4oliG"+ },+ "probed": true+ },+ "queryArtistDiscographySingles": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "limit",+ "offset",+ "order"+ ],+ "example": {},+ "probed": true+ },+ "queryArtistDiscoveredOn": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryArtistFeaturing": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryArtistMinimal": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryArtistOverview": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "locale",+ "preReleaseV2"+ ],+ "example": {+ "uri": "spotify:artist:1McMsnEElThX1knmY4oliG",+ "locale": "intl-fr",+ "preReleaseV2": true+ },+ "probed": true+ },+ "queryArtistPlaylists": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryArtistRelated": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {+ "uri": "spotify:artist:1McMsnEElThX1knmY4oliG"+ },+ "probed": true+ },+ "queryArtistRelatedVideos": {+ "kind": "query",+ "required": {+ "uri": "ID!",+ "showMapped": "Boolean!",+ "limit": "Int!",+ "offset": "Int!",+ "showUnmapped": "Boolean!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryBookChapters": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "limit",+ "offset"+ ],+ "example": {},+ "probed": true+ },+ "queryInlineCurationSearchAlbum": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [+ "limit",+ "offset"+ ],+ "example": {},+ "probed": true+ },+ "queryInlineCurationSearchArtist": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [+ "limit",+ "offset"+ ],+ "example": {},+ "probed": true+ },+ "queryInlineCurationSearchV2": {+ "kind": "query",+ "required": {+ "term": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryInlineCurationSearchV2Booklists": {+ "kind": "query",+ "required": {+ "term": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryMoreByArtist": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryNpvArtist": {+ "kind": "query",+ "required": {+ "artistUri": "ID!",+ "enableRelatedVideos": "Boolean!",+ "enableRelatedAudioTracks": "Boolean!",+ "trackUri": "ID!"+ },+ "optional": [+ "contributorsLimit",+ "contributorsOffset"+ ],+ "example": {+ "artistUri": "spotify:artist:0RRp1XbMoTmW8zSWC1synA",+ "trackUri": "spotify:track:0T1CzbjyOEU60cL5G244di",+ "contributorsLimit": 10,+ "contributorsOffset": 0,+ "enableRelatedVideos": true,+ "enableRelatedAudioTracks": true+ },+ "probed": true+ },+ "queryNpvEpisode": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryPodcastEpisodes": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "includeEpisodeContentRatingsV2",+ "limit",+ "offset",+ "variant"+ ],+ "example": {+ "uri": "spotify:show:3vS7gWYpz4ry0yRnQ345hU",+ "offset": 0,+ "limit": 50,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "queryShowMetadataV2": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [+ "includeContentCapabilityTrait",+ "includeEpisodeContentRatingsV2"+ ],+ "example": {+ "uri": "spotify:show:3vS7gWYpz4ry0yRnQ345hU",+ "includeContentCapabilityTrait": true,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "queryTrackArtists": {+ "kind": "query",+ "required": {+ "trackUri": "ID!"+ },+ "optional": [],+ "example": {+ "trackUri": "spotify:track:7heoPFrtuH6JU6AcfzjWHp"+ },+ "probed": true+ },+ "queryTrackCreditsGroupedModal": {+ "kind": "query",+ "required": {+ "trackUri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "queryWhatsNewFeed": {+ "kind": "query",+ "required": {+ "onlyUnPlayedItems": "Boolean!",+ "offset": "Int!",+ "limit": "Int!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "recentSearches": {+ "kind": "query",+ "required": {},+ "optional": [+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "limit"+ ],+ "example": {+ "limit": 50,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "recents": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [+ "limit",+ "offset"+ ],+ "example": {},+ "probed": true+ },+ "removeFromLibrary": {+ "kind": "mutation",+ "required": {+ "libraryItemUris": "[String!]!"+ },+ "optional": [],+ "example": {+ "libraryItemUris": [+ "spotify:artist:1McMsnEElThX1knmY4oliG"+ ]+ },+ "probed": true+ },+ "removeFromPlaylist": {+ "kind": "mutation",+ "required": {+ "playlistUri": "String!",+ "uids": "[String!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "removeRecentSearches": {+ "kind": "mutation",+ "required": {+ "uris": "[String!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "removeVenueFromLibrary": {+ "kind": "mutation",+ "required": {+ "venueUri": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "requestPromoCode": {+ "kind": "mutation",+ "required": {+ "accessCode": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "saveLocation": {+ "kind": "mutation",+ "required": {+ "geonameId": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "saveRecentSearches": {+ "kind": "mutation",+ "required": {+ "uris": "[String!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "searchAlbums": {+ "kind": "query",+ "required": {+ "searchTerm": "String!"+ },+ "optional": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "orelsan",+ "offset": 0,+ "limit": 30,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "searchArtists": {+ "kind": "query",+ "required": {+ "searchTerm": "String!"+ },+ "optional": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "orelsan",+ "offset": 0,+ "limit": 30,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "searchAudiobooks": {+ "kind": "query",+ "required": {+ "searchTerm": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "searchAuthors": {+ "kind": "query",+ "required": {+ "searchTerm": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "searchConcertLocations": {+ "kind": "query",+ "required": {+ "query": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "searchDesktop": {+ "kind": "query",+ "required": {+ "limit": "Int!",+ "numberOfTopResults": "Int!",+ "searchTerm": "String!",+ "includeAudiobooks": "Boolean!",+ "offset": "Int!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "searchEpisodes": {+ "kind": "query",+ "required": {+ "searchTerm": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "searchFullEpisodes": {+ "kind": "query",+ "required": {+ "searchTerm": "String!"+ },+ "optional": [+ "includeEpisodeContentRatingsV2",+ "limit",+ "offset"+ ],+ "example": {+ "searchTerm": "france inter",+ "offset": 0,+ "limit": 30,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "searchGenres": {+ "kind": "query",+ "required": {+ "searchTerm": "String!"+ },+ "optional": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "rap",+ "offset": 0,+ "limit": 30,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "searchModalEntityPage": {+ "kind": "query",+ "required": {+ "includeAuthors": "Boolean!",+ "uri": "ID!",+ "numberOfResults": "Int!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "searchModalResults": {+ "kind": "query",+ "required": {+ "includeAuthors": "Boolean!",+ "searchTerm": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "searchPlaylists": {+ "kind": "query",+ "required": {+ "searchTerm": "String!"+ },+ "optional": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "orelsan",+ "offset": 0,+ "limit": 30,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "searchPodcasts": {+ "kind": "query",+ "required": {+ "searchTerm": "String!"+ },+ "optional": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "france inter",+ "offset": 0,+ "limit": 30,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "searchSuggestions": {+ "kind": "query",+ "required": {+ "query": "String!"+ },+ "optional": [+ "includeAlbumPreReleases",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "limit",+ "numberOfTopResults",+ "offset"+ ],+ "example": {+ "query": "orelsan",+ "limit": 30,+ "numberOfTopResults": 30,+ "offset": 0,+ "includeAuthors": true,+ "includeAlbumPreReleases": false,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "searchTopResultsList": {+ "kind": "query",+ "required": {+ "query": "String!"+ },+ "optional": [+ "includeAlbumPreReleases",+ "includeArtistHasConcertsField",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "isPrefix",+ "limit",+ "numberOfTopResults",+ "offset",+ "sectionFilters"+ ],+ "example": {+ "query": "france inter",+ "limit": 50,+ "offset": 0,+ "numberOfTopResults": 50,+ "includeArtistHasConcertsField": false,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includePreReleases": true,+ "includeAlbumPreReleases": false,+ "includeEpisodeContentRatingsV2": true,+ "isPrefix": null,+ "sectionFilters": [+ "GENERIC",+ "VIDEO_CONTENT"+ ]+ },+ "probed": true+ },+ "searchTopResultsOnly": {+ "kind": "query",+ "required": {+ "searchTerm": "String!",+ "includeAudiobooks": "Boolean!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "searchTracks": {+ "kind": "query",+ "required": {+ "searchTerm": "String!"+ },+ "optional": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "orelsan",+ "offset": 0,+ "limit": 20,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "searchUsers": {+ "kind": "query",+ "required": {+ "searchTerm": "String!"+ },+ "optional": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "kotazo",+ "offset": 0,+ "limit": 30,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ },+ "probed": true+ },+ "seoRecommendedTrackPlaylistDesktop": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "showItemsPlayedState": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "similarAlbumsBasedOnThisTrack": {+ "kind": "query",+ "required": {+ "limit": "Int!",+ "uri": "ID!"+ },+ "optional": [+ "albumsOnly"+ ],+ "example": {+ "uri": "spotify:track:30RmEyZdIYdYpSTkMtgtKt",+ "limit": 50,+ "albumsOnly": true+ },+ "probed": true+ },+ "similarAudiobooks": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "smartShuffle": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "thisisPlaylistExtension": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "trackPreview": {+ "kind": "query",+ "required": {+ "uris": "[ID!]!"+ },+ "optional": [+ "ariaColIndex",+ "children",+ "className",+ "columnType",+ "size"+ ],+ "example": {},+ "probed": true+ },+ "undoConcertCampaignNotInterested": {+ "kind": "mutation",+ "required": {+ "concertCampaignUri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "unfollowUsers": {+ "kind": "mutation",+ "required": {+ "usernames": "[String!]!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "unpinLibraryItem": {+ "kind": "mutation",+ "required": {+ "pinnableItemUri": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "userAccountId": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "userLocation": {+ "kind": "query",+ "required": {},+ "optional": [],+ "example": {},+ "probed": true+ },+ "userTopContent": {+ "kind": "query",+ "required": {+ "topArtistsInput": "AffinityInput!",+ "includeTopTracks": "Boolean!",+ "includeTopArtists": "Boolean!",+ "topTracksInput": "AffinityInput!"+ },+ "optional": [],+ "example": {+ "includeTopArtists": true,+ "topArtistsInput": {+ "offset": 0,+ "limit": 10,+ "sortBy": "AFFINITY",+ "timeRange": "SHORT_TERM"+ },+ "includeTopTracks": true,+ "topTracksInput": {+ "offset": 0,+ "limit": 4,+ "sortBy": "AFFINITY",+ "timeRange": "SHORT_TERM"+ }+ },+ "probed": true+ },+ "venue": {+ "kind": "query",+ "required": {+ "uri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "watchFeedEntity": {+ "kind": "query",+ "required": {+ "watchFeedUri": "ID!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "watchFeedView": {+ "kind": "query",+ "required": {+ "country": "String!",+ "firstItemUri": "String!",+ "homeEndUserIntegration": "HomeEndUserIntegration!",+ "sp_t": "String!",+ "uri": "String!",+ "discoveryFeedUri": "String!"+ },+ "optional": [],+ "example": {},+ "probed": true+ },+ "whatsNewFeedNewItems": {+ "kind": "query",+ "required": {},+ "optional": [],+ "example": {},+ "probed": true+ }+}\ No newline at end of filediff --git a/base/api-spotify/src/test/kotlin/app/myspoti/spotify/bridge/AdBlockTest.kt b/base/api-spotify/src/test/kotlin/app/myspoti/spotify/bridge/AdBlockTest.ktnew file mode 100644index 00000000..771409d6--- /dev/null+++ b/base/api-spotify/src/test/kotlin/app/myspoti/spotify/bridge/AdBlockTest.kt@@ -0,0 +1,26 @@+package app.myspoti.spotify.bridge++import org.junit.jupiter.api.Assertions.assertFalse+import org.junit.jupiter.api.Assertions.assertTrue+import org.junit.jupiter.api.Test++class AdBlockTest {+ @Test+ fun `blocks the ad audio host only`() {+ assertTrue(AdBlock.isBlocked("https://adstudio-assets.scdn.co/mp3/d0448345e619692e0b13626ad4994d4b824f7107.mp3"))+ assertFalse(AdBlock.isBlocked("https://audio-fa.scdn.co/audio/abc"))+ assertFalse(AdBlock.isBlocked("https://i.scdn.co/image/ab67616d0000b273"))+ assertFalse(AdBlock.isBlocked("https://evil.com/adstudio-assets.scdn.co/x.mp3"))+ }++ @Test+ fun `base62 ids convert to metadata gids`() {+ // Pair checked against a captured metadata/4 request.+ assertTrue(app.myspoti.spotify.base62ToHex("55vPnuXfuzXNW75JpuSczF") == "a734c1d4e4d84c4093c32d5bce9797a3")+ }++ @Test+ fun `bridge script is bundled`() {+ assertTrue(BridgeScript.source.contains("window.Myspoti"))+ }+}diff --git a/base/api-spotify/tools/build_gql_schema.py b/base/api-spotify/tools/build_gql_schema.pynew file mode 100644index 00000000..039a63b1--- /dev/null+++ b/base/api-spotify/tools/build_gql_schema.py@@ -0,0 +1,50 @@+"""Merge everything known about each GraphQL operation into one schema file.++ python build_gql_schema.py <probe.json> > base/api-spotify/src/main/resources/spotify/gql-schema.json++Sources:+- probe.json: answers to each operation sent with empty variables. The server rejects the+ call before running it and names every required variable with its GraphQL type.+ Only probe queries: a mutation with no required variable would really run.+- docs/api/gql-variables.json: variables the Web Player really sent (captures), with one example.+- docs/api/gql-variables-inferred.json: names guessed from the bundles (kept only when short).++Output: {op: {"kind", "required": {name: type}, "optional": [names], "example": {...}}}+"""+import json, re, sys+from pathlib import Path++ROOT = Path(__file__).resolve().parents[3]+OPS = Path(__file__).resolve().parents[1] / "src/main/resources/spotify/gql-ops.json"+MISSING = re.compile(r"missing variable `\$(\w+)`: for required GraphQL type `([^`]+)`")+++def main(probe_path):+ ops = json.loads(OPS.read_text())["operations"]+ probe = json.load(open(probe_path))+ real = json.loads((ROOT / "docs/api/gql-variables.json").read_text())+ inferred_path = ROOT / "docs/api/gql-variables-inferred.json"+ inferred = json.loads(inferred_path.read_text()) if inferred_path.exists() else {}+ out = {}+ for name, op in ops.items():+ p = probe.get(name, {})+ required = dict(MISSING.findall(p.get("body", "")))+ known = set(real.get(name, {}).get("variables", []))+ guess = inferred.get(name) or []+ if len(guess) > 8 or any(len(g) > 30 or g[:1].isupper() for g in guess):+ guess = [] # noisy match on minified code+ optional = sorted((known | set(guess)) - set(required))+ out[name] = {+ "kind": op["kind"],+ "required": required,+ "optional": optional,+ "example": real.get(name, {}).get("example", {}),+ "probed": p.get("status") is not None,+ }+ json.dump(out, sys.stdout, indent=1, ensure_ascii=False)+ print(f"{len(out)} ops, {sum(1 for v in out.values() if v['probed'])} probed, "+ f"{sum(1 for v in out.values() if v['example'])} with a real example", file=sys.stderr)+++if __name__ == "__main__":+ main(sys.argv[1])diff --git a/base/api-spotify/tools/capability_report.py b/base/api-spotify/tools/capability_report.pynew file mode 100644index 00000000..411366bd--- /dev/null+++ b/base/api-spotify/tools/capability_report.py@@ -0,0 +1,76 @@+"""Write docs/api/CAPABILITIES.md: every Web Player GraphQL operation, grouped by domain,+with whether a spec in docs/api documents it and whether its variables are known.++ python capability_report.py+"""+import json, re+from pathlib import Path++ROOT = Path(__file__).resolve().parents[3]+OPS = Path(__file__).resolve().parents[1] / "src/main/resources/spotify/gql-ops.json"+DOCS = ROOT / "docs/api"+OUT = DOCS / "CAPABILITIES.md"+VARS = DOCS / "gql-variables.json" # optional: {opName: example variables}, filled by online captures++DOMAINS = [+ ("Search", r"^search|recentSearches|saveRecentSearches|removeRecentSearches"),+ ("Home and browse", r"^home|^browse|countryHub|whatsNew|WhatsNew|watchFeed|seoRecommended"),+ ("Tracks", r"Track(?!s?Entity)|^getTrack|trackPreview|^canvas|^npv|smartShuffle"),+ ("Albums", r"Album"),+ ("Artists", r"Artist|thisisPlaylist"),+ ("Playlists", r"[Pp]laylist|^getLists|curat|Curat"),+ ("Library", r"[Ll]ibrary|areEntitiesInLibrary|^recents$|pinLibrary"),+ ("Podcasts and audiobooks", r"Episode|Show|Podcast|Book|Audiobook|Chapter|showItems"),+ ("User and social", r"[Uu]ser|follow|account|profile|Comment|Reaction|Repl"),+ ("Concerts and location", r"[Cc]oncert|[Vv]enue|[Ll]ocation"),+ ("Colors and images", r"Color|Image"),+ ("Other", r"."),+]+++def main():+ table = json.loads(OPS.read_text())+ ops = table["operations"]+ # Only the per-domain specs describe variables; SESSION.md and CAPTURE-MAP.md just list names.+ specs = ("CATALOG.md", "SEARCH-HOME.md", "EXTRAS.md", "LIBRARY.md")+ docs_text = "\n".join((DOCS / f).read_text() for f in specs if (DOCS / f).exists())+ known_vars = json.loads(VARS.read_text()) if VARS.exists() else {}+ groups = {name: [] for name, _ in DOMAINS}+ for op in ops:+ for name, pattern in DOMAINS:+ if re.search(pattern, op):+ groups[name].append(op)+ break+ lines = [+ "# Web Player capabilities",+ "",+ f"Generated by `base/api-spotify/tools/capability_report.py` from build `{table['buildVersion']}`:",+ f"{len(ops)} GraphQL operations. Every one can be called through the bridge with",+ "`gql.query {name, hash, variables}`. Hashes: `base/api-spotify/src/main/resources/spotify/gql-ops.json`,",+ "refreshed by `tools/refresh_gql_ops.py`.",+ "",+ "Status: **spec** = documented in a docs/api file, **vars** = variables known from a capture.",+ "Non-GraphQL capabilities (playback, queue, volume, Connect, playlist edits, folders) go through the",+ "player and `service.call`; see the bridge README.",+ "",+ ]+ total_spec = total_vars = 0+ for name, _ in DOMAINS:+ items = sorted(groups[name])+ if not items:+ continue+ lines += [f"## {name} ({len(items)})", "", "| Operation | Kind | Spec | Vars |", "|---|---|---|---|"]+ for op in items:+ spec = bool(re.search(rf"`{re.escape(op)}`|\b{re.escape(op)}\b", docs_text))+ has_vars = op in known_vars or spec+ total_spec += spec+ total_vars += has_vars+ lines.append(f"| `{op}` | {ops[op]['kind']} | {'yes' if spec else ''} | {'yes' if has_vars else ''} |")+ lines.append("")+ lines.insert(9, f"Coverage: {total_spec} documented, {total_vars} with known variables, out of {len(ops)}.")+ OUT.write_text("\n".join(lines) + "\n")+ print(f"{OUT}: {total_spec} documented / {total_vars} with vars / {len(ops)} ops")+++if __name__ == "__main__":+ main()diff --git a/base/api-spotify/tools/extract_gql_variables.py b/base/api-spotify/tools/extract_gql_variables.pynew file mode 100644index 00000000..1a2420b5--- /dev/null+++ b/base/api-spotify/tools/extract_gql_variables.py@@ -0,0 +1,55 @@+"""Collect the variables the Web Player really sends for each GraphQL operation.++ python extract_gql_variables.py <capture.jsonl>... > docs/api/gql-variables.json++Captures are the JSONL files of the capture recorder. For each operationName, keeps one+example of variables (the richest seen) and the union of variable names. Values that look+like the account's own ids are replaced with placeholders, so the output can live in the repo.+"""+import base64, json, re, sys++def scrub(v, user_ids):+ if isinstance(v, dict):+ return {k: scrub(x, user_ids) for k, x in v.items()}+ if isinstance(v, list):+ return [scrub(x, user_ids) for x in v]+ if isinstance(v, str):+ if re.fullmatch(r"[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}", v):+ return "{uuid}" # sp_t cookie, interaction ids+ for uid in user_ids:+ v = v.replace(uid, "{user}")+ if v.startswith("spotify:user:"):+ return "spotify:user:{user}"+ return v++def main(paths):+ ops, user_ids = {}, set()+ for path in paths:+ for line in open(path):+ e = json.loads(line)+ if e.get("kind") != "http":+ continue+ m = re.search(r"/user/([a-z0-9]{20,})/", e["url"])+ if m:+ user_ids.add(m.group(1))+ if "pathfinder" not in e["url"] or not e.get("post"):+ continue+ try:+ body = json.loads(base64.b64decode(e["post"]))+ except Exception:+ continue+ name = body.get("operationName")+ if not name:+ continue+ variables = body.get("variables") or {}+ slot = ops.setdefault(name, {"names": set(), "example": {}})+ slot["names"] |= set(variables)+ if len(json.dumps(variables)) > len(json.dumps(slot["example"])):+ slot["example"] = variables+ out = {name: {"variables": sorted(s["names"]), "example": scrub(s["example"], user_ids)}+ for name, s in sorted(ops.items())}+ json.dump(out, sys.stdout, indent=1, ensure_ascii=False)+ print(f"{len(out)} operations", file=sys.stderr)++if __name__ == "__main__":+ main(sys.argv[1:])diff --git a/base/api-spotify/tools/infer_gql_variables.py b/base/api-spotify/tools/infer_gql_variables.pynew file mode 100644index 00000000..15dec0ff--- /dev/null+++ b/base/api-spotify/tools/infer_gql_variables.py@@ -0,0 +1,64 @@+"""Guess the variable names of GraphQL operations from the Web Player bundles.++ python infer_gql_variables.py > docs/api/gql-variables-inferred.json++Each operation is defined as `X=new Q("name","query","hash",...)` and used as+`loader(X,{key:value,...})`. This finds the identifier bound to each definition and+collects the keys of the object literals passed right after it. Heuristic: check against a+real call before relying on a guess.+"""+import json, re, sys+from concurrent.futures import ThreadPoolExecutor+from pathlib import Path++sys.path.insert(0, str(Path(__file__).parent))+from refresh_gql_ops import get, script_json # noqa: E402++DEF = re.compile(r'([\w$]+)\s*=\s*new [\w$]+(?:\.[\w$]+)?\("(\w+)","(query|mutation|subscription)","[0-9a-f]{64}"')+KEY = re.compile(r'(?:^|[,{])\s*([A-Za-z_$][\w$]*)\s*:')+++def object_keys(text, start):+ """Top-level keys of the object literal starting at text[start] == '{'."""+ depth, i, keys, buf = 0, start, [], []+ while i < len(text) and i < start + 4000:+ c = text[i]+ if c in "{[(":+ depth += 1+ elif c in "}])":+ depth -= 1+ if depth == 0:+ break+ if depth == 1:+ buf.append(c)+ elif depth > 1 and c in "{[(":+ buf.append("…")+ i += 1+ flat = "".join(buf)+ keys = [k for k in KEY.findall("{" + flat[1:]) if k]+ shorthand = re.findall(r'(?:^|,)\s*([A-Za-z_$][\w$]*)\s*(?=,|$)', flat[1:])+ return sorted(set(keys) | {s for s in shorthand if not s.startswith("…")})+++def main():+ html = get("https://open.spotify.com/")+ cdn = script_json(html, "__CDN_FILE_URLS__") or {}+ urls = set(re.findall(r'https://open\.spotifycdn\.com/cdn/build/web-player/[^"\']+?\.js', html))+ urls |= {u for u in (cdn.values() if isinstance(cdn, dict) else cdn) if isinstance(u, str) and u.endswith(".js")}+ with ThreadPoolExecutor(8) as pool:+ bodies = list(pool.map(get, sorted(urls)))+ result = {}+ for body in bodies:+ for m in DEF.finditer(body):+ ident, name = m.group(1), m.group(2)+ found = result.setdefault(name, set())+ # Usages in the same bundle: `(ident,{` or `, ident,{`.+ for u in re.finditer(r'[(,]\s*' + re.escape(ident) + r'\s*,\s*\{', body):+ found |= set(object_keys(body, u.end() - 1))+ out = {k: sorted(v) for k, v in sorted(result.items())}+ json.dump(out, sys.stdout, indent=1)+ print(f"{sum(1 for v in out.values() if v)} / {len(out)} operations with inferred variables", file=sys.stderr)+++if __name__ == "__main__":+ main()diff --git a/base/api-spotify/tools/refresh_gql_ops.py b/base/api-spotify/tools/refresh_gql_ops.pynew file mode 100644index 00000000..0ddfc369--- /dev/null+++ b/base/api-spotify/tools/refresh_gql_ops.py@@ -0,0 +1,66 @@+"""Rebuild the table of every Web Player GraphQL operation (name, kind, sha256 hash).++Reads only public files: the open.spotify.com page and its JS bundles on the CDN.+No account or token is needed.++ python refresh_gql_ops.py [out.json]++Output: {"buildVersion", "clientVersion", "operations": {name: {"kind", "hash"}}}.+The app can run the same steps at startup and refresh its table when buildVersion changes.+"""+import base64, json, re, sys, urllib.request+from concurrent.futures import ThreadPoolExecutor++UA = "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/155.0.0.0 Safari/537.36"+OP_DEF = re.compile(r'new [\w$]+(?:\.[\w$]+)?\("(\w+)","(query|mutation|subscription)","([0-9a-f]{64})"')+++def get(url):+ req = urllib.request.Request(url, headers={"User-Agent": UA, "Accept-Language": "en"})+ with urllib.request.urlopen(req, timeout=30) as r:+ return r.read().decode("utf-8", "replace")+++def script_json(html, script_id):+ m = re.search(rf'<script id="{script_id}" type="text/plain">([^<]+)</script>', html)+ if not m:+ m = re.search(rf'<script id="{script_id}"[^>]*>([^<]+)</script>', html)+ if not m:+ return None+ raw = m.group(1).strip()+ try:+ return json.loads(base64.b64decode(raw))+ except Exception:+ return json.loads(raw)+++def main():+ out_path = sys.argv[1] if len(sys.argv) > 1 else None+ html = get("https://open.spotify.com/")+ server = script_json(html, "appServerConfig") or {}+ cdn = script_json(html, "__CDN_FILE_URLS__") or {}+ urls = set(re.findall(r'https://open\.spotifycdn\.com/cdn/build/web-player/[^"\']+?\.js', html))+ urls |= {u for u in (cdn.values() if isinstance(cdn, dict) else cdn) if isinstance(u, str) and u.endswith(".js")}+ if not urls:+ raise SystemExit("no bundle URL found in the page")+ ops = {}+ with ThreadPoolExecutor(8) as pool:+ for body in pool.map(lambda u: get(u), sorted(urls)):+ for name, kind, h in OP_DEF.findall(body):+ ops[name] = {"kind": kind, "hash": h}+ table = {+ "buildVersion": server.get("buildVersion"),+ "clientVersion": server.get("clientVersion"),+ "bundles": len(urls),+ "operations": dict(sorted(ops.items())),+ }+ text = json.dumps(table, indent=1)+ if out_path:+ open(out_path, "w").write(text + "\n")+ print(f"{len(ops)} operations from {len(urls)} bundles, build {table['buildVersion']}", file=sys.stderr)+ if not out_path:+ print(text)+++if __name__ == "__main__":+ main()diff --git a/base/api/build.gradle.kts b/base/api/build.gradle.ktsnew file mode 100644index 00000000..bfcfbcc1--- /dev/null+++ b/base/api/build.gradle.kts@@ -0,0 +1,13 @@+// The Myspoti API contract: models and interfaces only, no Android, no Spotify details.+// The UI depends on this module alone.+plugins {+ alias(libs.plugins.kotlin.jvm)+}++kotlin {+ jvmToolchain(17)+}++dependencies {+ api(libs.coroutines.core)+}diff --git a/base/api/src/main/kotlin/app/myspoti/api/Api.kt b/base/api/src/main/kotlin/app/myspoti/api/Api.ktnew file mode 100644index 00000000..d61edc5d--- /dev/null+++ b/base/api/src/main/kotlin/app/myspoti/api/Api.kt@@ -0,0 +1,206 @@+package app.myspoti.api++import kotlinx.coroutines.flow.Flow+import kotlinx.coroutines.flow.StateFlow++/** Entry point the UI talks to. One instance per signed-in account. */+interface MyspotiApi {+ val player: Player+ val search: Search+ val catalog: Catalog+ val library: Library+ val playlists: Playlists+ val home: Home+ val podcasts: Podcasts+ val users: Users+ val extras: TrackExtras+ val devices: Devices+ val jam: Jam++ /** False until the playback engine is ready to take commands. */+ val ready: StateFlow<Boolean>+}++interface Player {+ /** Latest state, null when no playback session exists yet. */+ val state: StateFlow<PlayerState?>+ val queue: StateFlow<Queue?>++ /** Plays [contextUri] (playlist, album, artist, show, collection...), starting at [trackUri] or [index] if given. */+ suspend fun play(contextUri: Uri, trackUri: Uri? = null, index: Int? = null, positionMs: Long? = null)+ suspend fun pause()+ suspend fun resume()+ suspend fun seek(positionMs: Long)+ suspend fun next()+ suspend fun previous()+ suspend fun setShuffle(on: Boolean)+ suspend fun setRepeat(mode: Repeat)+ suspend fun addToQueue(uris: List<Uri>)+ suspend fun removeFromQueue(items: List<NowPlaying>)+ suspend fun clearQueue()+ /** Jumps to an item of [Queue.queued] or [Queue.nextUp]. */+ suspend fun skipTo(item: NowPlaying)+ /** "Play next": before everything already queued. */+ suspend fun playNext(uris: List<Uri>)+ /** Moves [item] just before or after [target], in the same part of the queue. */+ suspend fun moveInQueue(item: NowPlaying, target: NowPlaying, after: Boolean)++ /** Volume from 0.0 to 1.0. */+ suspend fun volume(): Double+ suspend fun setVolume(level: Double)+ /** Playback speed (podcasts): 0.5 to 3.5. */+ suspend fun setSpeed(speed: Double)+}++interface Search {+ /** Top results of every music kind at once, for the search screen's first view. */+ suspend fun all(query: String, limit: Int = 10): SearchResults+ suspend fun tracks(query: String, offset: Int = 0, limit: Int = 30): Page<Track>+ suspend fun artists(query: String, offset: Int = 0, limit: Int = 30): Page<Artist>+ suspend fun albums(query: String, offset: Int = 0, limit: Int = 30): Page<Album>+ suspend fun playlists(query: String, offset: Int = 0, limit: Int = 30): Page<Playlist>+ suspend fun shows(query: String, offset: Int = 0, limit: Int = 30): Page<MediaCard>+ suspend fun episodes(query: String, offset: Int = 0, limit: Int = 30): Page<Episode>+ suspend fun audiobooks(query: String, offset: Int = 0, limit: Int = 30): Page<MediaCard>+ suspend fun users(query: String, offset: Int = 0, limit: Int = 30): Page<MediaCard>+ suspend fun genres(query: String, offset: Int = 0, limit: Int = 30): Page<MediaCard>+ /** Completions while typing. */+ suspend fun suggestions(query: String, limit: Int = 10): List<String>+ suspend fun recent(): List<MediaCard>+ suspend fun clearRecent()+}++interface Catalog {+ suspend fun track(uri: Uri): Track+ suspend fun album(uri: Uri): Album+ suspend fun albumTracks(uri: Uri, offset: Int = 0, limit: Int = 50): Page<Track>+ suspend fun artist(uri: Uri): Artist+ suspend fun artistTopTracks(uri: Uri): List<Track>+ suspend fun artistPage(uri: Uri): ArtistPage+ /** The recording's ISRC (to match the same recording on other platforms). */+ suspend fun isrc(trackUri: Uri): String?+ /** Albums, singles and compilations, newest first. */+ suspend fun discography(uri: Uri, offset: Int = 0, limit: Int = 50): Page<Album>+ suspend fun relatedArtists(uri: Uri): List<Artist>+ suspend fun appearsOn(uri: Uri): List<Album>+ /** "More like this" albums for a track. */+ suspend fun similarAlbums(trackUri: Uri, limit: Int = 20): List<Album>+}++interface Library {+ /** Whether each uri (track, album, artist, show, playlist) is saved, in the same order. */+ suspend fun contains(uris: List<Uri>): List<Boolean>+ suspend fun add(uris: List<Uri>)+ suspend fun remove(uris: List<Uri>)++ /** The "Your Library" list, as the Web Player shows it. [folderUri] opens a folder. */+ suspend fun items(+ filter: LibraryFilter = LibraryFilter.ALL,+ sort: LibrarySort = LibrarySort.RECENTS,+ folderUri: Uri? = null,+ offset: Int = 0,+ limit: Int = 50,+ ): Page<LibraryItem>++ suspend fun likedTracks(offset: Int = 0, limit: Int = 50): Page<SavedTrack>+ suspend fun pin(uri: Uri)+ suspend fun unpin(uri: Uri)++ suspend fun createFolder(name: String, parentFolderUri: Uri? = null): Uri+ suspend fun renameFolder(folderUri: Uri, name: String)+ suspend fun deleteFolder(folderUri: Uri)+ /** Moves a playlist or folder into [folderUri] (null = top level). */+ suspend fun moveToFolder(uri: Uri, folderUri: Uri?)++ /** Pushed when the library changes, from this device or another one. */+ val changes: Flow<Unit>+}++interface Playlists {+ suspend fun playlist(uri: Uri): Playlist+ suspend fun tracks(uri: Uri, offset: Int = 0, limit: Int = 100): Page<Track>+ /** The user's own playlists and the ones they follow, in library order, folders flattened. */+ suspend fun mine(): List<Playlist>+ /** Playlists the user may add tracks to. */+ suspend fun editable(): List<Playlist>++ suspend fun create(name: String): Uri+ suspend fun rename(uri: Uri, name: String)+ suspend fun setDescription(uri: Uri, description: String)+ /** Removes the playlist from the library (owners: deletes it; it can be restored for 90 days). */+ suspend fun delete(uri: Uri)+ suspend fun follow(uri: Uri)+ suspend fun unfollow(uri: Uri)++ suspend fun addTracks(uri: Uri, trackUris: List<Uri>)+ /** Rows are addressed by [Track.uid]. */+ suspend fun removeTracks(uri: Uri, uids: List<String>)+ suspend fun moveTracks(uri: Uri, uids: List<String>, beforeUid: String?)+ /** Tracks Spotify suggests adding at the bottom of the playlist. */+ suspend fun recommended(uri: Uri, limit: Int = 10): List<Track>+}++interface Home {+ suspend fun feed(filter: HomeFilter = HomeFilter.ALL, itemsPerShelf: Int = 10): HomeFeed+ suspend fun categories(): List<Category>+ suspend fun category(uri: Uri): BrowsePage+ /** New releases from the artists the user follows, newest first ("What's new"). */+ suspend fun whatsNew(offset: Int = 0, limit: Int = 50): Page<Album>+}++interface Podcasts {+ suspend fun show(uri: Uri): Show+ suspend fun episodes(uri: Uri, offset: Int = 0, limit: Int = 50): Page<Episode>+ suspend fun episode(uri: Uri): Episode+ suspend fun audiobook(uri: Uri): Audiobook+ suspend fun chapters(uri: Uri, offset: Int = 0, limit: Int = 50): Page<Episode>+ /** Episodes the user saved ("Your Episodes"). */+ suspend fun savedEpisodes(offset: Int = 0, limit: Int = 50): Page<Episode>+}++interface Users {+ suspend fun me(): Account+ suspend fun profile(userUri: Uri): UserProfile+ suspend fun top(range: TimeRange = TimeRange.SHORT_TERM, limit: Int = 10): TopContent+ suspend fun follow(userUris: List<Uri>)+ suspend fun unfollow(userUris: List<Uri>)+ suspend fun isFollowing(userUris: List<Uri>): List<Boolean>+ suspend fun friendActivity(): List<FriendActivity>+ /** Contexts played lately (Recents). */+ suspend fun history(): List<HistoryEntry>+ suspend fun setPrivateSession(on: Boolean)+}++interface TrackExtras {+ suspend fun lyrics(trackUri: Uri): Lyrics?+ suspend fun canvas(trackUri: Uri): Canvas?+ suspend fun credits(trackUri: Uri): Credits+ /** The track's radio, as a playlist uri to play. Works with artist uris too. */+ suspend fun radio(seedUri: Uri): Uri?+ /** Hide this track from recommendations, or show it again. */+ suspend fun setExcludedFromTaste(trackUri: Uri, excluded: Boolean)+ suspend fun isExcludedFromTaste(trackUris: List<Uri>): List<Boolean>+}++interface Devices {+ /** Spotify Connect devices of the account, this app's player included. */+ val devices: StateFlow<List<Device>>+ suspend fun refresh()+ suspend fun transfer(deviceId: String, play: Boolean = true)+ /** Brings playback back to this app. */+ suspend fun pullHere()+}++interface Jam {+ suspend fun availability(): JamAvailability+ val session: StateFlow<JamSession?>+ suspend fun refresh()+ suspend fun start(): JamSession+ suspend fun join(joinToken: String): JamSession+ suspend fun leave()+ suspend fun end()+ suspend fun inviteLink(): String?+ suspend fun removeMember(userUri: Uri)+ suspend fun setQueueOnly(on: Boolean)+ suspend fun setParticipantVolumeControl(on: Boolean)+}diff --git a/base/api/src/main/kotlin/app/myspoti/api/Media.kt b/base/api/src/main/kotlin/app/myspoti/api/Media.ktnew file mode 100644index 00000000..e617f76e--- /dev/null+++ b/base/api/src/main/kotlin/app/myspoti/api/Media.kt@@ -0,0 +1,187 @@+package app.myspoti.api++/** What a uri points to. */+enum class MediaKind {+ TRACK, ALBUM, ARTIST, PLAYLIST, SHOW, EPISODE, AUDIOBOOK, CHAPTER, USER, GENRE,+ /** Liked Songs, Your Episodes and other built-in collections. */+ COLLECTION,+ FOLDER, UNKNOWN;++ companion object {+ fun of(uri: Uri): MediaKind = when {+ uri.startsWith("spotify:track:") -> TRACK+ uri.startsWith("spotify:album:") -> ALBUM+ uri.startsWith("spotify:artist:") -> ARTIST+ uri.startsWith("spotify:playlist:") -> PLAYLIST+ uri.startsWith("spotify:show:") -> SHOW+ uri.startsWith("spotify:episode:") -> EPISODE+ uri.startsWith("spotify:audiobook:") -> AUDIOBOOK+ uri.startsWith("spotify:chapter:") -> CHAPTER+ uri.startsWith("spotify:user:") && ":collection" in uri -> COLLECTION+ uri.startsWith("spotify:user:") -> USER+ uri.startsWith("spotify:genre:") || uri.startsWith("spotify:page:") -> GENRE+ uri.startsWith("spotify:collection:") -> COLLECTION+ uri.startsWith("spotify:folder:") || uri.contains(":folder:") -> FOLDER+ else -> UNKNOWN+ }+ }+}++/** A tile in a shelf: home, browse, search top results, "fans also like"... */+data class MediaCard(+ val uri: Uri,+ val kind: MediaKind,+ val title: String,+ val subtitle: String?,+ val images: List<Image>,+)++data class Shelf(val uri: Uri?, val title: String?, val items: List<MediaCard>, val total: Int)++// --- Home and browse ---------------------------------------------------------++enum class HomeFilter(val facet: String) { ALL(""), MUSIC("music-chip"), PODCASTS("podcasts-chip"), AUDIOBOOKS("audiobooks-chip") }++data class HomeFeed(val greeting: String, val filters: List<HomeFilter>, val shelves: List<Shelf>)++data class Category(val uri: Uri, val title: String, val images: List<Image>, val color: String?)++data class BrowsePage(val uri: Uri, val title: String, val shelves: List<Shelf>)++// --- Library -----------------------------------------------------------------++enum class LibraryFilter(val id: String?) { ALL(null), PLAYLISTS("Playlists"), ARTISTS("Artists"), ALBUMS("Albums"), PODCASTS("Podcasts"), AUDIOBOOKS("Audiobooks") }++enum class LibrarySort(val id: String?) { RECENTS(null), RECENTLY_ADDED("Recently Added"), ALPHABETICAL("Alphabetical"), CREATOR("Creator"), CUSTOM("Custom Order") }++data class LibraryItem(+ val uri: Uri,+ val kind: MediaKind,+ val name: String,+ val subtitle: String?,+ val images: List<Image>,+ val pinned: Boolean,+ val addedAt: String?,+ /** Items in a folder, tracks in Liked Songs. */+ val count: Int? = null,+)++data class SavedTrack(val track: Track, val addedAt: String?)++// --- Users -------------------------------------------------------------------++data class Account(+ val uri: Uri,+ val username: String,+ val name: String,+ val images: List<Image>,+ val premium: Boolean,+ val country: String?,+)++data class UserProfile(+ val uri: Uri,+ val name: String,+ val images: List<Image>,+ val followers: Int?,+ val following: Int?,+ val publicPlaylists: List<Playlist>,+)++enum class TimeRange { SHORT_TERM, MEDIUM_TERM, LONG_TERM }++data class TopContent(val artists: List<Artist>, val tracks: List<Track>)++/** A friend's latest listen (friend activity). */+data class FriendActivity(val user: UserRef, val track: Track?, val contextUri: Uri?, val timestampMs: Long)++data class UserRef(val uri: Uri, val name: String, val imageUrl: String?)++// --- Podcasts and audiobooks -------------------------------------------------++data class Show(+ val uri: Uri,+ val name: String,+ val publisher: String,+ val description: String?,+ val images: List<Image>,+ val saved: Boolean,+ val rating: Double?,+ val topics: List<String>,+)++data class Episode(+ val uri: Uri,+ val name: String,+ val description: String?,+ val durationMs: Long,+ val releaseDate: String?,+ val images: List<Image>,+ val show: AlbumRef?,+ /** Where the user stopped, and whether they finished it. */+ val playedPositionMs: Long,+ val played: Boolean,+ val explicit: Boolean,+ val playable: Boolean,+ val previewUrl: String?,+)++data class Audiobook(+ val uri: Uri,+ val name: String,+ val authors: List<String>,+ val narrators: List<String>,+ val description: String?,+ val images: List<Image>,+ val chapterCount: Int,+)++// --- Track extras ------------------------------------------------------------++data class LyricsLine(val startMs: Long, val endMs: Long?, val text: String, val words: List<LyricsWord>? = null)++data class LyricsWord(val startMs: Long, val text: String)++data class Lyrics(+ val lines: List<LyricsLine>,+ val synced: Boolean,+ val language: String?,+ val provider: String?,+ /** ARGB colours from Spotify's lyrics card. */+ val background: Int?,+ val text: Int?,+ val highlight: Int?,+)++data class Canvas(val uri: Uri, val videoUrl: String, val type: String)++data class Credits(val roles: List<CreditRole>)++data class CreditRole(val role: String, val artists: List<ArtistRef>)++// --- Devices and Jam ---------------------------------------------------------++data class Device(+ val id: String,+ val name: String,+ val type: String,+ val active: Boolean,+ val volume: Double?,+ /** This app's own player. */+ val local: Boolean,+)++enum class JamAvailability { AVAILABLE, RESTRICTED, UNKNOWN }++data class JamMember(val userUri: Uri, val name: String, val imageUrl: String?, val host: Boolean)++data class JamSession(+ val id: String,+ val joinToken: String?,+ val inviteLink: String?,+ val members: List<JamMember>,+ val isHost: Boolean,+ val queueOnly: Boolean,+)++data class HistoryEntry(val uri: Uri, val kind: MediaKind, val name: String, val images: List<Image>, val playedAtMs: Long?)diff --git a/base/api/src/main/kotlin/app/myspoti/api/Models.kt b/base/api/src/main/kotlin/app/myspoti/api/Models.ktnew file mode 100644index 00000000..832659c6--- /dev/null+++ b/base/api/src/main/kotlin/app/myspoti/api/Models.kt@@ -0,0 +1,131 @@+package app.myspoti.api++/** A Spotify-style uri such as `spotify:track:{id}`. Kept as a string so every kind fits. */+typealias Uri = String++data class Image(val url: String, val width: Int? = null, val height: Int? = null)++/** Picks the smallest image at least [minPx] wide, or the largest one. */+fun List<Image>.best(minPx: Int): Image? =+ filter { (it.width ?: 0) >= minPx }.minByOrNull { it.width ?: 0 } ?: maxByOrNull { it.width ?: 0 }++data class ArtistRef(val uri: Uri, val name: String)++data class AlbumRef(val uri: Uri, val name: String, val images: List<Image> = emptyList())++data class Track(+ val uri: Uri,+ val name: String,+ val durationMs: Long,+ val artists: List<ArtistRef>,+ val album: AlbumRef?,+ val explicit: Boolean = false,+ val playable: Boolean = true,+ /** Position in a playlist; needed to remove or move this exact row. */+ val uid: String? = null,+)++data class Album(+ val uri: Uri,+ val name: String,+ val artists: List<ArtistRef>,+ val images: List<Image>,+ val type: String,+ val releaseDate: String?,+ val trackCount: Int,+ val label: String? = null,+)++data class Artist(+ val uri: Uri,+ val name: String,+ val images: List<Image>,+ val followers: Long? = null,+ val monthlyListeners: Long? = null,+ val verified: Boolean = false,+)++data class Playlist(+ val uri: Uri,+ val name: String,+ val description: String?,+ val owner: String?,+ val images: List<Image>,+ val trackCount: Int,+ val editable: Boolean = false,+ val ownerUri: Uri? = null,+ val ownerImages: List<Image> = emptyList(),+ val followers: Long? = null,+)++/** One page of a longer list. [nextOffset] is null on the last page. */+data class Page<T>(val items: List<T>, val offset: Int, val total: Int, val nextOffset: Int?)++data class SearchResults(+ val tracks: Page<Track>,+ val artists: Page<Artist>,+ val albums: Page<Album>,+ val playlists: Page<Playlist>,+)++enum class Repeat { OFF, CONTEXT, TRACK }++enum class ItemKind { TRACK, EPISODE, AD }++/** What the player is on now. Ads never reach the UI as the current item. */+data class NowPlaying(+ val kind: ItemKind,+ val uri: Uri,+ val uid: String?,+ val name: String,+ val artists: List<ArtistRef>,+ val album: AlbumRef?,+ val imageUrl: String?,+ val durationMs: Long,+ val explicit: Boolean = false,+)++data class PlayerRestrictions(+ val canPause: Boolean = true,+ val canResume: Boolean = true,+ val canSeek: Boolean = true,+ val canSkipNext: Boolean = true,+ val canSkipPrevious: Boolean = true,+)++data class PlayerState(+ val item: NowPlaying?,+ val contextUri: Uri?,+ /** "Liked Songs", the playlist or album name... */+ val contextName: String? = null,+ val previous: NowPlaying? = null,+ val next: NowPlaying? = null,+ val isPaused: Boolean,+ val isBuffering: Boolean,+ /** Position at [timestampMs] (epoch). Use [positionAt] for a live value. */+ val positionMs: Long,+ val timestampMs: Long,+ val speed: Double,+ val shuffle: Boolean,+ val repeat: Repeat,+ val restrictions: PlayerRestrictions,+) {+ fun positionAt(nowMs: Long): Long =+ if (isPaused || item == null) positionMs+ else (positionMs + (nowMs - timestampMs) * speed).toLong().coerceIn(0, item.durationMs)+}++data class Queue(val current: NowPlaying?, val queued: List<NowPlaying>, val nextUp: List<NowPlaying>)++data class TopTrack(val track: Track, val playcount: Long?)++/** Everything the artist screen shows, in one call. */+data class ArtistPage(+ val artist: Artist,+ val biography: String?,+ val headerImages: List<Image>,+ val topTracks: List<TopTrack>,+ val popularReleases: List<Album>,+ val appearsOn: List<Album>,+ val related: List<Artist>,+)diff --git a/base/app/.gitignore b/base/app/.gitignorenew file mode 100644index 00000000..42afabfd--- /dev/null+++ b/base/app/.gitignore@@ -0,0 +1 @@+/build\ No newline at end of filediff --git a/base/app/build.gradle.kts b/base/app/build.gradle.ktsnew file mode 100644index 00000000..2dcd50a5--- /dev/null+++ b/base/app/build.gradle.kts@@ -0,0 +1,140 @@+import java.util.Properties++plugins {+ alias(libs.plugins.android.application)+ alias(libs.plugins.kotlin.compose)+ alias(libs.plugins.kotlin.serialization)+}++val keystorePropertiesFile = rootProject.file("keystore/keystore.properties")+val keystoreProperties = Properties().apply {+ if (keystorePropertiesFile.exists()) {+ keystorePropertiesFile.inputStream().use { load(it) }+ }+}+++android {+ namespace = "app.myspoti.engine"+ compileSdk = 37++ defaultConfig {+ applicationId = "app.myspoti"+ minSdk = 29+ targetSdk = 36+ // CI release builds pass the tag's version (-PappVersionName / -PappVersionCode).+ versionCode = (findProperty("appVersionCode") as String?)?.toIntOrNull() ?: 200+ versionName = (findProperty("appVersionName") as String?) ?: "2.0.0"+ // GitHub "owner/repo" whose releases the app checks for updates; empty = off+ // (local builds). CI sets it to the repository it builds.+ // Inspectable hidden player in a test build (-PwebDebug=true); never in releases.+ buildConfigField("boolean", "WEB_DEBUG", "${(findProperty("webDebug") as String?) == "true"}")+ buildConfigField("String", "UPDATE_REPO", "\"${(findProperty("updateRepo") as String?) ?: System.getenv("MYSPOTI_UPDATE_REPO") ?: ""}\"")+ ndk {+ abiFilters += listOf("arm64-v8a", "armeabi-v7a")+ }+ }++ buildFeatures {+ compose = true+ buildConfig = true+ }++ // Release key from the CI secrets (env), else keystore/keystore.properties.+ val envStore = System.getenv("MYSPOTI_KEYSTORE")+ val hasReleaseKey = envStore != null || keystorePropertiesFile.exists()+ signingConfigs {+ create("release") {+ if (envStore != null) {+ storeFile = file(envStore)+ storePassword = System.getenv("MYSPOTI_KEYSTORE_PASSWORD")+ keyAlias = System.getenv("MYSPOTI_KEY_ALIAS")+ keyPassword = System.getenv("MYSPOTI_KEY_PASSWORD")+ } else if (keystorePropertiesFile.exists()) {+ storeFile = rootProject.file("keystore/${keystoreProperties.getProperty("storeFile")}")+ storePassword = keystoreProperties.getProperty("storePassword")+ keyAlias = keystoreProperties.getProperty("keyAlias")+ keyPassword = keystoreProperties.getProperty("keyPassword")+ }+ }+ }++ buildTypes {+ debug {+ // Installs next to the release app (own data, own sign-in).+ applicationIdSuffix = ".dev"+ }+ release {+ // Real key when provided (CI releases); otherwise the debug key, so a local+ // release build installs over the debug one while testing.+ signingConfig = signingConfigs.getByName(if (hasReleaseKey) "release" else "debug")+ isMinifyEnabled = true+ isShrinkResources = true+ proguardFiles(+ getDefaultProguardFile("proguard-android-optimize.txt"),+ "proguard-rules.pro"+ )+ }+ }+ compileOptions {+ sourceCompatibility = JavaVersion.VERSION_17+ targetCompatibility = JavaVersion.VERSION_17+ }+}++dependencies {+ implementation(project(":host-android"))+ // Jam: scan the invite QR code (Google code scanner, no camera permission).+ implementation("com.google.android.gms:play-services-code-scanner:16.1.0")+ testImplementation("junit:junit:4.13.2")+ implementation(libs.androidx.core.ktx)+ implementation(libs.androidx.appcompat)+ implementation(libs.androidx.webkit)+ implementation(libs.androidx.media)+++ // Jetpack Compose+ implementation(platform(libs.compose.bom))+ implementation(libs.compose.ui)+ implementation(libs.compose.ui.graphics)+ implementation(libs.compose.ui.tooling.preview)+ implementation(libs.material)+ implementation(libs.compose.material3)+ implementation(libs.compose.foundation)+ implementation(libs.activity.compose)+ implementation(libs.lifecycle.runtime.compose)+ debugImplementation(libs.compose.ui.tooling)++ // Native UI (ported from Spotui, GPL-3.0)+ implementation("androidx.navigation:navigation-compose:2.9.0")+ implementation("androidx.lifecycle:lifecycle-viewmodel-compose:2.9.0")+ implementation("com.github.bumptech.glide:compose:1.0.0-beta01")+ implementation("androidx.palette:palette-ktx:1.0.0")+ // MediaTransferReceiver: lets the system output switcher transfer to our Connect routes+ implementation("androidx.mediarouter:mediarouter:1.8.1")+ implementation("androidx.compose.material:material-icons-extended:1.7.8")+ implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:1.10.2")+ implementation(libs.serialization.json)+ implementation(libs.ktor.client.core)+ implementation(libs.ktor.client.okhttp)+ implementation(libs.ktor.client.content.negotiation)+ implementation(libs.ktor.client.encoding)+ implementation(libs.ktor.serialization.json)+ // Looping Spotify Canvas video on the now-playing screen+ implementation("androidx.media3:media3-exoplayer:1.8.0")+ implementation("androidx.media3:media3-exoplayer-dash:1.8.0")+ // Installs the Baseline Profiles shipped by Compose & co. on sideloaded builds+ // (faster start, less jank; Play does this itself for store installs).+ implementation("androidx.profileinstaller:profileinstaller:1.4.1")+ // YouTube music videos (search + streams), as in Spotui / NewPipe.+ implementation("com.github.TeamNewPipe:NewPipeExtractor:v0.26.5")+ implementation(libs.okhttp)+ implementation("androidx.media3:media3-ui:1.8.0")+ implementation("androidx.media3:media3-datasource:1.8.0")+ implementation("androidx.media3:media3-database:1.8.0")++++++}\ No newline at end of filediff --git a/base/app/proguard-rules.pro b/base/app/proguard-rules.pronew file mode 100644index 00000000..6f344a5f--- /dev/null+++ b/base/app/proguard-rules.pro@@ -0,0 +1,76 @@+# The Web Player page calls the host through this @JavascriptInterface.+-keepclassmembers class app.myspoti.host.android.WebPlayerHost$HostInterface {+ @android.webkit.JavascriptInterface <methods>;+}+-keepclassmembers class app.myspoti.host.android.ControlRelay {+ @android.webkit.JavascriptInterface <methods>;+}+# Bundled resources read by name (bridge script, GraphQL operation table).+-keep class app.myspoti.spotify.bridge.BridgeScript { *; }+-keep class app.myspoti.spotify.gql.GqlOps { *; }+-keep class org.bouncycastle.** { *; }+-dontwarn org.bouncycastle.**+-dontwarn javax.annotation.concurrent.GuardedBy+-keepclassmembers enum * { *; }+-keepclassmembers class * implements java.io.Serializable { *; }+-keepclassmembers class * implements android.os.Parcelable {+ public static final android.os.Parcelable$Creator CREATOR;+}+-keepattributes *Annotation*,JavascriptInterface,SourceFile,LineNumberTable+-renamesourcefileattribute SourceFile++-keep class com.google.firebase.** { *; }+-keep class com.google.android.gms.** { *; }+-keep class com.google.protobuf.** { *; }+-keep class com.google.protos.** { *; }+-keep class ** extends com.google.protobuf.GeneratedMessageLite { *; }+-keep class ** extends com.google.protobuf.GeneratedMessage { *; }+-keepclassmembers class ** extends com.google.protobuf.GeneratedMessageLite {+ <fields>;+}+-keepclassmembers class ** extends com.google.protobuf.GeneratedMessage {+ <fields>;+}++# NewPipe / Rhino - java.beans.* not available on Android on device+-dontwarn java.beans.BeanDescriptor+-dontwarn java.beans.BeanInfo+-dontwarn java.beans.IntrospectionException+-dontwarn java.beans.Introspector+-dontwarn java.beans.PropertyDescriptor+-dontwarn javax.script.**+# do not add -keep class org.mozilla.javascript.** - it pulls in classes+# referencing java.beans.* which breaks ART install-time verification++-dontwarn java.lang.instrument.**++-keep class * extends androidx.room.RoomDatabase {+ <init>();+}+-keep class androidx.work.** {+ <init>(...);+}+-keep class * extends androidx.glance.appwidget.action.ActionCallback {+ <init>();+}++# Native UI (Spotui port) + Spotify data layer+-keep class com.metrolist.spotify.models.** { *; }+-keep class com.music.spotui.data.entity.** { *; }+-keepclassmembers @kotlinx.serialization.Serializable class ** { *; }+-dontwarn org.slf4j.**+-dontwarn io.ktor.**+-dontwarn org.conscrypt.**+-dontwarn org.bouncycastle.jsse.**+-dontwarn org.openjsse.**++# NewPipeExtractor (YouTube music videos): reflection / Rhino JS engine, as in NewPipe.+-keep class org.schabi.newpipe.extractor.** { *; }+-keep class org.mozilla.javascript.** { *; }+-keep class org.mozilla.classfile.ClassFileWriter+-dontwarn org.mozilla.javascript.tools.**+-dontwarn javax.script.**+-dontwarn java.beans.**+-dontwarn org.jsoup.**+-dontwarn com.google.re2j.**+-dontwarn jdk.dynalink.**diff --git a/base/app/src/debug/res/values/strings.xml b/base/app/src/debug/res/values/strings.xmlnew file mode 100644index 00000000..12c57a6c--- /dev/null+++ b/base/app/src/debug/res/values/strings.xml@@ -0,0 +1,4 @@+<?xml version="1.0" encoding="utf-8"?>+<resources>+ <string name="app_name">Myspoti dev</string>+</resources>diff --git a/base/app/src/main/AndroidManifest.xml b/base/app/src/main/AndroidManifest.xmlnew file mode 100644index 00000000..54bbd680--- /dev/null+++ b/base/app/src/main/AndroidManifest.xml@@ -0,0 +1,193 @@+<?xml version="1.0" encoding="utf-8"?>+<manifest xmlns:android="http://schemas.android.com/apk/res/android"+ xmlns:tools="http://schemas.android.com/tools">++ <uses-permission android:name="android.permission.INTERNET" />+ <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />+ <uses-permission android:name="android.permission.FOREGROUND_SERVICE" />+ <uses-permission android:name="android.permission.FOREGROUND_SERVICE_MEDIA_PLAYBACK" />+ <!-- Asked once: background playback and Connect updates with the screen off. -->+ <uses-permission android:name="android.permission.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS" />+ <!-- Local Files: the device's own audio files, read only. -->+ <uses-permission android:name="android.permission.READ_MEDIA_AUDIO" />+ <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" android:maxSdkVersion="32" />+ <uses-permission android:name="android.permission.POST_NOTIFICATIONS" />+ <uses-permission android:name="android.permission.WAKE_LOCK" />+ <uses-permission android:name="android.permission.BLUETOOTH_CONNECT" />+ <uses-permission+ android:name="android.permission.WRITE_EXTERNAL_STORAGE"+ android:maxSdkVersion="28" />++ <application+ android:name="app.myspoti.MyspotiApplication"+ android:allowBackup="false"+ android:icon="@mipmap/ic_launcher"+ android:label="@string/app_name"+ android:roundIcon="@mipmap/ic_launcher_round"+ android:supportsRtl="true"+ android:theme="@style/Theme.Myspoti"+ android:usesCleartextTraffic="false">+ <!-- Cover art for Android Auto (content:// only); Spotify image CDN hosts only. -->+ <provider+ android:name="com.music.spotui.di.ArtworkProvider"+ android:authorities="${applicationId}.artwork"+ android:exported="true" />+ <!-- Lets the system profiler (Perfetto, Android Studio) trace release builds; no debugging. -->+ <profileable android:shell="true" />++ <meta-data+ android:name="com.google.android.gms.car.application"+ android:resource="@xml/automotive_app_desc" />++ <meta-data+ android:name="firebase_analytics_collection_deactivated"+ android:value="true" />+ <meta-data+ android:name="google_analytics_adid_collection_enabled"+ android:value="false" />+ <meta-data+ android:name="firebase_performance_collection_deactivated"+ android:value="true" />+++ <activity+ android:name="app.myspoti.MainActivity"+ android:exported="true"+ android:launchMode="singleTask"+ android:screenOrientation="portrait"+ android:supportsPictureInPicture="true"+ android:configChanges="orientation|screenSize|screenLayout|keyboardHidden"+ android:windowSoftInputMode="adjustResize"+ android:theme="@style/Theme.Myspoti">+ <intent-filter>+ <action android:name="android.intent.action.MAIN" />+ <category android:name="android.intent.category.LAUNCHER" />+ </intent-filter>+ <intent-filter>+ <action android:name="android.media.action.MEDIA_PLAY_FROM_SEARCH" />+ <category android:name="android.intent.category.DEFAULT" />+ </intent-filter>+ <intent-filter android:autoVerify="true">+ <action android:name="android.intent.action.VIEW" />+ <category android:name="android.intent.category.DEFAULT" />+ <category android:name="android.intent.category.BROWSABLE" />+ <data+ android:scheme="https"+ android:host="open.spotify.com" />+ <data+ android:scheme="https"+ android:host="spotify.com" />+ <data+ android:scheme="https"+ android:host="www.spotify.com" />+ <data+ android:scheme="https"+ android:host="play.spotify.com" />+ <data+ android:scheme="https"+ android:host="spotify.link" />+ </intent-filter>+ </activity>++ <!-- Supporter icons (SupportReminder.setIcon), off with the supporter perks: re-enabling+ them = remove the LAUNCHER filter from MainActivity and uncomment these aliases.+ <activity-alias+ android:name=".ui.LauncherGreen"+ android:targetActivity="app.myspoti.MainActivity"+ android:exported="true"+ android:enabled="true"+ android:icon="@mipmap/ic_launcher"+ android:roundIcon="@mipmap/ic_launcher_round">+ <intent-filter>+ <action android:name="android.intent.action.MAIN" />+ <category android:name="android.intent.category.LAUNCHER" />+ </intent-filter>+ </activity-alias>+ <activity-alias+ android:name=".ui.LauncherBlue"+ android:targetActivity="app.myspoti.MainActivity"+ android:exported="true"+ android:enabled="false"+ android:icon="@mipmap/ic_launcher_blue"+ android:roundIcon="@mipmap/ic_launcher_blue">+ <intent-filter>+ <action android:name="android.intent.action.MAIN" />+ <category android:name="android.intent.category.LAUNCHER" />+ </intent-filter>+ </activity-alias>+ <activity-alias+ android:name=".ui.LauncherPurple"+ android:targetActivity="app.myspoti.MainActivity"+ android:exported="true"+ android:enabled="false"+ android:icon="@mipmap/ic_launcher_purple"+ android:roundIcon="@mipmap/ic_launcher_purple">+ <intent-filter>+ <action android:name="android.intent.action.MAIN" />+ <category android:name="android.intent.category.LAUNCHER" />+ </intent-filter>+ </activity-alias>+ <activity-alias+ android:name=".ui.LauncherPink"+ android:targetActivity="app.myspoti.MainActivity"+ android:exported="true"+ android:enabled="false"+ android:icon="@mipmap/ic_launcher_pink"+ android:roundIcon="@mipmap/ic_launcher_pink">+ <intent-filter>+ <action android:name="android.intent.action.MAIN" />+ <category android:name="android.intent.category.LAUNCHER" />+ </intent-filter>+ </activity-alias>+ <activity-alias+ android:name=".ui.LauncherOrange"+ android:targetActivity="app.myspoti.MainActivity"+ android:exported="true"+ android:enabled="false"+ android:icon="@mipmap/ic_launcher_orange"+ android:roundIcon="@mipmap/ic_launcher_orange">+ <intent-filter>+ <action android:name="android.intent.action.MAIN" />+ <category android:name="android.intent.category.LAUNCHER" />+ </intent-filter>+ </activity-alias>+ -->++ <!-- Spotify's account pages, in a browser that shares the app's sign-in. -->+ <activity+ android:name="com.music.spotui.ui.screens.AccountBrowser"+ android:exported="false"+ android:configChanges="orientation|screenSize|screenLayout|keyboardHidden"+ android:theme="@style/Theme.Myspoti" />+ <!-- Per-app language on Android 12 and older (AppCompat stores the choice). -->+ <service+ android:name="androidx.appcompat.app.AppLocalesMetadataHolderService"+ android:enabled="false"+ android:exported="false">+ <meta-data android:name="autoStoreLocales" android:value="true" />+ </service>+ <receiver+ android:name="androidx.media.session.MediaButtonReceiver"+ android:exported="true">+ <intent-filter>+ <action android:name="android.intent.action.MEDIA_BUTTON" />+ </intent-filter>+ </receiver>++++ <!-- Home screen widget: now playing with controls. -->+ <receiver+ android:name="com.music.spotui.widget.NowPlayingWidget"+ android:exported="false"+ android:label="@string/app_name">+ <intent-filter>+ <action android:name="android.appwidget.action.APPWIDGET_UPDATE" />+ </intent-filter>+ <meta-data+ android:name="android.appwidget.provider"+ android:resource="@xml/widget_now_playing_info" />+ </receiver>+ </application>++</manifest>diff --git a/base/app/src/main/assets/silent.mp3 b/base/app/src/main/assets/silent.mp3new file mode 100644index 00000000..d5ddc7fbBinary files /dev/null and b/base/app/src/main/assets/silent.mp3 differdiff --git a/base/app/src/main/java/app/myspoti/MainActivity.kt b/base/app/src/main/java/app/myspoti/MainActivity.ktnew file mode 100644index 00000000..e7b58d9d--- /dev/null+++ b/base/app/src/main/java/app/myspoti/MainActivity.kt@@ -0,0 +1,199 @@+package app.myspoti++import android.Manifest+import android.content.Context+import android.content.Intent+import android.content.pm.PackageManager+import android.os.Build+import android.os.Bundle+import android.view.ViewGroup+import android.widget.FrameLayout+import androidx.activity.compose.setContent+import androidx.activity.result.contract.ActivityResultContracts+import androidx.appcompat.app.AppCompatActivity+import androidx.compose.foundation.background+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.setValue+import androidx.compose.ui.platform.ComposeView+import androidx.core.content.ContextCompat+import androidx.lifecycle.lifecycleScope+import app.myspoti.host.android.MyspotiRuntime+import com.music.spotui.App+import com.music.spotui.di.AutoBrowser+import com.music.spotui.ui.screens.WelcomeScreen+import com.music.spotui.ui.theme.SpotuiTheme+import kotlinx.coroutines.flow.combine+import kotlinx.coroutines.flow.first+import kotlinx.coroutines.launch++/**+ * The app's only screen host: the Compose UI, with the Web Player page attached behind it.+ * The page comes to the front only to sign in, on Spotify's own login pages.+ */+class MainActivity : AppCompatActivity() {+ private lateinit var root: FrameLayout+ private var signedIn by mutableStateOf(false)+ private var showingLogin by mutableStateOf(false)+ /** Back from Spotify's login, waiting for the session: a native loading screen, not the web page. */+ private var connecting by mutableStateOf(false)++ private val prefs get() = getSharedPreferences("myspoti_prefs", Context.MODE_PRIVATE)++ private val notificationPermission = registerForActivityResult(ActivityResultContracts.RequestPermission()) {}++ override fun onCreate(savedInstanceState: Bundle?) {+ super.onCreate(savedInstanceState)+ signedIn = prefs.getBoolean("LoggedIn", false)+ root = FrameLayout(this)+ val compose = ComposeView(this).apply {+ setContent {+ SpotuiTheme {+ androidx.compose.foundation.layout.Box(androidx.compose.ui.Modifier.fillMaxSize()) {+ when {+ signedIn -> App()+ connecting -> ConnectingScreen()+ else -> WelcomeScreen(onLogin = { showLogin() })+ }+ // Beta and dev builds only: hold the faint dot to copy the recent logs.+ if (com.music.spotui.data.api.UpdateChecker.isBeta || app.myspoti.engine.BuildConfig.DEBUG)+ com.music.spotui.ui.components.BetaLogButton(+ androidx.compose.ui.Modifier.align(androidx.compose.ui.Alignment.BottomEnd))+ }+ }+ }+ }+ root.addView(compose, ViewGroup.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT))+ setContentView(root)+ // Debug builds: `am start ... --ez showPlayer true` shows the Web Player page full screen.+ val debuggable = applicationInfo.flags and android.content.pm.ApplicationInfo.FLAG_DEBUGGABLE != 0+ MyspotiRuntime.host.attach(root, visible = debuggable && intent.getBooleanExtra("showPlayer", false))+ watchSession()+ watchLoginReturn()+ watchLogout()+ askNotifications()+ handle(intent)+ }++ override fun onNewIntent(intent: Intent) {+ super.onNewIntent(intent)+ handle(intent)+ }++ /** Spotify's login page, full screen, until the Web Player comes back signed in. */+ private fun showLogin() {+ showingLogin = true+ MyspotiRuntime.host.attach(root, visible = true)+ MyspotiRuntime.host.openLogin()+ }++ private fun hideLogin() {+ showingLogin = false+ MyspotiRuntime.host.attach(root, visible = false)+ }++ /** Logout: leave the app's screens for Spotify's login page. */+ private fun watchLogout() {+ lifecycleScope.launch {+ com.music.spotui.di.SessionActions.signedOut.collect { out ->+ if (out && signedIn) {+ signedIn = false+ showingLogin = true+ MyspotiRuntime.host.attach(root, visible = true)+ }+ }+ }+ }++ /** Spotify sent the user back to the player: hide the page now, the session follows. */+ private fun watchLoginReturn() {+ lifecycleScope.launch {+ MyspotiRuntime.host.url.collect { url ->+ val backOnPlayer = url.startsWith("https://open.spotify.com") && !url.contains("/login")+ if (showingLogin && backOnPlayer) {+ hideLogin()+ if (!signedIn) connecting = true+ }+ }+ }+ }++ /**+ * Signed in = the Web Player is ready with a user token. A Spotify login page while+ * signed in (expired session) brings the page back to the front.+ */+ private fun watchSession() {+ val api = MyspotiRuntime.spotify+ lifecycleScope.launch {+ combine(api.ready, MyspotiRuntime.loginRequired) { ready, login -> ready to login }.collect { (ready, login) ->+ when {+ login && !showingLogin && signedIn -> showLogin()+ ready && !login -> {+ val user = runCatching { MyspotiRuntime.isSignedIn() }.getOrDefault(false)+ if (user) {+ if (com.music.spotui.di.SessionActions.signedOut.value) {+ // Signed in again after a logout, maybe as someone else: start the+ // screens over (a new activity also drops their view models).+ com.music.spotui.di.SessionActions.signedIn()+ prefs.edit().putBoolean("LoggedIn", true).apply()+ MyspotiRuntime.host.attach(root, visible = false)+ startActivity(Intent(this@MainActivity, MainActivity::class.java)+ .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK or Intent.FLAG_ACTIVITY_CLEAR_TASK))+ finish()+ return@collect+ }+ if (!signedIn) {+ prefs.edit().putBoolean("LoggedIn", true).apply()+ signedIn = true+ }+ connecting = false+ if (showingLogin) hideLogin()+ }+ }+ }+ }+ }+ }++ private fun askNotifications() {+ if (Build.VERSION.SDK_INT >= 33 &&+ ContextCompat.checkSelfPermission(this, Manifest.permission.POST_NOTIFICATIONS) != PackageManager.PERMISSION_GRANTED+ ) notificationPermission.launch(Manifest.permission.POST_NOTIFICATIONS)+ }++ /** Spotify links (open.spotify.com/...) play their item; voice search plays its best match. */+ private fun handle(intent: Intent?) {+ intent ?: return+ when (intent.action) {+ Intent.ACTION_VIEW -> {+ val uri = spotifyUri(intent.data?.toString() ?: return) ?: return+ lifecycleScope.launch {+ MyspotiRuntime.api.ready.first { it }+ runCatching { MyspotiRuntime.api.player.play(uri) }+ }+ }+ android.provider.MediaStore.INTENT_ACTION_MEDIA_PLAY_FROM_SEARCH -> {+ val query = intent.getStringExtra(android.app.SearchManager.QUERY).orEmpty()+ if (query.isNotBlank()) lifecycleScope.launch { AutoBrowser.playFromSearch(query) }+ }+ }+ }++ /** `https://open.spotify.com/intl-fr/album/{id}?si=…` -> `spotify:album:{id}`. */+ private fun spotifyUri(link: String): String? {+ val m = Regex("open\\.spotify\\.com/(?:intl-[a-z-]+/)?(track|album|playlist|artist|show|episode)/([A-Za-z0-9]{22})").find(link) ?: return null+ return "spotify:${m.groupValues[1]}:${m.groupValues[2]}"+ }+}++/** Shown between Spotify's login page and the first screen. */+private fun ConnectingScreen() {+ androidx.compose.foundation.layout.Box(+ androidx.compose.ui.Modifier.fillMaxSize().background(androidx.compose.ui.graphics.Color(0xFF0E0E13)),+ contentAlignment = androidx.compose.ui.Alignment.Center,+ ) {+ androidx.compose.material3.CircularProgressIndicator(color = com.music.spotui.ui.theme.AppAccent)+ }+}diff --git a/base/app/src/main/java/app/myspoti/MyspotiApplication.kt b/base/app/src/main/java/app/myspoti/MyspotiApplication.ktnew file mode 100644index 00000000..eb7044f1--- /dev/null+++ b/base/app/src/main/java/app/myspoti/MyspotiApplication.kt@@ -0,0 +1,43 @@+package app.myspoti++import android.app.Application+import android.content.Context+import android.support.v4.media.MediaBrowserCompat+import app.myspoti.host.android.MediaLibrary+import app.myspoti.host.android.PlaybackService+import com.music.spotui.di.AutoBrowser+import com.music.spotui.di.Graph+import com.music.spotui.di.SongPlayer+import kotlinx.coroutines.flow.first+import kotlinx.coroutines.launch++/** Starts the Spotify session, the UI singletons and the playback service bindings. */+class MyspotiApplication : Application() {+ override fun onCreate() {+ super.onCreate()+ app.myspoti.power.EnergySettings.init(this)+ // Spotify session (hidden Web Player + API), caches, downloads, data saver.+ Graph.init(this)+ SongPlayer.attachEngine(Graph.currentSongState)+ PlaybackService.library = object : MediaLibrary {+ override suspend fun children(context: Context, parentId: String): List<MediaBrowserCompat.MediaItem> =+ AutoBrowser.children(context, parentId)+ override suspend fun search(query: String): List<MediaBrowserCompat.MediaItem> = AutoBrowser.search(query)+ }+ prefetch()+ }++ /**+ * Once the Web Player is signed in, the library and Liked Songs load in the background+ * (the home feed is loaded by the first screen): the tabs open on fresh content.+ */+ private fun prefetch() {+ kotlinx.coroutines.CoroutineScope(kotlinx.coroutines.SupervisorJob() + kotlinx.coroutines.Dispatchers.IO).launch {+ app.myspoti.host.android.MyspotiRuntime.api.ready.first { it }+ if (!getSharedPreferences("myspoti_prefs", MODE_PRIVATE).getBoolean("LoggedIn", false)) return@launch+ val api = com.music.spotui.data.api.Api()+ launch { runCatching { api.getLibraryRoot().collect {} } }+ launch { runCatching { api.getLikedPage().collect {} } }+ }+ }+}diff --git a/base/app/src/main/java/app/myspoti/power/BatteryExemption.kt b/base/app/src/main/java/app/myspoti/power/BatteryExemption.ktnew file mode 100644index 00000000..35aca303--- /dev/null+++ b/base/app/src/main/java/app/myspoti/power/BatteryExemption.kt@@ -0,0 +1,36 @@+package app.myspoti.power++import android.annotation.SuppressLint+import android.content.Context+import android.content.Intent+import android.net.Uri+import android.os.PowerManager+import android.provider.Settings++/**+ * Battery optimization off for Myspoti: without it, Android may put the app to sleep in+ * the background (music stopping, a Connect device no longer followed with the screen off).+ */+object BatteryExemption {+ private const val PREFS = "myspoti_prefs"+ private const val KEY_ASKED = "BatteryExemptionAsked"++ fun isExempt(context: Context): Boolean =+ context.getSystemService(PowerManager::class.java).isIgnoringBatteryOptimizations(context.packageName)++ /** The system "Allow unrestricted battery?" dialog, or the settings list if it is unavailable. */+ @SuppressLint("BatteryLife")+ fun request(context: Context) {+ context.getSharedPreferences(PREFS, Context.MODE_PRIVATE).edit().putBoolean(KEY_ASKED, true).apply()+ val direct = Intent(Settings.ACTION_REQUEST_IGNORE_BATTERY_OPTIMIZATIONS, Uri.parse("package:${context.packageName}"))+ runCatching { context.startActivity(direct) }.onFailure {+ runCatching { context.startActivity(Intent(Settings.ACTION_IGNORE_BATTERY_OPTIMIZATION_SETTINGS)) }+ }+ }++ /** Asks once (onboarding, or the first launch after an update); later from Settings. */+ fun askOnce(context: Context) {+ val asked = context.getSharedPreferences(PREFS, Context.MODE_PRIVATE).getBoolean(KEY_ASKED, false)+ if (!asked && !isExempt(context)) request(context)+ }+}diff --git a/base/app/src/main/java/app/myspoti/power/EnergyPolicy.kt b/base/app/src/main/java/app/myspoti/power/EnergyPolicy.ktnew file mode 100644index 00000000..181d1a05--- /dev/null+++ b/base/app/src/main/java/app/myspoti/power/EnergyPolicy.kt@@ -0,0 +1,42 @@+package app.myspoti.power++/** Playback transport and listening events are independent of this visual policy. */+data class EnergyPolicy(+ val saverEnabled: Boolean = false,+ val oledBlack: Boolean = false,+ val allowCanvas: Boolean = true,+ val videoMaxHeight: Int = 1080,+ val allowBackgroundLookups: Boolean = true,+ val progressFps: Int = 30,+ /** 0 = no preference: the LTPO screen already drops its rate when nothing moves. */+ val displayRefreshCap: Float = 0f,+) {+ companion object {+ /**+ * Only the app's own switch turns the saver on: Android's battery saver is not+ * followed (it already lowers the screen's refresh rate by itself).+ */+ fun resolve(manualSaver: Boolean, blackPreference: Boolean, canvasEnabled: Boolean = true): EnergyPolicy {+ val saver = manualSaver+ return EnergyPolicy(+ saverEnabled = saver,+ oledBlack = blackPreference,+ allowCanvas = !saver && canvasEnabled,+ videoMaxHeight = if (saver) 480 else 1080,+ allowBackgroundLookups = !saver,+ progressFps = if (saver) 20 else 30,+ displayRefreshCap = if (saver) 60f else 0f,+ )+ }+ }+}++data class EnergyState(+ val manualSaver: Boolean = false,+ /** AMOLED appearance stays user-controlled while saver limits visual work. */+ val blackPreference: Boolean = false,+ /** The user's Canvas switch (Settings), independent of the saver. */+ val canvasEnabled: Boolean = true,+) {+ val policy: EnergyPolicy get() = EnergyPolicy.resolve(manualSaver, blackPreference, canvasEnabled)+}diff --git a/base/app/src/main/java/app/myspoti/power/EnergySettings.kt b/base/app/src/main/java/app/myspoti/power/EnergySettings.ktnew file mode 100644index 00000000..0b915f7d--- /dev/null+++ b/base/app/src/main/java/app/myspoti/power/EnergySettings.kt@@ -0,0 +1,57 @@+package app.myspoti.power++import android.app.Application+import androidx.core.content.edit+import android.content.Context+import android.content.SharedPreferences+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.setValue+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.asStateFlow++/** Application-owned preferences (the app's saver is independent of Android's); no polling or playback commands. */+object EnergySettings {+ private val mutableState = MutableStateFlow(EnergyState())+ val state = mutableState.asStateFlow()+ var oledBlack by mutableStateOf(false)+ private set+ private var app: Application? = null+ private var preferences: SharedPreferences? = null+ private val preferenceListener = SharedPreferences.OnSharedPreferenceChangeListener { _, _ -> refresh() }++ fun init(context: Context) {+ if (app != null) return+ val application = context.applicationContext as Application+ app = application+ preferences = application.getSharedPreferences("energy_settings", Context.MODE_PRIVATE)+ preferences?.registerOnSharedPreferenceChangeListener(preferenceListener)+ refresh()+ }++ fun setSaver(enabled: Boolean) {+ preferences?.edit { putBoolean("manual_saver", enabled) }+ refresh()+ }++ fun setBlackBackground(enabled: Boolean) {+ preferences?.edit { putBoolean("black_background", enabled) }+ refresh()+ }++ fun setCanvasEnabled(enabled: Boolean) {+ preferences?.edit { putBoolean("canvas", enabled) }+ refresh()+ }++ private fun refresh() {+ if (app == null) return+ val next = EnergyState(+ manualSaver = preferences?.getBoolean("manual_saver", false) == true,+ blackPreference = preferences?.getBoolean("black_background", false) == true,+ canvasEnabled = preferences?.getBoolean("canvas", true) != false,+ )+ mutableState.value = next+ oledBlack = next.policy.oledBlack+ }+}diff --git a/base/app/src/main/java/com/music/spotui/App.kt b/base/app/src/main/java/com/music/spotui/App.ktnew file mode 100644index 00000000..c00f4c99--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/App.kt@@ -0,0 +1,260 @@+package com.music.spotui++import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.verticalScroll+import androidx.compose.foundation.layout.heightIn+import com.music.spotui.ui.components.pressable+import androidx.compose.ui.unit.sp+import androidx.compose.ui.unit.dp+import androidx.compose.ui.draw.clip+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.background+import android.annotation.SuppressLint+import android.os.Build+import androidx.annotation.RequiresApi+import androidx.compose.foundation.layout.navigationBarsPadding+import androidx.compose.material3.Scaffold+import androidx.compose.runtime.Composable+import androidx.compose.runtime.getValue+import androidx.compose.runtime.setValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.saveable.rememberSaveable+import androidx.compose.ui.Modifier+import androidx.navigation.compose.currentBackStackEntryAsState+import androidx.navigation.compose.rememberNavController+import com.music.spotui.ui.navigation.MainBottomNavigation+import com.music.spotui.ui.navigation.MyNavHost+import com.music.spotui.ui.navigation.Routes+++@SuppressLint("UnusedMaterial3ScaffoldPaddingParameter")+@Composable+fun App() {+ val bottomBarState = rememberSaveable { (mutableStateOf(true)) }+ val bottomBarPlayerState = rememberSaveable { (mutableStateOf(true)) }+ val navController = rememberNavController()+ val navBackStackEntry by navController.currentBackStackEntryAsState()++ // Control TopBar and BottomBar+ when (navBackStackEntry?.destination?.route) {+ Routes.Home.route -> {+ bottomBarState.value = true+ }+ Routes.Search.route -> {+ bottomBarState.value = true+ }+ Routes.Library.route -> {+ bottomBarState.value = true+ }+ Routes.Album.route -> {+ bottomBarState.value = false+ }+ }++ UpdatePrompt()+ SupportPrompt()++ androidx.compose.foundation.layout.Box(Modifier.fillMaxSize()) {+ Scaffold(+ modifier = Modifier,+ bottomBar = {+ MainBottomNavigation(navController = navController, bottomBarState = bottomBarState, bottomBarPlayerState)+ }+ ) {+ MyNavHost(navHostController = navController, bottomBarState = bottomBarState, bottomBarPlayerState)+ }+ // Over the pages and the bottom bar: pulling it down shows them, already in place.+ com.music.spotui.ui.navigation.PlayerOverlay(navController)+ }+}++++/** The update card is on screen: the donation reminder waits for another launch. */+private val updateCardOpen = mutableStateOf(false)++/**+ * The donation reminder (see SupportReminder): a card a few seconds after launch, only+ * when due, signed in, and no update card is open. "No thanks" closes it for 2 weeks.+ */+@Composable+private fun SupportPrompt() {+ val context = androidx.compose.ui.platform.LocalContext.current+ var show by androidx.compose.runtime.remember { mutableStateOf(false) }+ androidx.compose.runtime.LaunchedEffect(Unit) {+ kotlinx.coroutines.delay(12_000)+ val signedIn = context.getSharedPreferences("myspoti_prefs", android.content.Context.MODE_PRIVATE).getBoolean("LoggedIn", false)+ show = signedIn && !updateCardOpen.value && com.music.spotui.data.api.SupportReminder.isDue(context)+ }+ if (!show) return+ val close = { com.music.spotui.data.api.SupportReminder.shown(context); show = false }+ SupportDialog(+ supporter = com.music.spotui.data.api.SupportReminder.level != com.music.spotui.data.api.SupportReminder.Level.NONE,+ onSupport = { close(); com.music.spotui.data.api.SupportReminder.open(context) },+ onDecline = close,+ onSupported = { level -> com.music.spotui.data.api.SupportReminder.setLevel(context, level); close() },+ )+}++/**+ * The reminder card: a request, or a thank-you for someone who already gave. "I've+ * supported" (on trust) asks once or monthly, and unlocks the supporter thank-yous.+ */+@Composable+private fun SupportDialog(supporter: Boolean, onSupport: () -> Unit, onDecline: () -> Unit, onSupported: (com.music.spotui.data.api.SupportReminder.Level) -> Unit) {+ var choosing by androidx.compose.runtime.remember { mutableStateOf(false) }+ androidx.compose.ui.window.Dialog(onDismissRequest = onDecline) {+ androidx.compose.foundation.layout.Column(+ horizontalAlignment = androidx.compose.ui.Alignment.CenterHorizontally,+ modifier = Modifier+ .fillMaxWidth()+ .clip(androidx.compose.foundation.shape.RoundedCornerShape(16.dp))+ .background(androidx.compose.ui.graphics.Color(0xFF242424))+ .padding(horizontal = 24.dp, vertical = 28.dp),+ ) {+ androidx.compose.foundation.Image(+ painter = androidx.compose.ui.res.painterResource(app.myspoti.engine.R.drawable.ic_launcher_foreground),+ contentDescription = null,+ modifier = Modifier.size(72.dp).clip(androidx.compose.foundation.shape.RoundedCornerShape(20.dp))+ .background(androidx.compose.ui.graphics.Color(0xFF181818)),+ )+ androidx.compose.material3.Text(+ androidx.compose.ui.res.stringResource(if (supporter) app.myspoti.engine.R.string.supporter_thanks_title else app.myspoti.engine.R.string.support_title),+ color = androidx.compose.ui.graphics.Color.White, fontFamily = com.music.spotui.ui.theme.AppSans,+ fontWeight = androidx.compose.ui.text.font.FontWeight.Bold, fontSize = 20.sp,+ textAlign = androidx.compose.ui.text.style.TextAlign.Center,+ modifier = Modifier.padding(top = 18.dp),+ )+ androidx.compose.material3.Text(+ androidx.compose.ui.res.stringResource(if (supporter) app.myspoti.engine.R.string.supporter_thanks_body else app.myspoti.engine.R.string.support_body),+ color = androidx.compose.ui.graphics.Color.White.copy(alpha = 0.8f),+ fontFamily = com.music.spotui.ui.theme.AppSans, fontSize = 14.sp, lineHeight = 20.sp,+ textAlign = androidx.compose.ui.text.style.TextAlign.Center,+ modifier = Modifier.padding(top = 12.dp),+ )+ androidx.compose.foundation.layout.Box(+ contentAlignment = androidx.compose.ui.Alignment.Center,+ modifier = Modifier+ .padding(top = 24.dp)+ .fillMaxWidth()+ .height(48.dp)+ .pressable(0.96f, onClick = onSupport)+ .clip(androidx.compose.foundation.shape.RoundedCornerShape(50))+ .background(com.music.spotui.ui.theme.AppAccent),+ ) {+ androidx.compose.material3.Text(+ androidx.compose.ui.res.stringResource(if (supporter) app.myspoti.engine.R.string.support_again else app.myspoti.engine.R.string.support_action),+ color = androidx.compose.ui.graphics.Color.Black, fontFamily = com.music.spotui.ui.theme.AppSans,+ fontWeight = androidx.compose.ui.text.font.FontWeight.Bold, fontSize = 16.sp,+ )+ }+ androidx.compose.material3.Text(+ androidx.compose.ui.res.stringResource(app.myspoti.engine.R.string.support_decline),+ color = androidx.compose.ui.graphics.Color.White, fontFamily = com.music.spotui.ui.theme.AppSans,+ fontWeight = androidx.compose.ui.text.font.FontWeight.Bold, fontSize = 15.sp,+ modifier = Modifier.padding(top = 8.dp).pressable(0.96f, onClick = onDecline).padding(horizontal = 24.dp, vertical = 12.dp),+ )+ if (!supporter && com.music.spotui.data.api.SupportReminder.PERKS_ENABLED) {+ if (choosing) androidx.compose.foundation.layout.Column(+ horizontalAlignment = androidx.compose.ui.Alignment.CenterHorizontally,+ modifier = Modifier.padding(top = 8.dp),+ ) { com.music.spotui.ui.components.SupportChoice(onChosen = onSupported) }+ else androidx.compose.material3.Text(+ androidx.compose.ui.res.stringResource(app.myspoti.engine.R.string.supporter_i_supported),+ color = androidx.compose.ui.graphics.Color.White.copy(alpha = 0.6f), fontFamily = com.music.spotui.ui.theme.AppSans,+ fontSize = 13.sp,+ modifier = Modifier.pressable(0.96f) { choosing = true }.padding(horizontal = 24.dp, vertical = 8.dp),+ )+ }+ }+ }+}++/** "New version" dialog: checked a few seconds after launch (not on the startup path). */+@Composable+private fun UpdatePrompt() {+ val context = androidx.compose.ui.platform.LocalContext.current+ var release by androidx.compose.runtime.remember { mutableStateOf<com.music.spotui.data.api.UpdateChecker.Release?>(null) }+ androidx.compose.runtime.LaunchedEffect(Unit) {+ kotlinx.coroutines.delay(5_000)+ release = com.music.spotui.data.api.UpdateChecker.check(context)+ }+ updateCardOpen.value = release != null+ val r = release ?: return+ val dismiss = { com.music.spotui.data.api.UpdateChecker.dismiss(context, r); release = null }+ UpdateDialog(+ version = r.version,+ notes = r.notes,+ onUpdate = {+ release = null+ context.startActivity(android.content.Intent(android.content.Intent.ACTION_VIEW, android.net.Uri.parse(r.pageUrl))+ .addFlags(android.content.Intent.FLAG_ACTIVITY_NEW_TASK))+ },+ onLater = dismiss,+ )+}++/** The update card, in the app's own style (dark sheet, green pill), not a system dialog. */+@Composable+private fun UpdateDialog(version: String, notes: String, onUpdate: () -> Unit, onLater: () -> Unit) {+ androidx.compose.ui.window.Dialog(onDismissRequest = onLater) {+ androidx.compose.foundation.layout.Column(+ horizontalAlignment = androidx.compose.ui.Alignment.CenterHorizontally,+ modifier = Modifier+ .fillMaxWidth()+ .clip(androidx.compose.foundation.shape.RoundedCornerShape(16.dp))+ .background(androidx.compose.ui.graphics.Color(0xFF242424))+ .padding(horizontal = 24.dp, vertical = 28.dp),+ ) {+ androidx.compose.foundation.Image(+ painter = androidx.compose.ui.res.painterResource(app.myspoti.engine.R.drawable.ic_launcher_foreground),+ contentDescription = null,+ modifier = Modifier.size(72.dp).clip(androidx.compose.foundation.shape.RoundedCornerShape(20.dp))+ .background(androidx.compose.ui.graphics.Color(0xFF181818)),+ )+ androidx.compose.material3.Text(+ androidx.compose.ui.res.stringResource(app.myspoti.engine.R.string.main_update_available),+ color = androidx.compose.ui.graphics.Color.White, fontFamily = com.music.spotui.ui.theme.AppSans,+ fontWeight = androidx.compose.ui.text.font.FontWeight.Bold, fontSize = 20.sp,+ textAlign = androidx.compose.ui.text.style.TextAlign.Center,+ modifier = Modifier.padding(top = 18.dp),+ )+ androidx.compose.material3.Text(+ "Myspoti $version", color = androidx.compose.ui.graphics.Color.White.copy(alpha = 0.7f),+ fontFamily = com.music.spotui.ui.theme.AppSans, fontSize = 15.sp, modifier = Modifier.padding(top = 6.dp),+ )+ // What's new (the release's CHANGELOG section), scrollable if long.+ if (notes.isNotBlank()) androidx.compose.material3.Text(+ notes, color = androidx.compose.ui.graphics.Color.White.copy(alpha = 0.8f),+ fontFamily = com.music.spotui.ui.theme.AppSans, fontSize = 14.sp, lineHeight = 20.sp,+ modifier = Modifier.padding(top = 16.dp).fillMaxWidth().heightIn(max = 240.dp)+ .verticalScroll(androidx.compose.foundation.rememberScrollState()),+ )+ androidx.compose.foundation.layout.Box(+ contentAlignment = androidx.compose.ui.Alignment.Center,+ modifier = Modifier+ .padding(top = 24.dp)+ .fillMaxWidth()+ .height(48.dp)+ .pressable(0.96f, onClick = onUpdate)+ .clip(androidx.compose.foundation.shape.RoundedCornerShape(50))+ .background(com.music.spotui.ui.theme.AppAccent),+ ) {+ androidx.compose.material3.Text(+ androidx.compose.ui.res.stringResource(app.myspoti.engine.R.string.version_sunsetting_dialog_cta_update),+ color = androidx.compose.ui.graphics.Color.Black, fontFamily = com.music.spotui.ui.theme.AppSans,+ fontWeight = androidx.compose.ui.text.font.FontWeight.Bold, fontSize = 16.sp,+ )+ }+ androidx.compose.material3.Text(+ androidx.compose.ui.res.stringResource(app.myspoti.engine.R.string.age_assurance_intro_cta_not_now),+ color = androidx.compose.ui.graphics.Color.White, fontFamily = com.music.spotui.ui.theme.AppSans,+ fontWeight = androidx.compose.ui.text.font.FontWeight.Bold, fontSize = 15.sp,+ modifier = Modifier.padding(top = 8.dp).pressable(0.96f, onClick = onLater).padding(horizontal = 24.dp, vertical = 12.dp),+ )+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/AppLanguage.kt b/base/app/src/main/java/com/music/spotui/data/AppLanguage.ktnew file mode 100644index 00000000..72b25a91--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/AppLanguage.kt@@ -0,0 +1,35 @@+package com.music.spotui.data++import android.content.Context+import androidx.appcompat.app.AppCompatDelegate+import androidx.core.os.LocaleListCompat+import java.util.Locale++/** The app's own language (per-app locale), independent of the phone's. */+object AppLanguage {+ /** Follow the phone. */+ const val SYSTEM = ""++ /** Languages the app has strings for, as BCP 47 tags, after "automatic". */+ val AVAILABLE: List<String> = listOf(SYSTEM) + listOf(+ "af", "am", "ar", "az", "bg", "bn", "bs", "ca", "cs", "da", "de", "el", "en", "en-GB", "es", "es-AR", "es-MX",+ "et", "eu", "fa", "fi", "fr", "fr-CA", "gl", "gu", "hi", "hr", "hu", "id", "is", "it", "he", "ja", "kn", "ko",+ "lt", "lv", "mk", "ml", "mr", "ms", "nb", "ne", "nl", "or", "pa", "pl", "pt", "pt-PT", "ro", "ru", "sk", "sl",+ "sr", "sv", "sw", "ta", "te", "th", "tl", "tr", "uk", "ur", "vi", "zh", "zh-HK", "zh-TW", "zu",+ ).sortedBy { nativeName(it).lowercase() }++ fun current(context: Context): String =+ AppCompatDelegate.getApplicationLocales().takeIf { !it.isEmpty }?.get(0)?.toLanguageTag() ?: SYSTEM++ fun apply(context: Context, tag: String) {+ AppCompatDelegate.setApplicationLocales(+ if (tag == SYSTEM) LocaleListCompat.getEmptyLocaleList() else LocaleListCompat.forLanguageTags(tag)+ )+ }++ /** The language's name in itself ("Français", "Deutsch"…). */+ fun nativeName(tag: String): String {+ val locale = Locale.forLanguageTag(tag)+ return locale.getDisplayName(locale).replaceFirstChar { it.titlecase(locale) }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/BetaLogs.kt b/base/app/src/main/java/com/music/spotui/data/BetaLogs.ktnew file mode 100644index 00000000..da29a604--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/BetaLogs.kt@@ -0,0 +1,43 @@+package com.music.spotui.data++import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.withContext+import java.text.SimpleDateFormat+import java.util.Date+import java.util.Locale++/**+ * The app's own Logcat lines of the last minutes, for beta testers to paste in a bug report.+ * An app can always read its own process's logs; nothing leaves the phone unless the user+ * copies or shares the text. Tokens, e-mails and account ids are masked.+ */+object BetaLogs {+ const val MINUTES = 3+ /** Clipboard and share sheets refuse very large texts. */+ private const val MAX_CHARS = 400_000++ suspend fun recent(minutes: Int = MINUTES): String = withContext(Dispatchers.IO) {+ val since = SimpleDateFormat("MM-dd HH:mm:ss.SSS", Locale.US).format(Date(System.currentTimeMillis() - minutes * 60_000L))+ val text = runCatching {+ val process = ProcessBuilder("logcat", "-d", "-v", "threadtime", "--pid=${android.os.Process.myPid()}", "-T", since)+ .redirectErrorStream(true).start()+ process.inputStream.bufferedReader().use { it.readText() }.also { process.waitFor() }+ }.getOrElse { "logcat unavailable: ${it.message}" }+ val header = "Myspoti ${app.myspoti.engine.BuildConfig.VERSION_NAME} · Android ${android.os.Build.VERSION.RELEASE} (SDK ${android.os.Build.VERSION.SDK_INT}) · " ++ "${android.os.Build.MANUFACTURER} ${android.os.Build.MODEL} · last $minutes min\n\n"+ header + sanitize(text).takeLast(MAX_CHARS)+ }++ private val rules = listOf(+ Regex("Bearer\\s+[A-Za-z0-9._\\-]+") to "Bearer <hidden>",+ Regex("\"(accessToken|access_token|clientToken|client_token|token|refresh_token)\"\\s*:\\s*\"[^\"]*\"") to "\"$1\":\"<hidden>\"",+ Regex("(access_token|token)=[^&\\s\"]+") to "$1=<hidden>",+ Regex("[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\\.[A-Za-z]{2,}") to "<email>",+ Regex("\"(email|username|userName|birthdate|country)\"\\s*:\\s*\"[^\"]*\"") to "\"$1\":\"<hidden>\"",+ Regex("spotify:user:[^\\s\"',)]+") to "spotify:user:<user>",+ Regex("\\b([0-9a-f]{6})[0-9a-f]{14,}\\b") to "$1…",+ Regex("[A-Za-z0-9+/_\\-]{80,}={0,2}") to "<long value>",+ )++ fun sanitize(text: String): String = rules.fold(text) { t, (r, s) -> r.replace(t, s) }+}diff --git a/base/app/src/main/java/com/music/spotui/data/DataSaver.kt b/base/app/src/main/java/com/music/spotui/data/DataSaver.ktnew file mode 100644index 00000000..be5f4f36--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/DataSaver.kt@@ -0,0 +1,84 @@+package com.music.spotui.data++import android.content.Context+import android.net.ConnectivityManager+import android.net.Network+import android.net.NetworkCapabilities+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.setValue++/**+ * Data saver (a switch in the profile menu): on mobile data or another metered network+ * (never on Wi-Fi) the app uses no data at all, as if offline. Every connection is+ * refused ([check], [interceptor], the WebView and Glide guards), the hidden Spotify+ * player is shut down, and only downloaded songs and Local Files play. Back on Wi-Fi,+ * the player is rebuilt.+ */+object DataSaver {+ private const val PREFS = "myspoti_prefs"+ private const val KEY = "DataSaver"++ /** The user's switch. */+ var enabled by mutableStateOf(false)+ private set+ /** The current network costs data (mobile data, a hotspot). */+ var metered by mutableStateOf(false)+ private set+ private var context: Context? = null+ private val main by lazy { android.os.Handler(android.os.Looper.getMainLooper()) }+ @Volatile private var wasActive = false++ /** The saver is on and applies right now. */+ val active: Boolean get() = enabled && metered++ /** A connection refused by the data saver. */+ class Blocked : java.io.IOException("Data saver: no mobile data")++ /** Throws [Blocked] while the saver applies: call before opening any connection. */+ fun check() {+ if (active) throw Blocked()+ }++ /** For OkHttp clients (and Ktor's OkHttp engine). */+ val interceptor = okhttp3.Interceptor { chain -> check(); chain.proceed(chain.request()) }++ /** Shuts the hidden Spotify player down when the saver starts applying, rebuilds it when it stops. */+ private fun changed() {+ val now = active+ if (now == wasActive) return+ wasActive = now+ main.post {+ if (now) app.myspoti.host.android.MyspotiRuntime.suspendPlayer()+ else app.myspoti.host.android.MyspotiRuntime.resume()+ }+ }++ fun init(c: Context) {+ if (context != null) return+ val app = c.applicationContext+ context = app+ enabled = app.getSharedPreferences(PREFS, Context.MODE_PRIVATE).getBoolean(KEY, false)+ val cm = app.getSystemService(ConnectivityManager::class.java) ?: return+ metered = cm.isActiveNetworkMetered+ wasActive = active+ runCatching {+ cm.registerDefaultNetworkCallback(object : ConnectivityManager.NetworkCallback() {+ override fun onCapabilitiesChanged(network: Network, caps: NetworkCapabilities) {+ metered = !caps.hasCapability(NetworkCapabilities.NET_CAPABILITY_NOT_METERED)+ changed()+ }+ override fun onLost(network: Network) {+ metered = cm.isActiveNetworkMetered+ changed()+ }+ })+ }+ }++ fun set(on: Boolean) {+ enabled = on+ changed()+ context?.getSharedPreferences(PREFS, Context.MODE_PRIVATE)?.edit()?.putBoolean(KEY, on)?.apply()+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/DataSaverGlide.kt b/base/app/src/main/java/com/music/spotui/data/DataSaverGlide.ktnew file mode 100644index 00000000..a7abd8ad--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/DataSaverGlide.kt@@ -0,0 +1,48 @@+package com.music.spotui.data++import android.content.Context+import com.bumptech.glide.Glide+import com.bumptech.glide.Priority+import com.bumptech.glide.load.DataSource+import com.bumptech.glide.load.Options+import com.bumptech.glide.load.data.DataFetcher+import com.bumptech.glide.load.model.GlideUrl+import com.bumptech.glide.load.model.ModelLoader+import com.bumptech.glide.load.model.ModelLoaderFactory+import com.bumptech.glide.load.model.MultiModelLoaderFactory+import com.bumptech.glide.load.model.stream.HttpGlideUrlLoader+import java.io.InputStream++/**+ * Images under the data saver: Glide still shows what its disk cache holds, and asks+ * the network for nothing (see [DataSaver]).+ */+object DataSaverGlide {+ fun install(context: Context) {+ Glide.get(context).registry.replace(GlideUrl::class.java, InputStream::class.java, Factory())+ }++ private class Factory : ModelLoaderFactory<GlideUrl, InputStream> {+ override fun build(multiFactory: MultiModelLoaderFactory): ModelLoader<GlideUrl, InputStream> =+ Loader(HttpGlideUrlLoader())+ override fun teardown() {}+ }++ private class Loader(private val inner: ModelLoader<GlideUrl, InputStream>) : ModelLoader<GlideUrl, InputStream> {+ override fun buildLoadData(model: GlideUrl, width: Int, height: Int, options: Options): ModelLoader.LoadData<InputStream>? {+ val data = inner.buildLoadData(model, width, height, options) ?: return null+ return ModelLoader.LoadData(data.sourceKey, data.alternateKeys, Fetcher(data.fetcher))+ }+ override fun handles(model: GlideUrl) = inner.handles(model)+ }++ private class Fetcher(private val inner: DataFetcher<InputStream>) : DataFetcher<InputStream> {+ override fun loadData(priority: Priority, callback: DataFetcher.DataCallback<in InputStream>) {+ if (DataSaver.active) callback.onLoadFailed(DataSaver.Blocked()) else inner.loadData(priority, callback)+ }+ override fun cleanup() = inner.cleanup()+ override fun cancel() = inner.cancel()+ override fun getDataClass(): Class<InputStream> = inner.dataClass+ override fun getDataSource(): DataSource = inner.dataSource+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/api/Api.kt b/base/app/src/main/java/com/music/spotui/data/api/Api.ktnew file mode 100644index 00000000..2fa15162--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/api/Api.kt@@ -0,0 +1,733 @@+package com.music.spotui.data.api++import kotlinx.coroutines.withContext+import kotlinx.coroutines.Dispatchers+import android.util.Log+import app.myspoti.api.Album+import app.myspoti.api.Artist+import app.myspoti.api.Image+import app.myspoti.api.LibraryFilter+import app.myspoti.api.MediaCard+import app.myspoti.api.MediaKind+import app.myspoti.api.MyspotiApi+import app.myspoti.api.Playlist+import app.myspoti.api.Track+import app.myspoti.api.best+import app.myspoti.engine.R+import app.myspoti.host.android.MyspotiRuntime+import com.music.spotui.data.entity.AlbumsModel+import com.music.spotui.data.entity.ArtistOverviewModel+import com.music.spotui.data.entity.ArtistTrackUi+import com.music.spotui.data.entity.ArtistsModel+import com.music.spotui.data.entity.ContextPageModel+import com.music.spotui.data.entity.HomeFeedModel+import com.music.spotui.data.entity.HomeItem+import com.music.spotui.data.entity.HomeSection+import com.music.spotui.data.entity.LibraryEntry+import com.music.spotui.data.entity.PodcastModel+import com.music.spotui.data.entity.SearchResults+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.di.Graph+import com.music.spotui.di.SongPlayer+import kotlinx.coroutines.async+import kotlinx.coroutines.coroutineScope+import kotlinx.coroutines.flow.Flow+import kotlinx.coroutines.flow.first+import kotlinx.coroutines.flow.flow+import kotlinx.coroutines.withTimeoutOrNull++/**+ * The UI's data source, over [MyspotiApi]. Keeps the `Flow<Response<...>>` contract the+ * ViewModels use; every call maps the API's models to the UI's ones.+ */+class Api constructor(+ private val context: android.content.Context = Graph.app,+) {+ private val api: MyspotiApi get() = MyspotiRuntime.api++ private fun stableId(key: String): Int = key.hashCode() and 0x7fffffff++ /** Process-level caches: screens show the last result at once, then refresh. */+ companion object HomeCache {+ /** Sentinel id for the pinned "Liked Songs" library entry. */+ const val LIKED_SONGS_ID = "liked-songs"+ /** The "Local Files" folder pinned under Liked Songs in the library (not a Spotify item). */+ const val LOCAL_FILES_ID = "local-files"+ /** "Downloaded" (songs kept for offline listening), pinned under Local Files. */+ const val DOWNLOADS_ID = "downloads"+ /** "Your Episodes" (saved podcast episodes). */+ const val EPISODES_ID = "your-episodes"+ @Volatile var albums: List<AlbumsModel>? = null+ @Volatile var artists: List<ArtistsModel>? = null+ @Volatile var home: HomeFeedModel? = null+ val facets = java.util.concurrent.ConcurrentHashMap<String, HomeFeedModel>()+ @Volatile var library: List<LibraryEntry>? = null+ /** Library as shown by the Library screen (root level, folders closed). */+ @Volatile var libraryRoot: List<LibraryEntry>? = null+ /** Contents of the library folders opened so far, by folder uri. */+ val folders = java.util.concurrent.ConcurrentHashMap<String, List<LibraryEntry>>()++ /** Drop all cached feeds (e.g. on logout / account switch). */+ fun clear() {+ albums = null; artists = null; home = null; library = null+ libraryRoot = null; folders.clear()+ facets.clear()+ LikedCache.tracks = null+ ScreenCache.clear()+ }+ }++ object LikedCache { @Volatile var tracks: List<SongsModel>? = null }++ /** True once the Web Player is signed in and ready (waits up to 30 s at startup). */+ private suspend fun ready(): Boolean =+ withTimeoutOrNull(30_000) { api.ready.first { it } } != null++ private suspend fun diskHome(): HomeFeedModel? =+ withContext(Dispatchers.IO) { ScreenCache.home.read() }?.also { HomeCache.home = it }++ private fun notSignedIn() = context.getString(R.string.not_signed_in)++ // ── Mapping ──++ private fun cover(images: List<Image>) = images.best(300)?.url.orEmpty()+ private fun big(images: List<Image>) = images.best(640)?.url.orEmpty()++ fun songOf(t: Track): SongsModel {+ val id = t.uri.substringAfterLast(':')+ val singer = t.artists.joinToString(", ") { it.name }+ return SongsModel(+ id = stableId("track:$id"),+ title = t.name.take(128),+ album = t.album?.name.orEmpty(),+ singer = singer,+ coverUri = cover(t.album?.images.orEmpty()),+ url = SongPlayer.buildSpotifyPlayQuery(id, t.name, singer),+ spotifyTrackId = id,+ explicit = t.explicit,+ durationMs = t.durationMs.toInt(),+ albumId = t.album?.uri?.substringAfterLast(':').orEmpty(),+ )+ }++ private fun episodeSong(e: app.myspoti.api.Episode): SongsModel {+ val id = e.uri.substringAfterLast(':')+ val show = e.show?.name ?: "Podcast"+ return SongsModel(+ id = stableId("episode:$id"),+ title = e.name,+ album = show,+ singer = show,+ coverUri = cover(e.images).ifBlank { cover(e.show?.images.orEmpty()) },+ url = "episode:$id",+ durationMs = e.durationMs.toInt(),+ )+ }++ private fun albumOf(a: Album) = AlbumsModel(+ spotifyId = a.uri.substringAfterLast(':'),+ id = stableId("album:${a.uri}"),+ artists = a.artists.joinToString(", ") { it.name },+ coverUri = cover(a.images),+ name = a.name,+ time = a.releaseDate?.take(4).orEmpty(),+ type = a.type,+ )++ private fun artistOf(a: Artist) = ArtistsModel(name = a.name, coverUri = cover(a.images), id = a.uri.substringAfterLast(':'))++ private fun playlistEntry(p: Playlist) = LibraryEntry(+ spotifyId = p.uri.substringAfterLast(':'),+ name = p.name,+ subtitle = context.getString(R.string.assisted_curation_search_playlist) + (p.owner?.let { " • $it" } ?: ""),+ coverUri = cover(p.images),+ isPlaylist = true,+ )++ private fun homeItem(c: MediaCard): HomeItem? {+ val id = c.uri.substringAfterLast(':')+ val image = cover(c.images)+ return when (c.kind) {+ MediaKind.ALBUM -> HomeItem.Album(id = id, name = c.title, imageUrl = image, subtitle = c.subtitle ?: "Album", artists = c.subtitle.orEmpty())+ MediaKind.ARTIST -> HomeItem.Artist(name = c.title, imageUrl = image, id = id)+ MediaKind.PLAYLIST -> HomeItem.Playlist(name = c.title, imageUrl = image, subtitle = c.subtitle?.let { "Playlist • $it" } ?: "Playlist", id = id)+ MediaKind.SHOW, MediaKind.AUDIOBOOK -> HomeItem.Show(id = id, name = c.title, imageUrl = image, subtitle = c.subtitle.orEmpty(), isEpisode = false)+ MediaKind.EPISODE, MediaKind.CHAPTER -> HomeItem.Show(id = id, name = c.title, imageUrl = image, subtitle = c.subtitle.orEmpty(), isEpisode = true)+ MediaKind.COLLECTION -> HomeItem.Playlist(name = c.title, imageUrl = image.ifBlank { LIKED_COVER }, subtitle = "Playlist", id = LIKED_SONGS_ID)+ else -> null+ }+ }++ private val LIKED_COVER = "https://misc.scdn.co/liked-songs/liked-songs-640.png"++ private fun likedEntry() = LibraryEntry(+ spotifyId = LIKED_SONGS_ID,+ name = context.getString(R.string.collection_liked_songs_title),+ subtitle = context.getString(R.string.assisted_curation_search_playlist),+ coverUri = LIKED_COVER,+ isPlaylist = true,+ )++ // ── Home ──++ /** New releases: albums from the home feed's music shelves. */+ suspend fun getAlbums(): Flow<Response<List<AlbumsModel>>> = flow {+ HomeCache.albums?.let { emit(Response.Success(it)) } ?: emit(Response.Loading())+ if (!ready()) { if (HomeCache.albums == null) emit(Response.Error(notSignedIn())); return@flow }+ runCatching { newReleases() }.fold(+ onSuccess = { HomeCache.albums = it; emit(Response.Success(it)) },+ onFailure = { Log.e("Api", "getAlbums failed", it); if (HomeCache.albums == null) emit(Response.Error(it.message ?: "error")) },+ )+ }++ /**+ * New releases for the "New releases" screen: albums from artists the user follows+ * (home shelves), then Spotify's new-release editorial playlists' albums.+ */+ suspend fun newReleases(): List<AlbumsModel> {+ val feed = api.home.feed(app.myspoti.api.HomeFilter.MUSIC, itemsPerShelf = 30)+ val albums = feed.shelves.flatMap { it.items }.filter { it.kind == MediaKind.ALBUM }.distinctBy { it.uri }+ return albums.map { c ->+ AlbumsModel(spotifyId = c.uri.substringAfterLast(':'), id = stableId("album:${c.uri}"), artists = c.subtitle.orEmpty(),+ coverUri = cover(c.images), name = c.title, time = "", type = "ALBUM")+ }+ }++ /** Artists the user follows (library "Artists" filter). */+ suspend fun getFollowedArtists(): List<ArtistsModel> {+ if (!ready()) return emptyList()+ val out = ArrayList<ArtistsModel>()+ var offset = 0+ while (true) {+ val page = runCatching { api.library.items(filter = LibraryFilter.ARTISTS, offset = offset, limit = 50) }.getOrNull() ?: break+ page.items.filter { it.kind == MediaKind.ARTIST }.forEach { out += ArtistsModel(it.name, cover(it.images), it.uri.substringAfterLast(':')) }+ offset = page.nextOffset ?: break+ }+ return out+ }++ /** The user's top artists. */+ suspend fun getArtists(): Flow<Response<List<ArtistsModel>>> = flow {+ HomeCache.artists?.let { emit(Response.Success(it)) } ?: emit(Response.Loading())+ if (!ready()) { if (HomeCache.artists == null) emit(Response.Error(notSignedIn())); return@flow }+ runCatching { api.users.top(limit = 20).artists.map(::artistOf) }.fold(+ onSuccess = { HomeCache.artists = it; emit(Response.Success(it)) },+ onFailure = { Log.e("Api", "getArtists failed", it); if (HomeCache.artists == null) emit(Response.Error(it.message ?: "error")) },+ )+ }++ /** The user's top tracks. */+ suspend fun getSongs(): Flow<Response<List<SongsModel>>> = flow {+ emit(Response.Loading())+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ runCatching { api.users.top(limit = 50).tracks.map(::songOf) }.fold(+ onSuccess = { emit(Response.Success(it)) },+ onFailure = { Log.e("Api", "getSongs failed", it); emit(Response.Error(it.message ?: "error")) },+ )+ }++ /** [facet]: "" (all), "music-chip", "podcasts-chip", "audiobooks-chip". */+ suspend fun getHomeFeed(facet: String = ""): Flow<Response<HomeFeedModel>> = flow {+ val cached = if (facet.isEmpty()) HomeCache.home ?: diskHome() else HomeCache.facets[facet]+ cached?.let { emit(Response.Success(it)) } ?: emit(Response.Loading())+ if (!ready()) { if (cached == null) emit(Response.Error(notSignedIn())); return@flow }+ val filter = app.myspoti.api.HomeFilter.entries.firstOrNull { it.facet == facet } ?: app.myspoti.api.HomeFilter.ALL+ runCatching { api.home.feed(filter, itemsPerShelf = 20) }.fold(+ onSuccess = { feed ->+ val sections = feed.shelves.mapNotNull { shelf ->+ val items = shelf.items.distinctBy { it.uri }.mapNotNull(::homeItem)+ .distinctBy { it::class.simpleName + "|" + it.name.lowercase() }+ if (items.isEmpty()) null else HomeSection(title = shelf.title.orEmpty(), items = items)+ }.distinctBy { it.title.lowercase().ifBlank { it.hashCode().toString() } }+ val model = HomeFeedModel(greeting = feed.greeting, sections = sections)+ if (facet.isEmpty()) { HomeCache.home = model; ScreenCache.home.write(model) } else HomeCache.facets[facet] = model+ emit(Response.Success(model))+ },+ onFailure = { Log.e("Api", "getHomeFeed failed", it); if (cached == null) emit(Response.Error(it.message ?: "error")) },+ )+ }++ // ── Search ──++ suspend fun searchTracks(query: String): Flow<Response<List<SongsModel>>> = flow {+ emit(Response.Loading())+ if (query.isBlank()) { emit(Response.Success(emptyList())); return@flow }+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ runCatching { api.search.tracks(query, limit = 30).items.map(::songOf) }.fold(+ onSuccess = { emit(Response.Success(it)) },+ onFailure = { Log.e("Api", "searchTracks failed", it); emit(Response.Error(it.message ?: "error")) },+ )+ }++ /** Tracks, albums, artists and playlists in parallel, then podcasts and episodes. */+ suspend fun searchEverything(query: String): Flow<Response<SearchResults>> = flow {+ emit(Response.Loading())+ if (query.isBlank()) { emit(Response.Success(SearchResults())); return@flow }+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ val music = runCatching { api.search.all(query, limit = 20) }.getOrElse {+ Log.e("Api", "searchEverything failed", it); emit(Response.Error(it.message ?: "error")); return@flow+ }+ val base = SearchResults(+ songs = music.tracks.items.map(::songOf),+ albums = music.albums.items.map(::albumOf),+ artists = music.artists.items.map(::artistOf),+ playlists = music.playlists.items.map(::playlistEntry),+ )+ emit(Response.Success(base))+ val (shows, episodes) = coroutineScope {+ val s = async { runCatching { api.search.shows(query, limit = 12).items }.getOrDefault(emptyList()) }+ val e = async { runCatching { api.search.episodes(query, limit = 12).items }.getOrDefault(emptyList()) }+ s.await() to e.await()+ }+ if (shows.isNotEmpty() || episodes.isNotEmpty()) emit(Response.Success(base.copy(+ shows = shows.map { PodcastModel(it.uri.substringAfterLast(':'), it.title, it.subtitle.orEmpty(), cover(it.images)) },+ episodes = episodes.map(::episodeSong),+ )))+ }++ // ── Podcasts ──++ /** A podcast's episodes, newest first, as playable songs (url = "episode:<id>"). */+ suspend fun getShowEpisodes(showId: String): Flow<Response<List<SongsModel>>> = flow {+ emit(Response.Loading())+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ val uri = "spotify:show:$showId"+ runCatching {+ val out = ArrayList<SongsModel>()+ var offset = 0+ repeat(10) {+ val page = api.podcasts.episodes(uri, offset, 50)+ out += page.items.map(::episodeSong)+ emit(Response.Success(out.toList()))+ offset = page.nextOffset ?: return@runCatching out+ }+ out+ }.fold(+ onSuccess = { songs -> SongPlayer.registerContext(songs.map { it.url }, uri); emit(Response.Success(songs)) },+ onFailure = { Log.e("Api", "getShowEpisodes failed", it); emit(Response.Error(it.message ?: "error")) },+ )+ }++ /** Show header (name, publisher, cover). */+ suspend fun getShow(showId: String): PodcastModel? {+ if (!ready()) return null+ return runCatching { api.podcasts.show("spotify:show:$showId") }.getOrNull()?.let {+ PodcastModel(showId, it.name, it.publisher, big(it.images))+ }+ }++ /** "Your Episodes": saved podcast episodes. */+ suspend fun getSavedEpisodes(): List<SongsModel> {+ if (!ready()) return emptyList()+ return runCatching { api.podcasts.savedEpisodes(limit = 100).items.map(::episodeSong) }.getOrDefault(emptyList())+ }++ // ── Radio and categories ──++ /** The song radio after [seedTrackIds]' last track: Spotify's own radio playlist. */+ suspend fun getRecommendations(seedTrackIds: List<String>): List<SongsModel> {+ val seed = seedTrackIds.lastOrNull { it.isNotBlank() } ?: return emptyList()+ if (!ready()) return emptyList()+ val radio = runCatching { api.extras.radio("spotify:track:$seed") }.getOrNull() ?: return emptyList()+ return runCatching { api.playlists.tracks(radio, 0, 50).items.map(::songOf).filter { it.spotifyTrackId != seed } }.getOrDefault(emptyList())+ }++ /** The radio playlist id for a track or artist uri (for "Go to song radio"). */+ suspend fun radioPlaylistId(seedUri: String): String? =+ if (!ready()) null else runCatching { api.extras.radio(seedUri) }.getOrNull()?.substringAfterLast(':')++ /**+ * A browse category: Spotify's own category page when [genre] is a page/genre uri or id,+ * else playlists matching the name.+ */+ suspend fun getCategoryPlaylists(genre: String): Flow<Response<List<LibraryEntry>>> = flow {+ emit(Response.Loading())+ if (genre.isBlank()) { emit(Response.Success(emptyList())); return@flow }+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ val pageUri = when {+ genre.startsWith("spotify:page:") || genre.startsWith("spotify:genre:") -> genre+ else -> runCatching { api.home.categories() }.getOrNull()?.firstOrNull { it.title.equals(genre, ignoreCase = true) }?.uri+ }+ val entries = runCatching {+ if (pageUri != null) {+ api.home.category(pageUri).shelves.flatMap { it.items }.distinctBy { it.uri }.mapNotNull { c ->+ if (c.kind != MediaKind.PLAYLIST && c.kind != MediaKind.ALBUM) return@mapNotNull null+ LibraryEntry(c.uri.substringAfterLast(':'), c.title, c.subtitle.orEmpty(), cover(c.images), isPlaylist = c.kind == MediaKind.PLAYLIST)+ }+ } else api.search.playlists(genre, limit = 24).items.map(::playlistEntry)+ }+ entries.fold(+ onSuccess = { emit(Response.Success(it)) },+ onFailure = { Log.e("Api", "getCategoryPlaylists failed", it); emit(Response.Error(it.message ?: "error")) },+ )+ }++ // ── Artists ──++ private suspend fun findArtist(name: String): Artist? {+ val hits = api.search.artists(name, limit = 5).items+ return hits.firstOrNull { it.name.equals(name, ignoreCase = true) } ?: hits.firstOrNull()+ }++ suspend fun getArtistSongs(artistName: String): Flow<Response<List<SongsModel>>> = flow {+ emit(Response.Loading())+ if (artistName.isBlank()) { emit(Response.Success(emptyList())); return@flow }+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ runCatching {+ val artist = findArtist(artistName) ?: return@runCatching emptyList()+ api.catalog.artistTopTracks(artist.uri).map { songOf(it).let { s -> if (s.coverUri.isBlank()) s.copy(coverUri = cover(artist.images)) else s } }+ }.fold(+ onSuccess = { emit(Response.Success(it)) },+ onFailure = { Log.e("Api", "getArtistSongs failed", it); emit(Response.Error(it.message ?: "error")) },+ )+ }++ /** The full artist page; [knownArtistId] avoids the fuzzy name lookup. */+ suspend fun getArtistOverview(artistName: String, knownArtistId: String = ""): Flow<Response<ArtistOverviewModel>> = flow {+ emit(Response.Loading())+ if (artistName.isBlank() && knownArtistId.isBlank()) { emit(Response.Success(ArtistOverviewModel(name = artistName))); return@flow }+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ val uri = if (knownArtistId.isNotBlank()) "spotify:artist:$knownArtistId"+ else runCatching { findArtist(artistName) }.getOrNull()?.uri+ if (uri == null) { emit(Response.Error(context.getString(R.string.artist_not_found))); return@flow }+ val page = runCatching { api.catalog.artistPage(uri) }.getOrElse {+ Log.e("Api", "getArtistOverview failed", it); emit(Response.Error(it.message ?: "error")); return@flow+ }+ val avatar = big(page.artist.images)+ val top = page.topTracks.map { t -> songOf(t.track).let { if (it.coverUri.isBlank()) it.copy(coverUri = avatar) else it } to t.playcount }+ SongPlayer.registerContext(top.map { it.first.url }, uri)+ val model = ArtistOverviewModel(+ id = uri.substringAfterLast(':'),+ name = page.artist.name.ifBlank { artistName },+ verified = page.artist.verified,+ monthlyListeners = page.artist.monthlyListeners,+ biography = page.biography,+ headerImage = big(page.headerImages).ifBlank { avatar },+ avatarImage = avatar,+ topTracks = top.map { (song, plays) -> ArtistTrackUi(song, plays) },+ popularReleases = page.popularReleases.map(::albumOf),+ appearsOn = page.appearsOn.map(::albumOf),+ relatedArtists = page.related.map(::artistOf),+ )+ emit(Response.Success(model))+ // The overview carries only part of the discography: the whole list follows.+ val all = runCatching { api.catalog.discography(uri, 0, 50).items }.getOrNull().orEmpty()+ val known = page.popularReleases.map { it.uri }.toSet()+ if (all.any { it.uri !in known }) {+ val merged = (page.popularReleases + all).distinctBy { it.uri }.sortedByDescending { it.releaseDate.orEmpty() }+ emit(Response.Success(model.copy(popularReleases = merged.map(::albumOf))))+ }+ }++ // ── Albums and playlists ──++ private fun dateLabel(iso: String?): String {+ if (iso.isNullOrBlank()) return ""+ return runCatching {+ val d = java.time.LocalDate.parse(iso.take(10))+ d.format(java.time.format.DateTimeFormatter.ofPattern("d MMM yyyy", java.util.Locale.getDefault()))+ }.getOrDefault(iso.take(4))+ }++ private fun durationLabel(totalMs: Long): String {+ val min = totalMs / 60000+ return if (min >= 60) "${min / 60} h ${min % 60} min" else "$min min"+ }++ /** Album id for a name (+ artist) when the caller only knows the name. */+ suspend fun resolveAlbumId(albumName: String, artist: String = ""): String? {+ if (albumName.isBlank() || !ready()) return null+ val hits = runCatching { api.search.albums(if (artist.isBlank()) albumName else "$albumName $artist", limit = 10).items }.getOrNull().orEmpty()+ return pickAlbum(hits, albumName, artist)?.uri?.substringAfterLast(':')+ }++ /** Liked Songs as a page: cached list shown instantly, then refreshed page by page. */+ suspend fun getLikedPage(): Flow<Response<ContextPageModel>> = flow {+ fun page(tracks: List<SongsModel>, complete: Boolean) = ContextPageModel(+ uri = "spotify:collection:tracks",+ type = "liked",+ name = context.getString(R.string.collection_liked_songs_title),+ coverUri = "",+ ownerName = ProfileCache.name.orEmpty(),+ ownerAvatar = ProfileCache.imageUrl.orEmpty(),+ metaLine = context.resources.getQuantityString(R.plurals.liked_songs_header_metadata_text, tracks.size, tracks.size),+ tracks = tracks,+ complete = complete,+ )+ if (LikedCache.tracks == null) LikedCache.tracks = withContext(Dispatchers.IO) { ScreenCache.liked.read() }+ LikedCache.tracks?.let { emit(Response.Success(page(it, true))) } ?: emit(Response.Loading())+ if (!ready()) { if (LikedCache.tracks == null) emit(Response.Error(notSignedIn())); return@flow }+ val first = LikedCache.tracks == null+ val tracks = runCatching { allLiked { if (first) emit(Response.Success(page(it, false))) } }.getOrElse {+ Log.e("Api", "getLikedPage failed", it)+ if (LikedCache.tracks == null) emit(Response.Error(context.getString(R.string.couldnt_load, context.getString(R.string.collection_liked_songs_title))))+ return@flow+ }+ LikedCache.tracks = tracks+ ScreenCache.liked.write(tracks)+ SongPlayer.registerLikedSongs(tracks.map { it.url })+ emit(Response.Success(page(tracks, true)))+ }++ private suspend fun allLiked(onPage: suspend (List<SongsModel>) -> Unit): List<SongsModel> {+ val out = ArrayList<SongsModel>()+ var offset = 0+ while (true) {+ val page = api.library.likedTracks(offset, 50)+ out += page.items.map { songOf(it.track) }+ onPage(out.toList())+ offset = page.nextOffset ?: break+ }+ return out+ }++ suspend fun getAlbumPage(albumId: String): Flow<Response<ContextPageModel>> = flow {+ emit(Response.Loading())+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ val uri = "spotify:album:$albumId"+ val (album, tracks) = runCatching {+ coroutineScope {+ val a = async { api.catalog.album(uri) }+ val t = async {+ val out = ArrayList<Track>()+ var offset = 0+ while (true) {+ val p = api.catalog.albumTracks(uri, offset, 50)+ out += p.items+ offset = p.nextOffset ?: break+ }+ out+ }+ a.await() to t.await()+ }+ }.getOrElse { emit(Response.Error(context.getString(R.string.album_not_found))); return@flow }+ val songs = tracks.map { songOf(it).copy(album = album.name, coverUri = cover(album.images), albumId = albumId) }+ SongPlayer.registerContext(songs.map { it.url }, uri)+ val type = context.getString(when (album.type) {+ "SINGLE" -> R.string.album_type_single; "EP" -> R.string.album_type_ep+ "COMPILATION" -> R.string.album_type_compilation; else -> R.string.album_type_album+ })+ val firstArtist = album.artists.firstOrNull()+ val avatar = firstArtist?.let { runCatching { api.catalog.artist(it.uri) }.getOrNull() }?.images?.let(::cover).orEmpty()+ emit(Response.Success(ContextPageModel(+ uri = uri,+ type = "album",+ name = album.name,+ coverUri = big(album.images),+ ownerName = album.artists.joinToString(", ") { it.name },+ ownerAvatar = avatar,+ ownerUri = firstArtist?.uri.orEmpty(),+ metaLine = listOf(type, dateLabel(album.releaseDate)).filter { it.isNotBlank() }.joinToString(" • "),+ explicit = songs.any { it.explicit },+ tracks = songs,+ )))+ }++ suspend fun getPlaylistPage(playlistId: String): Flow<Response<ContextPageModel>> = flow {+ emit(Response.Loading())+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ val uri = "spotify:playlist:$playlistId"+ val pl = runCatching { api.playlists.playlist(uri) }.getOrElse {+ emit(Response.Error(context.getString(R.string.playlist_not_found))); return@flow+ }+ val saves = pl.followers?.takeIf { it > 0 }?.let {+ context.resources.getQuantityString(R.plurals.profile_list_item_saves_count, it.coerceAtMost(Int.MAX_VALUE.toLong()).toInt(), it)+ }.orEmpty()+ val header = ContextPageModel(+ uri = uri,+ type = "playlist",+ name = pl.name,+ coverUri = big(pl.images),+ description = stripHtml(pl.description),+ ownerName = pl.owner.orEmpty(),+ ownerAvatar = cover(pl.ownerImages),+ ownerUri = pl.ownerUri.orEmpty(),+ metaLine = saves,+ )+ val songs = ArrayList<SongsModel>()+ var offset = 0+ var failed = false+ while (true) {+ val page = runCatching { api.playlists.tracks(uri, offset, 100) }.getOrElse { failed = true; null } ?: break+ songs += page.items.map(::songOf)+ SongPlayer.registerContext(songs.map { it.url }, uri)+ val total = songs.sumOf { it.durationMs.toLong() }+ val meta = listOf(saves, if (total > 0) durationLabel(total) else "").filter { it.isNotBlank() }.joinToString(" • ")+ val done = page.nextOffset == null+ emit(Response.Success(header.copy(metaLine = meta, tracks = songs.toList(), complete = done)))+ offset = page.nextOffset ?: break+ }+ if (failed && songs.isEmpty()) emit(Response.Error(context.getString(R.string.couldnt_load, pl.name)))+ }++ suspend fun getAlbumSongs(albumName: String, artist: String = ""): Flow<Response<List<SongsModel>>> = flow {+ emit(Response.Loading())+ if (albumName.isBlank()) { emit(Response.Success(emptyList())); return@flow }+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ val id = resolveAlbumId(albumName, artist) ?: run { emit(Response.Success(emptyList())); return@flow }+ runCatching { api.catalog.albumTracks("spotify:album:$id", 0, 50).items.map(::songOf) }.fold(+ onSuccess = { songs -> SongPlayer.registerContext(songs.map { it.url }, "spotify:album:$id"); emit(Response.Success(songs)) },+ onFailure = { Log.e("Api", "getAlbumSongs failed", it); emit(Response.Error(it.message ?: "error")) },+ )+ }++ /** A playlist's tracks, first page at once, then the rest. */+ suspend fun getPlaylistSongs(playlistId: String): Flow<Response<List<SongsModel>>> = flow {+ emit(Response.Loading())+ if (playlistId.isBlank()) { emit(Response.Success(emptyList())); return@flow }+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ val uri = "spotify:playlist:$playlistId"+ val songs = ArrayList<SongsModel>()+ var offset = 0+ while (true) {+ val page = runCatching { api.playlists.tracks(uri, offset, 100) }.getOrNull() ?: break+ songs += page.items.map(::songOf)+ SongPlayer.registerContext(songs.map { it.url }, uri)+ emit(Response.Success(songs.toList()))+ offset = page.nextOffset ?: break+ }+ if (songs.isEmpty()) emit(Response.Error("Couldn't load this playlist"))+ }++ // ── Library ──++ private fun entryOf(item: app.myspoti.api.LibraryItem): LibraryEntry? = when (item.kind) {+ MediaKind.FOLDER -> LibraryEntry(+ spotifyId = item.uri, name = item.name,+ subtitle = context.getString(R.string.create_menu_item_folder_title) + " • " ++ context.resources.getQuantityString(R.plurals.add_to_playlist_folder_subtitle_playlists_count, item.count ?: 0, (item.count ?: 0).toString()),+ coverUri = "", isPlaylist = false, folderUri = item.uri, childCount = item.count ?: 0,+ )+ MediaKind.PLAYLIST -> LibraryEntry(item.uri.substringAfterLast(':'), item.name,+ context.getString(R.string.assisted_curation_search_playlist) + (item.subtitle?.let { " • $it" } ?: ""), cover(item.images), isPlaylist = true)+ MediaKind.ALBUM -> LibraryEntry(item.uri.substringAfterLast(':'), item.name,+ context.getString(R.string.album_type_album) + (item.subtitle?.let { " • $it" } ?: ""), cover(item.images), isPlaylist = false, artists = item.subtitle.orEmpty())+ MediaKind.COLLECTION -> if (item.uri == "spotify:collection:tracks") null+ else LibraryEntry(EPISODES_ID, item.name, "Podcast", cover(item.images), isPlaylist = true)+ else -> null+ }++ private suspend fun libraryLevel(folderUri: String?, filter: LibraryFilter = LibraryFilter.ALL): List<app.myspoti.api.LibraryItem> {+ val out = ArrayList<app.myspoti.api.LibraryItem>()+ var offset = 0+ repeat(40) {+ val page = api.library.items(filter = filter, folderUri = folderUri, offset = offset, limit = 50)+ out += page.items+ offset = page.nextOffset ?: return out+ }+ return out+ }++ /** Flat library (Android Auto, pickers): Liked Songs, playlists, then albums. */+ suspend fun getLibrary(): Flow<Response<List<LibraryEntry>>> = flow {+ HomeCache.library?.let { emit(Response.Success(it)) } ?: emit(Response.Loading())+ if (!ready()) { if (HomeCache.library == null) emit(Response.Error(notSignedIn())); return@flow }+ runCatching {+ val playlists = api.playlists.mine().map(::playlistEntry)+ val albums = libraryLevel(null, LibraryFilter.ALBUMS).mapNotNull(::entryOf).filter { !it.isPlaylist }+ listOf(likedEntry()) + playlists + albums+ }.fold(+ onSuccess = { HomeCache.library = it; emit(Response.Success(it)) },+ onFailure = { Log.e("Api", "getLibrary failed", it); if (HomeCache.library == null) emit(Response.Error(it.message ?: "error")) },+ )+ }++ /** "Your Library" as Spotify shows it: Liked Songs, then folders, playlists and albums in the user's order. */+ suspend fun getLibraryRoot(): Flow<Response<List<LibraryEntry>>> = flow {+ if (HomeCache.libraryRoot == null) HomeCache.libraryRoot = withContext(Dispatchers.IO) { ScreenCache.libraryRoot.read() }+ HomeCache.libraryRoot?.let { emit(Response.Success(it)) } ?: emit(Response.Loading())+ if (!ready()) { if (HomeCache.libraryRoot == null) emit(Response.Error(notSignedIn())); return@flow }+ runCatching { listOf(likedEntry()) + libraryLevel(null).mapNotNull(::entryOf) }.fold(+ onSuccess = { HomeCache.libraryRoot = it; ScreenCache.libraryRoot.write(it); emit(Response.Success(it)) },+ onFailure = { Log.e("Api", "getLibraryRoot failed", it); if (HomeCache.libraryRoot == null) emit(Response.Error(it.message ?: "error")) },+ )+ }++ /** The folders and playlists inside one library folder. */+ suspend fun getLibraryFolder(folderUri: String): Flow<Response<List<LibraryEntry>>> = flow {+ HomeCache.folders[folderUri]?.let { emit(Response.Success(it)) } ?: emit(Response.Loading())+ if (!ready()) { if (HomeCache.folders[folderUri] == null) emit(Response.Error(notSignedIn())); return@flow }+ runCatching { libraryLevel(folderUri).mapNotNull(::entryOf) }.fold(+ onSuccess = { HomeCache.folders[folderUri] = it; emit(Response.Success(it)) },+ onFailure = { Log.e("Api", "getLibraryFolder failed", it); if (HomeCache.folders[folderUri] == null) emit(Response.Error(it.message ?: "error")) },+ )+ }++ /** The looping Canvas video for a track, cached per track (also when there is none). */+ suspend fun getCanvasUrl(trackId: String): String? {+ if (trackId.isBlank()) return null+ CanvasCache.map[trackId]?.let { return it.value }+ if (!ready()) return null+ val url = runCatching { api.extras.canvas("spotify:track:$trackId")?.videoUrl }.getOrNull()+ CanvasCache.map[trackId] = CanvasCache.Entry(url)+ return url+ }++ private object CanvasCache {+ class Entry(val value: String?)+ val map = java.util.concurrent.ConcurrentHashMap<String, Entry>()+ }++ /** Liked Songs as playable songs; also keeps the local hearts in step. */+ suspend fun getLikedSongs(): Flow<Response<List<SongsModel>>> = flow {+ emit(Response.Loading())+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ runCatching {+ allLiked { emit(Response.Success(it)) }+ }.fold(+ onSuccess = { songs ->+ SongPlayer.registerLikedSongs(songs.map { it.url })+ com.music.spotui.data.preferences.syncSpotifyLikedSongIds(context, songs.mapTo(HashSet()) { it.id.toString() }, complete = true)+ LikedCache.tracks = songs+ emit(Response.Success(songs))+ },+ onFailure = { emit(Response.Error("Couldn't load Liked Songs")) },+ )+ }++ /** The signed-in account (name, avatar, plan). Spotify does not give the e-mail to the Web Player. */+ suspend fun getAccount(): Flow<Response<com.music.spotui.data.entity.AccountModel>> = flow {+ emit(Response.Loading())+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ runCatching { api.users.me() }.fold(+ onSuccess = { u ->+ emit(Response.Success(com.music.spotui.data.entity.AccountModel(+ name = u.name, email = "", imageUrl = cover(u.images), plan = if (u.premium) "Premium" else "Free",+ )))+ },+ onFailure = { Log.e("Api", "getAccount failed", it); emit(Response.Error(it.message ?: "error")) },+ )+ }++ /** Playlist header by id. */+ suspend fun getPlaylist(playlistId: String): Flow<Response<AlbumsModel>> = flow {+ emit(Response.Loading())+ if (playlistId.isBlank()) { emit(Response.Error("missing playlist id")); return@flow }+ if (!ready()) { emit(Response.Error(notSignedIn())); return@flow }+ runCatching { api.playlists.playlist("spotify:playlist:$playlistId") }.fold(+ onSuccess = { p ->+ emit(Response.Success(AlbumsModel(+ id = stableId("playlist:${p.uri}"), artists = p.owner.orEmpty(), coverUri = big(p.images),+ name = p.name, time = stripHtml(p.description), spotifyId = playlistId,+ )))+ },+ onFailure = { Log.e("Api", "getPlaylist failed", it); emit(Response.Error(it.message ?: "error")) },+ )+ }++ /** Playlist descriptions come as HTML: keep the text and link labels. */+ private fun stripHtml(raw: String?): String {+ if (raw.isNullOrBlank()) return ""+ return androidx.core.text.HtmlCompat.fromHtml(raw, androidx.core.text.HtmlCompat.FROM_HTML_MODE_LEGACY).toString().trim()+ }++ /** Among same-named albums, prefer the exact name by the requested artist. */+ private fun pickAlbum(candidates: List<Album>, albumName: String, artist: String): Album? {+ if (candidates.isEmpty()) return null+ if (artist.isBlank()) return candidates.firstOrNull { it.name.equals(albumName, ignoreCase = true) } ?: candidates.first()+ val want = artist.split(",").map { it.trim().lowercase() }.filter { it.isNotBlank() }+ fun artistMatches(a: Album) = a.artists.joinToString(" ") { it.name }.lowercase().let { names -> want.any { names.contains(it) } }+ val nameMatches = candidates.filter { it.name.equals(albumName, ignoreCase = true) }+ return nameMatches.firstOrNull(::artistMatches) ?: candidates.firstOrNull(::artistMatches) ?: nameMatches.firstOrNull() ?: candidates.first()+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/api/EditablePlaylists.kt b/base/app/src/main/java/com/music/spotui/data/api/EditablePlaylists.ktnew file mode 100644index 00000000..75340fbb--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/api/EditablePlaylists.kt@@ -0,0 +1,15 @@+package com.music.spotui.data.api++import app.myspoti.api.best+import app.myspoti.host.android.MyspotiRuntime++/** A playlist the user can add tracks to, for the "Add to playlist" pickers. */+data class EditablePlaylist(val id: String, val name: String, val trackCount: Int, val imageUrl: String?)++object EditablePlaylists {+ /** The user's own and collaborative playlists, in library order. */+ suspend fun load(): List<EditablePlaylist> =+ runCatching { MyspotiRuntime.api.playlists.editable() }.getOrDefault(emptyList()).map {+ EditablePlaylist(it.uri.substringAfterLast(':'), it.name, it.trackCount, it.images.best(160)?.url)+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/api/Features.kt b/base/app/src/main/java/com/music/spotui/data/api/Features.ktnew file mode 100644index 00000000..f8f046b3--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/api/Features.kt@@ -0,0 +1,7 @@+package com.music.spotui.data.api++/** Parts of the app switched off for now. */+object Features {+ /** Podcasts and audiobooks (shows, episodes, Your Episodes, playback speed). */+ const val PODCASTS = true+}diff --git a/base/app/src/main/java/com/music/spotui/data/api/LibraryFolders.kt b/base/app/src/main/java/com/music/spotui/data/api/LibraryFolders.ktnew file mode 100644index 00000000..f6e8ab89--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/api/LibraryFolders.kt@@ -0,0 +1,22 @@+package com.music.spotui.data.api++import app.myspoti.host.android.MyspotiRuntime++/**+ * Library folders: real Spotify folders, synced to the account (the public Web API has none).+ */+object LibraryFolders {+ /** Creates a folder at the top of the library; its uri, or null when Spotify refused. */+ suspend fun create(name: String): String? =+ runCatching { MyspotiRuntime.api.library.createFolder(name.trim()) }.getOrNull()?.also { changed() }++ /** Renames a folder; false when Spotify refused. */+ suspend fun rename(uri: String, name: String): Boolean =+ runCatching { MyspotiRuntime.api.library.renameFolder(uri, name.trim()) }.isSuccess.also { if (it) changed() }++ /** The library changed: the next load must come from Spotify, not from the caches. */+ private fun changed() {+ Api.HomeCache.libraryRoot = null+ Api.HomeCache.folders.clear()+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/api/LyricTranslate.kt b/base/app/src/main/java/com/music/spotui/data/api/LyricTranslate.ktnew file mode 100644index 00000000..c3df7043--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/api/LyricTranslate.kt@@ -0,0 +1,81 @@+package com.music.spotui.data.api++import android.util.Log+import org.json.JSONArray+import java.net.HttpURLConnection+import java.net.URL+import java.net.URLEncoder++/** Translates lyric lines in one request through Google's public endpoint. */+object LyricTranslate {+ private const val TAG = "LyricTranslate"++ data class Result(val lines: List<String>, val sourceLanguage: String?)++ fun detectLanguage(lines: List<String>, targetLang: String): String? {+ val sample = lines.asSequence()+ .map { it.trim() }+ .filter { it.isNotEmpty() && it != "♪" }+ .take(3)+ .joinToString("\n")+ if (sample.isBlank()) return null+ return translateText(sample, targetLang)?.sourceLanguage+ }++ fun translateLines(lines: List<String>, targetLang: String): Result? {+ if (lines.isEmpty()) return Result(emptyList(), null)++ val idx = ArrayList<Int>()+ val payload = ArrayList<String>()+ lines.forEachIndexed { i, line ->+ val t = line.trim()+ if (t.isNotEmpty() && t != "♪") {+ idx.add(i)+ payload.add(t)+ }+ }+ if (payload.isEmpty()) return Result(lines.map { "" }, null)++ val translated = translateText(payload.joinToString("\n"), targetLang) ?: return null+ val parts = translated.text.split("\n")+ val out = MutableList(lines.size) { "" }+ idx.forEachIndexed { j, lineIdx ->+ out[lineIdx] = parts.getOrElse(j) { payload[j] }.trim()+ }+ return Result(out, translated.sourceLanguage)+ }++ private data class Response(val text: String, val sourceLanguage: String?)++ private fun translateText(text: String, targetLang: String): Response? = runCatching {+ com.music.spotui.data.DataSaver.check()+ val q = URLEncoder.encode(text, "UTF-8")+ val tl = URLEncoder.encode(targetLang, "UTF-8")+ val conn = (URL(+ "https://translate.googleapis.com/translate_a/single?client=gtx&sl=auto&tl=$tl&dt=t&q=$q"+ ).openConnection() as HttpURLConnection).apply {+ connectTimeout = 12_000+ readTimeout = 12_000+ setRequestProperty("User-Agent", "Mozilla/5.0")+ }+ try {+ if (conn.responseCode !in 200..299) return null+ val responseBody = conn.inputStream.bufferedReader().use { it.readText() }+ val root = JSONArray(responseBody)+ val chunks = root.optJSONArray(0)+ ?: return null+ val translated = buildString {+ for (i in 0 until chunks.length()) {+ val piece = chunks.optJSONArray(i)?.optString(0) ?: continue+ append(piece)+ }+ }.ifBlank { return null }+ Response(translated, root.optString(2).ifBlank { null })+ } finally {+ conn.disconnect()+ }+ }.getOrElse {+ Log.e(TAG, "translate failed", it)+ null+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/api/LyricsApi.kt b/base/app/src/main/java/com/music/spotui/data/api/LyricsApi.ktnew file mode 100644index 00000000..18d09616--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/api/LyricsApi.kt@@ -0,0 +1,353 @@+package com.music.spotui.data.api++import android.util.Log+import com.music.spotui.data.entity.LyricLine+import com.music.spotui.data.entity.LyricWord+import com.music.spotui.data.entity.Lyrics+import com.music.spotui.data.entity.LyricsColors+import kotlinx.coroutines.async+import kotlinx.coroutines.coroutineScope+import kotlinx.coroutines.launch+import org.json.JSONArray+import org.json.JSONObject+import java.net.HttpURLConnection+import java.net.URL+import java.net.URLEncoder++/**+ * Lyrics resolver, in the order of the spec (SPEC-V1 §5), with the provider map of+ * LiriQo / Syncanto (MIT, AlFarrizi-Studio / alfzcore) as reference:+ *+ * 1. Spotify's own color-lyrics, by track id: exactly what the official app shows,+ * with its colours and credits.+ * 2. LRCLIB (lrclib.net, open API for third-party apps), line-synced or plain.+ * 3. Opt-in ("sources supplémentaires"): LyricsPlus (Apple Music word-synced lyrics),+ * NetEase Cloud Music (line-synced LRC) and Genius (plain text). Off by default.+ *+ * Fallback results are only kept when title, artist and length match the track.+ * LRCLIB asks clients to send a descriptive User-Agent; we oblige.+ */+object LyricsApi {+ private const val LRCLIB = "https://lrclib.net/api"+ private const val UA = "Myspoti (https://github.com/)"+ private val LYRICSPLUS = listOf(+ "https://lyricsplus.binimum.org",+ "https://lyricsplus.atomix.one",+ "https://lyricsplus.prjktla.my.id",+ )++ /** What the resolver needs to know about a track. */+ data class Track(+ val trackId: String,+ val title: String,+ val artist: String,+ val album: String,+ val durationMs: Long,+ val coverUrl: String = "",+ ) {+ val key: String get() = trackId.ifBlank { "${title.lowercase()}|${artist.substringBefore(",").trim().lowercase()}" }+ }++ // Cache by track: re-opening the lyrics (card + full screen ask for the same+ // track) is instant. A miss is cached too, but only for MISS_RETRY_MS — a+ // "not found" is often just a timeout, not a fact.+ private class Miss(val at: Long = System.currentTimeMillis())+ private const val MISS_RETRY_MS = 120_000L+ private val cache = java.util.concurrent.ConcurrentHashMap<String, Any>() // Lyrics | Miss+ private val inFlight = java.util.concurrent.ConcurrentHashMap<String, kotlinx.coroutines.Deferred<Lyrics?>>()+ private val scope =+ kotlinx.coroutines.CoroutineScope(kotlinx.coroutines.SupervisorJob() + kotlinx.coroutines.Dispatchers.IO)++ /** Set by the settings: also ask the word-synced Apple Music mirrors. */+ @Volatile var extraSources: Boolean = false++ fun cached(track: Track): Lyrics? = cache[track.key] as? Lyrics++ /** Warm the cache in the background (current track and the next one). */+ fun prefetch(track: Track) {+ if (track.title.isBlank() && track.trackId.isBlank()) return+ val c = cache[track.key]+ if (c is Lyrics) return+ if (c is Miss && System.currentTimeMillis() - c.at < MISS_RETRY_MS) return+ if (inFlight.containsKey(track.key)) return+ scope.launch { runCatching { fetch(track) } }+ }++ fun forget(track: Track) { cache.remove(track.key) }++ suspend fun fetch(track: Track): Lyrics? {+ when (val c = cache[track.key]) {+ is Lyrics -> return c+ is Miss -> if (System.currentTimeMillis() - c.at < MISS_RETRY_MS) return null+ }+ // One request per track even when the card and the full screen ask together.+ val job = synchronized(inFlight) {+ inFlight[track.key] ?: scope.async(start = kotlinx.coroutines.CoroutineStart.LAZY) {+ resolve(track)+ }.also { created ->+ inFlight[track.key] = created+ created.invokeOnCompletion { inFlight.remove(track.key, created) }+ created.start()+ }+ }+ // A cancelled card only stops waiting; the shared request owns cleanup.+ return job.await()+ }++ private suspend fun resolve(track: Track): Lyrics? {+ val result = fromSpotify(track) ?: coroutineScope {+ val title = cleanTitle(track.title)+ val artist = track.artist.substringBefore(",").trim()+ val durationSec = (track.durationMs / 1000).toInt()+ val extra = if (extraSources) async { fromLyricsPlus(title, artist, durationSec) } else null+ val netease = if (extraSources) async { fromNetEase(title, artist, durationSec) } else null+ val genius = if (extraSources) async { fromGenius(title, artist) } else null+ val exact = async { lrclibGet(title, artist, track.album, durationSec) }+ val fuzzy = async { lrclibSearch("$LRCLIB/search?track_name=${enc(title)}&artist_name=${enc(artist)}", title, artist, durationSec) }+ val lrclib = exact.await() ?: fuzzy.await()+ ?: lrclibSearch("$LRCLIB/search?track_name=${enc(title)}", title, artist, durationSec)+ val word = extra?.await()+ val ne = netease?.await()+ // Word-synced beats line-synced beats plain.+ when {+ word != null && word.wordSynced -> word+ lrclib != null && lrclib.synced -> lrclib+ word != null && word.synced -> word+ ne != null && ne.synced -> ne+ else -> lrclib ?: word ?: ne ?: genius?.await()+ }+ }+ cache[track.key] = result ?: Miss()+ Log.d("LyricsApi", "${track.title}: ${result?.let { "${it.lines.size} lines from ${it.provider}, synced=${it.synced}, words=${it.wordSynced}" } ?: "none"}")+ return result+ }++ // ── 1. Spotify color-lyrics ──+ private suspend fun fromSpotify(track: Track): Lyrics? {+ if (track.trackId.isBlank()) return null+ val sp = runCatching { app.myspoti.host.android.MyspotiRuntime.api.extras.lyrics("spotify:track:${track.trackId}") }+ .onFailure { Log.d("LyricsApi", "spotify lyrics miss for ${track.trackId}: ${it.message}") }+ .getOrNull() ?: return null+ if (sp.lines.isEmpty()) return null+ val bg = sp.background+ val text = sp.text+ val hi = sp.highlight+ return Lyrics(+ lines = sp.lines.map { l -> LyricLine(l.startMs, l.text, l.words?.map { w -> LyricWord(w.startMs, w.startMs, w.text) }) },+ synced = sp.synced,+ language = sp.language,+ provider = sp.provider ?: "Spotify",+ colors = if (bg != null && text != null && hi != null) LyricsColors(bg, text, hi) else null,+ )+ }++ // ── 4. NetEase Cloud Music (line-synced LRC) ──+ private fun fromNetEase(title: String, artist: String, durationSec: Int): Lyrics? {+ val search = httpGet("https://music.163.com/api/search/get?s=${enc("$title $artist")}&type=1&limit=6", timeoutMs = 6000)+ ?.let { runCatching { JSONObject(it) }.getOrNull() } ?: return null+ val songs = search.optJSONObject("result")?.optJSONArray("songs") ?: return null+ for (i in 0 until songs.length()) {+ val song = songs.optJSONObject(i) ?: continue+ val songArtist = song.optJSONArray("artists")?.optJSONObject(0)?.optString("name").orEmpty()+ if (!isPlausibleMatch(song.optString("name"), songArtist, (song.optLong("duration") / 1000).toInt(), title, artist, durationSec)) continue+ val o = httpGet("https://music.163.com/api/song/lyric?id=${song.optLong("id")}&lv=1&kv=1&tv=-1", timeoutMs = 6000)+ ?.let { runCatching { JSONObject(it) }.getOrNull() } ?: continue+ val lrc = o.optJSONObject("lrc")?.optString("lyric").orEmpty()+ // Credit lines ("作词 : …") come first in NetEase LRC.+ val lines = parseLrc(lrc).filter { it.text.isNotBlank() && !it.text.contains(" : ") }+ if (lines.isEmpty()) continue+ return Lyrics(lines = lines, synced = lines.any { it.timeMs > 0 }, provider = "NetEase Cloud Music")+ }+ return null+ }++ // ── 5. Genius (plain text from the song page) ──+ private fun fromGenius(title: String, artist: String): Lyrics? {+ val search = httpGet("https://genius.com/api/search/song?per_page=5&q=${enc("$title $artist")}", timeoutMs = 6000)+ ?.let { runCatching { JSONObject(it) }.getOrNull() } ?: return null+ val hits = search.optJSONObject("response")?.optJSONArray("sections")?.optJSONObject(0)?.optJSONArray("hits") ?: return null+ for (i in 0 until hits.length()) {+ val r = hits.optJSONObject(i)?.optJSONObject("result") ?: continue+ if (!isPlausibleMatch(r.optString("title"), r.optString("artist_names"), 0, title, artist, 0)) continue+ val html = httpGet(r.optString("url"), timeoutMs = 8000) ?: continue+ val text = geniusText(html) ?: continue+ val lines = text.lines().map { it.trim() }.filter { it.isNotEmpty() && !(it.startsWith("[") && it.endsWith("]")) }+ if (lines.isEmpty()) continue+ return Lyrics(lines = lines.map { LyricLine(0, it) }, synced = false, provider = "Genius")+ }+ return null+ }++ private val geniusContainer = Regex("<div[^>]*data-lyrics-container=\"true\"[^>]*>", RegexOption.IGNORE_CASE)++ /** The lyrics containers of a Genius song page, as plain text (nested divs balanced). */+ internal fun geniusText(html: String): String? {+ val parts = geniusContainer.findAll(html).mapNotNull { m ->+ var depth = 1+ var i = m.range.last + 1+ val start = i+ while (i < html.length && depth > 0) {+ when {+ html.startsWith("<div", i, ignoreCase = true) -> depth+++ html.startsWith("</div", i, ignoreCase = true) -> { depth--; if (depth == 0) return@mapNotNull html.substring(start, i) }+ }+ i+++ }+ null+ }.toList()+ if (parts.isEmpty()) return null+ return parts.joinToString("\n") { part ->+ androidx.core.text.HtmlCompat.fromHtml(part.replace(Regex("<br\\s*/?>", RegexOption.IGNORE_CASE), "\n"), androidx.core.text.HtmlCompat.FROM_HTML_MODE_LEGACY)+ .toString()+ }.trim().takeIf { it.isNotEmpty() }+ }++ // ── 2. LRCLIB ──+ private fun lrclibGet(title: String, artist: String, album: String, durationSec: Int): Lyrics? {+ val url = buildString {+ append("$LRCLIB/get?track_name=").append(enc(title))+ append("&artist_name=").append(enc(artist))+ if (album.isNotBlank()) append("&album_name=").append(enc(album))+ if (durationSec > 0) append("&duration=").append(durationSec)+ }+ val o = httpGet(url)?.let { runCatching { JSONObject(it) }.getOrNull() } ?: return null+ if (!isPlausibleMatch(o.optString("trackName"), o.optString("artistName"), o.optInt("duration"), title, artist, durationSec)) return null+ return parseLrclib(o)+ }++ private fun lrclibSearch(url: String, title: String, artist: String, durationSec: Int): Lyrics? {+ val arr = httpGet(url)?.let { runCatching { JSONArray(it) }.getOrNull() } ?: return null+ // Of the plausible candidates, prefer synced lyrics, then the closest duration.+ var best: JSONObject? = null+ var bestScore = Long.MAX_VALUE+ for (i in 0 until arr.length()) {+ val o = arr.optJSONObject(i) ?: continue+ val dur = o.optInt("duration", 0)+ if (!isPlausibleMatch(o.optString("trackName"), o.optString("artistName"), dur, title, artist, durationSec)) continue+ val hasSynced = o.optString("syncedLyrics").isNotBlank() && !o.isNull("syncedLyrics")+ val diff = if (durationSec > 0 && dur > 0) kotlin.math.abs(dur - durationSec).toLong() else 0L+ val score = diff + (if (hasSynced) 0 else 100_000)+ if (score < bestScore) { bestScore = score; best = o }+ }+ return best?.let { parseLrclib(it) }+ }++ private fun parseLrclib(o: JSONObject): Lyrics? {+ val synced = o.optString("syncedLyrics").takeIf { it.isNotBlank() && !o.isNull("syncedLyrics") }+ if (synced != null) {+ val lines = parseLrc(synced)+ if (lines.isNotEmpty()) return Lyrics(lines, synced = true, provider = "LRCLIB")+ }+ val plain = o.optString("plainLyrics").takeIf { it.isNotBlank() && !o.isNull("plainLyrics") } ?: return null+ return Lyrics(plain.split("\n").map { LyricLine(0L, it) }, synced = false, provider = "LRCLIB")+ }++ // ── 3. LyricsPlus (Apple Music TTML as JSON, word / syllable timing) ──+ private fun fromLyricsPlus(title: String, artist: String, durationSec: Int): Lyrics? {+ for (server in LYRICSPLUS) {+ val url = "$server/v2/lyrics/get?title=${enc(title)}&artist=${enc(artist)}" ++ (if (durationSec > 0) "&duration=$durationSec" else "")+ val o = httpGet(url, timeoutMs = 6000)?.let { runCatching { JSONObject(it) }.getOrNull() } ?: continue+ val meta = o.optJSONObject("metadata")+ val gotTitle = meta?.optString("title").orEmpty().ifBlank { o.optString("trackName") }+ if (gotTitle.isNotBlank() && !overlaps(matchKey(cleanTitle(gotTitle)), matchKey(title))) continue+ val arr = o.optJSONArray("lyrics") ?: continue+ val lines = ArrayList<LyricLine>()+ for (i in 0 until arr.length()) {+ val l = arr.optJSONObject(i) ?: continue+ val syl = l.optJSONArray("syllabus")+ val words = if (syl != null && syl.length() > 0) {+ (0 until syl.length()).mapNotNull { j ->+ val w = syl.optJSONObject(j) ?: return@mapNotNull null+ if (w.optBoolean("isBackground")) return@mapNotNull null+ val t = w.optLong("time")+ LyricWord(t, t + w.optLong("duration"), w.optString("text"))+ }.takeIf { it.isNotEmpty() }+ } else null+ val text = words?.joinToString("") { it.text }?.trim() ?: l.optString("text").trim()+ if (text.isEmpty()) continue+ lines.add(LyricLine(l.optLong("time"), text, words))+ }+ if (lines.isEmpty()) continue+ val synced = o.optString("type") != "plain" && lines.any { it.timeMs > 0 }+ return Lyrics(+ lines = lines,+ synced = synced,+ language = meta?.optString("language")?.takeIf { it.isNotBlank() },+ provider = "Apple Music (LyricsPlus)",+ )+ }+ return null+ }++ // ── Matching ──+ // Strip the noise Spotify puts in titles that other catalogues don't have:+ // "Song - 2011 Remaster", "Song (feat. X)", "Song [Bonus Track]".+ private val featTag = Regex("""\s*[(\[][^)\]]*(feat\.?|ft\.?|with )[^)\]]*[)\]]""", RegexOption.IGNORE_CASE)+ private val bracketTag = Regex("""\s*[(\[][^)\]]*(remaster|remastered|live|version|edit|mono|stereo|deluxe|bonus)[^)\]]*[)\]]""", RegexOption.IGNORE_CASE)+ private fun cleanTitle(title: String) =+ title.substringBefore(" - ").replace(featTag, "").replace(bracketTag, "").trim()++ private fun matchKey(s: String) = s.lowercase().filter { it.isLetterOrDigit() }+ // Exact normalized identity is conservative: ambiguous fallbacks are rejected.+ private fun overlaps(a: String, b: String) = a.isNotEmpty() && a == b++ /**+ * Fallback hits are only used when they are the same song: same artist, same+ * title (either may carry extras), and a similar length when both are known.+ */+ internal fun isPlausibleMatch(+ candTitle: String, candArtist: String, candDurationSec: Int,+ title: String, artist: String, durationSec: Int,+ ): Boolean {+ if (!overlaps(matchKey(candArtist), matchKey(artist))) return false+ if (!overlaps(matchKey(cleanTitle(candTitle)), matchKey(title))) return false+ return durationSec <= 0 || candDurationSec <= 0 || kotlin.math.abs(candDurationSec - durationSec) <= 3+ }++ // LRC: each line is "[mm:ss.xx] text" (a line may carry multiple timestamps).+ private val lrcTag = Regex("""\[(\d{1,2}):(\d{2})(?:[.:](\d{1,3}))?]""")+ private fun parseLrc(lrc: String): List<LyricLine> {+ val out = ArrayList<LyricLine>()+ for (raw in lrc.split("\n")) {+ val tags = lrcTag.findAll(raw).toList()+ if (tags.isEmpty()) continue+ val text = raw.substring(tags.last().range.last + 1).trim().ifEmpty { "♪" }+ for (m in tags) {+ val frac = m.groupValues[3]+ val ms = when (frac.length) {+ 0 -> 0L+ 1 -> frac.toLong() * 100+ 2 -> frac.toLong() * 10+ else -> frac.take(3).toLong()+ }+ out.add(LyricLine(m.groupValues[1].toLong() * 60_000 + m.groupValues[2].toLong() * 1_000 + ms, text))+ }+ }+ // Collapse runs of empty (instrumental) lines into one ♪.+ val sorted = out.sortedBy { it.timeMs }+ return sorted.filterIndexed { i, l -> !(l.text == "♪" && i > 0 && sorted[i - 1].text == "♪") }+ }++ private fun enc(s: String) = URLEncoder.encode(s, "UTF-8")++ private fun httpGet(spec: String, timeoutMs: Int = 5000): String? = runCatching {+ com.music.spotui.data.DataSaver.check()+ val conn = (URL(spec).openConnection() as HttpURLConnection).apply {+ requestMethod = "GET"+ connectTimeout = timeoutMs+ readTimeout = timeoutMs+ setRequestProperty("User-Agent", UA)+ setRequestProperty("Accept", "application/json, text/html;q=0.9, */*;q=0.8")+ }+ try {+ if (conn.responseCode != 200) {+ Log.d("LyricsApi", "HTTP ${conn.responseCode} for $spec")+ return null+ }+ conn.inputStream.bufferedReader().use { it.readText() }+ } finally {+ conn.disconnect()+ }+ }.getOrElse { Log.d("LyricsApi", "request failed: ${it.message}"); null }+}diff --git a/base/app/src/main/java/com/music/spotui/data/api/ProfileCache.kt b/base/app/src/main/java/com/music/spotui/data/api/ProfileCache.ktnew file mode 100644index 00000000..b4746e2c--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/api/ProfileCache.kt@@ -0,0 +1,50 @@+package com.music.spotui.data.api++import android.content.Context+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.setValue+import app.myspoti.api.best+import app.myspoti.host.android.MyspotiRuntime+import kotlinx.coroutines.flow.first+import kotlinx.coroutines.launch+import java.util.concurrent.atomic.AtomicBoolean++/** The signed-in profile (name, avatar, user id), fetched once per session. Compose state. */+object ProfileCache {+ var name by mutableStateOf<String?>(null)+ private set+ var imageUrl by mutableStateOf<String?>(null)+ private set+ /** Spotify user id (owner of the playlists the user can edit). */+ @Volatile var id: String? = null+ private set++ private val fetching = AtomicBoolean(false)+ private val generation = java.util.concurrent.atomic.AtomicLong()++ fun clearSession() {+ generation.incrementAndGet()+ name = null+ imageUrl = null+ id = null+ }++ fun ensure(context: Context) {+ if (name != null) return+ if (!fetching.compareAndSet(false, true)) return+ val requestGeneration = generation.get()+ MyspotiRuntime.scope.launch {+ try {+ MyspotiRuntime.api.ready.first { it }+ val me = runCatching { MyspotiRuntime.api.users.me() }.getOrNull() ?: return@launch+ if (generation.get() != requestGeneration) return@launch+ name = me.name+ imageUrl = me.images.best(160)?.url+ id = me.username.takeIf { it.isNotBlank() }+ } finally {+ fetching.set(false)+ }+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/api/Response.kt b/base/app/src/main/java/com/music/spotui/data/api/Response.ktnew file mode 100644index 00000000..ceaf55bc--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/api/Response.kt@@ -0,0 +1,8 @@+package com.music.spotui.data.api++sealed class Response<T> {++ class Loading<T> : Response<T>()+ data class Success<T>(val data: T) : Response<T>()+ data class Error<T>(val error : String) : Response<T>()+}\ No newline at end of filediff --git a/base/app/src/main/java/com/music/spotui/data/api/ScreenCache.kt b/base/app/src/main/java/com/music/spotui/data/api/ScreenCache.ktnew file mode 100644index 00000000..4a360177--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/api/ScreenCache.kt@@ -0,0 +1,60 @@+package com.music.spotui.data.api++import android.util.AtomicFile+import android.util.Log+import com.music.spotui.data.entity.HomeFeedModel+import com.music.spotui.data.entity.LibraryEntry+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.di.Graph+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.SupervisorJob+import kotlinx.coroutines.launch+import kotlinx.serialization.KSerializer+import kotlinx.serialization.builtins.ListSerializer+import kotlinx.serialization.json.Json+import java.io.File++/**+ * The last home feed, library and Liked Songs, kept on disk: after a restart the screens+ * show them at once, while the hidden Web Player is still starting, then refresh.+ * Private app storage; cleared on logout ([clear]).+ */+object ScreenCache {+ private const val TAG = "ScreenCache"+ // Bumped when a cached model changes shape.+ private const val DIR = "screen_cache1"+ private val json = Json { ignoreUnknownKeys = true; encodeDefaults = false }+ private val io = CoroutineScope(SupervisorJob() + Dispatchers.IO)+ private val dir: File by lazy { File(Graph.app.filesDir, DIR).also { it.mkdirs() } }++ val home = Entry("home", HomeFeedModel.serializer())+ val libraryRoot = Entry("library_root", ListSerializer(LibraryEntry.serializer()))+ val liked = Entry("liked", ListSerializer(SongsModel.serializer()))++ class Entry<T>(private val name: String, private val serializer: KSerializer<T>) {+ private val file get() = AtomicFile(File(dir, "$name.json"))++ /** Blocking read: call from a background thread. */+ fun read(): T? = runCatching {+ if (!file.baseFile.exists()) return null+ json.decodeFromString(serializer, file.readFully().decodeToString())+ }.onFailure { Log.w(TAG, "drop unreadable $name: ${it.javaClass.simpleName}"); runCatching { file.delete() } }.getOrNull()++ fun write(value: T) {+ io.launch {+ runCatching {+ val f = file+ val out = f.startWrite()+ try {+ out.write(json.encodeToString(serializer, value).encodeToByteArray())+ f.finishWrite(out)+ } catch (t: Throwable) { f.failWrite(out); throw t }+ }.onFailure { Log.w(TAG, "could not save $name: ${it.javaClass.simpleName}") }+ }+ }+ }++ /** Logout / account switch. */+ fun clear() { io.launch { dir.listFiles()?.forEach { it.delete() } } }+}diff --git a/base/app/src/main/java/com/music/spotui/data/api/SpotifySync.kt b/base/app/src/main/java/com/music/spotui/data/api/SpotifySync.ktnew file mode 100644index 00000000..74739558--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/api/SpotifySync.kt@@ -0,0 +1,97 @@+package com.music.spotui.data.api++import android.content.Context+import android.util.Log+import app.myspoti.host.android.MyspotiRuntime+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.SupervisorJob+import kotlinx.coroutines.launch+import java.util.concurrent.ConcurrentHashMap++/**+ * Library and playlist edits on the user's Spotify account. Failures are logged and+ * reported through the callbacks; the UI has already shown the change.+ */+object SpotifySync {+ private const val TAG = "SpotifySync"+ private val scope = CoroutineScope(SupervisorJob() + Dispatchers.Main)+ private val api get() = MyspotiRuntime.api++ fun setTrackSaved(context: Context, trackId: String, saved: Boolean) {+ if (trackId.isNotBlank()) com.music.spotui.di.SongPlayer.setTrackSaved(trackId, saved)+ }++ fun setAlbumSaved(context: Context, albumId: String, saved: Boolean) {+ if (albumId.isNotBlank()) com.music.spotui.di.SongPlayer.setSaved("spotify:album:$albumId", saved)+ }++ fun setArtistFollowed(context: Context, artistId: String, followed: Boolean) {+ if (artistId.isNotBlank()) com.music.spotui.di.SongPlayer.setSaved("spotify:artist:$artistId", followed)+ }++ /** Adds a track to one of the user's playlists. */+ fun addTrackToPlaylist(context: Context, playlistId: String, trackId: String, onDone: (Boolean) -> Unit = {}) {+ if (playlistId.isBlank() || trackId.isBlank()) { onDone(false); return }+ scope.launch {+ val ok = runCatching { api.playlists.addTracks("spotify:playlist:$playlistId", listOf("spotify:track:$trackId")) }+ .onFailure { Log.w(TAG, "add $trackId to $playlistId failed: ${it.message}") }.isSuccess+ if (ok) membershipCache[playlistId]?.add(trackId)+ onDone(ok)+ }+ }++ /** Removes every occurrence of a track from one of the user's playlists. */+ fun removeTrackFromPlaylist(context: Context, playlistId: String, trackId: String, onDone: (Boolean) -> Unit = {}) {+ if (playlistId.isBlank() || trackId.isBlank()) { onDone(false); return }+ scope.launch {+ val ok = runCatching {+ val uri = "spotify:playlist:$playlistId"+ val uids = allTracks(uri).filter { it.uri == "spotify:track:$trackId" }.mapNotNull { it.uid }+ check(uids.isNotEmpty()) { "track not in playlist" }+ api.playlists.removeTracks(uri, uids)+ }.onFailure { Log.w(TAG, "remove $trackId from $playlistId failed: ${it.message}") }.isSuccess+ if (ok) membershipCache[playlistId]?.remove(trackId)+ onDone(ok)+ }+ }++ /** Creates a playlist (and adds the track when given). */+ fun createPlaylistWithTrack(context: Context, name: String, trackId: String, onDone: (Boolean) -> Unit = {}) {+ if (name.isBlank()) { onDone(false); return }+ scope.launch {+ val ok = runCatching {+ val uri = api.playlists.create(name.trim())+ if (trackId.isNotBlank()) {+ api.playlists.addTracks(uri, listOf("spotify:track:$trackId"))+ membershipCache[uri.substringAfterLast(':')] = ConcurrentHashMap.newKeySet<String>().apply { add(trackId) }+ }+ }.onFailure { Log.w(TAG, "create playlist '$name' failed: ${it.message}") }.isSuccess+ Api.HomeCache.libraryRoot = null+ onDone(ok)+ }+ }++ private suspend fun allTracks(uri: String): List<app.myspoti.api.Track> {+ val out = ArrayList<app.myspoti.api.Track>()+ var offset = 0+ while (true) {+ val page = api.playlists.tracks(uri, offset, 100)+ out += page.items+ offset = page.nextOffset ?: break+ }+ return out+ }++ // Which playlists contain a track, cached per playlist for the session.+ private val membershipCache = ConcurrentHashMap<String, MutableSet<String>>()++ /** Track ids contained in [playlistId] (first call fetches, then cached). */+ suspend fun playlistTrackIds(context: Context, playlistId: String): Set<String> {+ membershipCache[playlistId]?.let { return it }+ val ids = runCatching { allTracks("spotify:playlist:$playlistId").map { it.uri.substringAfterLast(':') } }.getOrNull() ?: return emptySet()+ val set = ConcurrentHashMap.newKeySet<String>().apply { addAll(ids) }+ membershipCache[playlistId] = set+ return set+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/api/SupportReminder.kt b/base/app/src/main/java/com/music/spotui/data/api/SupportReminder.ktnew file mode 100644index 00000000..1cac2191--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/api/SupportReminder.kt@@ -0,0 +1,112 @@+package com.music.spotui.data.api++import android.content.ComponentName+import android.content.Context+import android.content.Intent+import android.content.pm.PackageManager+import android.net.Uri+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.setValue+import androidx.compose.ui.graphics.Color++/**+ * Donations and their thank-yous. Reminders: a day after first use, then every 2 weeks;+ * for someone who said they gave once, every 3 months with a thank-you; never for a+ * monthly supporter. "I've supported" is taken on trust (nothing is checked, nothing is+ * sold): it unlocks cosmetic thank-yous only (accent colour, app icon, badge).+ */+object SupportReminder {+ const val URL = "https://ko-fi.com/kotazo"+ const val FIRST_AFTER_MS = 24L * 3_600_000+ /**+ * Supporter perks ("I've supported", accent, icon, badge) are off until supports can+ * be checked: everyone is treated as a non-supporter and their entry points are hidden.+ */+ const val PERKS_ENABLED = false+ const val EVERY_MS = 14L * 24 * 3_600_000+ const val SUPPORTER_EVERY_MS = 90L * 24 * 3_600_000+ private const val PREFS = "support_reminder"++ enum class Level { NONE, ONCE, MONTHLY }++ /** A thank-you colour: the app's accent, and the app icon's bars. */+ enum class Accent(val key: String, val color: Color) {+ GREEN("green", Color(0xFF1ED760)),+ BLUE("blue", Color(0xFF509BF5)),+ PURPLE("purple", Color(0xFFAF7AF6)),+ PINK("pink", Color(0xFFF573A0)),+ ORANGE("orange", Color(0xFFFF9E3D)),+ }++ /** What the user said ("I've supported"), kept while perks are off. */+ private var storedLevel by mutableStateOf(Level.NONE)+ /** The supporter level in effect (NONE while perks are off). */+ val level: Level get() = if (PERKS_ENABLED) storedLevel else Level.NONE+ /** The accent chosen (applied only for supporters). */+ var accent by mutableStateOf(Accent.GREEN)+ private set+ var icon by mutableStateOf(Accent.GREEN)+ private set++ /** The colour the whole app uses for its accent (Spotify green unless a supporter chose another). */+ val accentColor: Color get() = if (level != Level.NONE) accent.color else Accent.GREEN.color++ /** When the next reminder is due. */+ fun nextAt(firstSeen: Long, lastShown: Long, level: Level, supportedAt: Long): Long = when (level) {+ Level.MONTHLY -> Long.MAX_VALUE+ Level.ONCE -> maxOf(lastShown, supportedAt) + SUPPORTER_EVERY_MS+ Level.NONE -> if (lastShown == 0L) firstSeen + FIRST_AFTER_MS else lastShown + EVERY_MS+ }++ private fun prefs(context: Context) = context.getSharedPreferences(PREFS, Context.MODE_PRIVATE)++ fun init(context: Context) {+ val p = prefs(context)+ storedLevel = runCatching { Level.valueOf(p.getString("level", "NONE")!!) }.getOrDefault(Level.NONE)+ accent = Accent.entries.firstOrNull { it.key == p.getString("accent", "green") } ?: Accent.GREEN+ icon = Accent.entries.firstOrNull { it.key == p.getString("icon", "green") } ?: Accent.GREEN+ }++ fun isDue(context: Context, now: Long = System.currentTimeMillis()): Boolean {+ val p = prefs(context)+ val firstSeen = p.getLong("first_seen", 0L).takeIf { it > 0 } ?: now.also { p.edit().putLong("first_seen", it).apply() }+ return now >= nextAt(firstSeen, p.getLong("last_shown", 0L), level, p.getLong("supported_at", 0L))+ }++ /** The reminder was answered (Ko-fi opened or "no thanks"). */+ fun shown(context: Context) = prefs(context).edit().putLong("last_shown", System.currentTimeMillis()).apply()++ /** "I've supported", on trust. */+ fun setLevel(context: Context, value: Level) {+ storedLevel = value+ prefs(context).edit().putString("level", value.name).putLong("supported_at", System.currentTimeMillis()).apply()+ }++ fun setAccent(context: Context, value: Accent) {+ accent = value+ prefs(context).edit().putString("accent", value.key).apply()+ }++ /**+ * Switches the launcher icon: one launcher alias per colour, only the chosen one+ * enabled (Android has no other way to change an app's icon).+ */+ fun setIcon(context: Context, value: Accent) {+ // The launcher aliases are commented out in the manifest while perks are off.+ if (!PERKS_ENABLED || value == icon) return+ val pm = context.packageManager+ for (a in Accent.entries) {+ val state = if (a == value) PackageManager.COMPONENT_ENABLED_STATE_ENABLED else PackageManager.COMPONENT_ENABLED_STATE_DISABLED+ pm.setComponentEnabledSetting(ComponentName(context, aliasOf(a)), state, PackageManager.DONT_KILL_APP)+ }+ icon = value+ prefs(context).edit().putString("icon", value.key).apply()+ }++ private fun aliasOf(a: Accent) = "app.myspoti.engine.ui.Launcher" + a.key.replaceFirstChar { it.uppercase() }++ fun open(context: Context) {+ context.startActivity(Intent(Intent.ACTION_VIEW, Uri.parse(URL)).addFlags(Intent.FLAG_ACTIVITY_NEW_TASK))+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/api/UpdateChecker.kt b/base/app/src/main/java/com/music/spotui/data/api/UpdateChecker.ktnew file mode 100644index 00000000..8c68f759--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/api/UpdateChecker.kt@@ -0,0 +1,95 @@+package com.music.spotui.data.api++import android.content.Context+import app.myspoti.engine.BuildConfig+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.withContext+import okhttp3.OkHttpClient+import okhttp3.Request+import org.json.JSONObject+import java.util.concurrent.TimeUnit++/**+ * New version check against the GitHub releases of [BuildConfig.UPDATE_REPO]+ * (set by the CI build; empty in local builds, which never check).+ * At most one request every 3 hours (releases can come several a day); the app only+ * opens the release page, never installs.+ */+object UpdateChecker {+ data class Release(val version: String, val pageUrl: String, val notes: String = "")++ private const val INTERVAL_MS = 3 * 3_600_000L+ private val http by lazy { OkHttpClient.Builder().callTimeout(10, TimeUnit.SECONDS).addInterceptor(com.music.spotui.data.DataSaver.interceptor).build() }++ suspend fun check(context: Context): Release? = withContext(Dispatchers.IO) {+ val repo = BuildConfig.UPDATE_REPO+ if (repo.isBlank()) return@withContext null+ val prefs = context.getSharedPreferences("updates", Context.MODE_PRIVATE)+ val now = System.currentTimeMillis()+ if (now - prefs.getLong("checked_at", 0L) < INTERVAL_MS) return@withContext pending(prefs)+ val release = runCatching {+ // Stable builds follow "latest", which never includes pre-releases. A beta build+ // also takes the newer betas, then the release they lead to.+ val url = if (isBeta) "https://api.github.com/repos/$repo/releases?per_page=10" else "https://api.github.com/repos/$repo/releases/latest"+ val request = Request.Builder().url(url).header("Accept", "application/vnd.github+json").build()+ http.newCall(request).execute().use { r ->+ if (!r.isSuccessful) return@runCatching null+ val text = r.body.string()+ val list = if (isBeta) org.json.JSONArray(text).let { a -> (0 until a.length()).map { a.getJSONObject(it) } } else listOf(JSONObject(text))+ list.filter { !it.optBoolean("draft") }+ .map { Release(it.getString("tag_name").removePrefix("v"), it.getString("html_url"), cleanNotes(it.optString("body"))) }+ .reduceOrNull { best, next -> if (isNewer(next.version, best.version)) next else best }+ }+ }.getOrNull()+ prefs.edit().putLong("checked_at", now)+ .putString("version", release?.version).putString("url", release?.pageUrl)+ .putString("notes", release?.notes).apply()+ pending(prefs)+ }++ /** The latest release known, if newer than this build and not dismissed. */+ private fun pending(prefs: android.content.SharedPreferences): Release? {+ val version = prefs.getString("version", null) ?: return null+ val url = prefs.getString("url", null) ?: return null+ if (prefs.getString("dismissed", null) == version) return null+ return Release(version, url, prefs.getString("notes", null).orEmpty()).takeIf { isNewer(version, BuildConfig.VERSION_NAME) }+ }++ fun dismiss(context: Context, release: Release) {+ context.getSharedPreferences("updates", Context.MODE_PRIVATE).edit()+ .putString("dismissed", release.version).apply()+ }++ /**+ * The release description as plain lines for the update window: the CHANGELOG section,+ * without GitHub's generated part, Markdown emphasis or link syntax.+ */+ fun cleanNotes(body: String): String = body+ .substringBefore("**Full Changelog**").substringBefore("## What's Changed")+ .lines().map { it.trimEnd() }+ .filter { it.isNotBlank() }+ .joinToString("\n") { line ->+ line.replace("**", "").replace(Regex("\\[([^]]+)]\\([^)]+\\)"), "$1")+ .replace(Regex("^(\\s*)[-*] "), "$1• ")+ }+ .trim()++ /** This build is a beta ("2.0.0-beta.1"). */+ val isBeta get() = BuildConfig.VERSION_NAME.contains("-beta")++ /**+ * "1.10.0" > "1.9.2". A release is newer than its betas ("2.0.0" > "2.0.0-beta.3"), and+ * betas compare by number ("2.0.0-beta.2" > "2.0.0-beta.1").+ */+ fun isNewer(candidate: String, current: String): Boolean {+ fun parts(v: String) = v.substringBefore('-').split('.').map { it.toIntOrNull() ?: 0 }+ val a = parts(candidate); val b = parts(current)+ for (i in 0 until maxOf(a.size, b.size)) {+ val x = a.getOrElse(i) { 0 }; val y = b.getOrElse(i) { 0 }+ if (x != y) return x > y+ }+ // Same version number: release > beta, then the higher beta.+ fun beta(v: String) = if (!v.contains('-')) Int.MAX_VALUE else Regex("(\\d+)$").find(v)?.value?.toIntOrNull() ?: 0+ return beta(candidate) > beta(current)+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/entity/AccountModel.kt b/base/app/src/main/java/com/music/spotui/data/entity/AccountModel.ktnew file mode 100644index 00000000..27fc2cce--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/entity/AccountModel.kt@@ -0,0 +1,9 @@+package com.music.spotui.data.entity++/** The logged-in Spotify account, shown in the Library settings menu. */+data class AccountModel(+ val name: String = "",+ val email: String = "",+ val imageUrl: String = "",+ val plan: String = "",+)diff --git a/base/app/src/main/java/com/music/spotui/data/entity/AlbumsModel.kt b/base/app/src/main/java/com/music/spotui/data/entity/AlbumsModel.ktnew file mode 100644index 00000000..429d914f--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/entity/AlbumsModel.kt@@ -0,0 +1,16 @@+package com.music.spotui.data.entity++data class AlbumsModel(+ val id : Int,+ val artists : String,+ val coverUri : String,+ val name : String,+ val time : String,+ // Release kind from Spotify: "album", "single", "compilation"... Empty when unknown.+ val type : String = "",+ // Real Spotify album id (empty when unknown) — the page is loaded by id.+ val spotifyId : String = "",+){+ constructor() : this( -1,"" ,"" ,"", "")+}diff --git a/base/app/src/main/java/com/music/spotui/data/entity/ArtistOverviewModel.kt b/base/app/src/main/java/com/music/spotui/data/entity/ArtistOverviewModel.ktnew file mode 100644index 00000000..af128f50--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/entity/ArtistOverviewModel.kt@@ -0,0 +1,25 @@+package com.music.spotui.data.entity++/**+ * Rich artist page data (Spotify-style): header art, monthly listeners, bio,+ * popular tracks with play counts, discography and related artists. Backed by+ * Spotify's queryArtistOverview GQL endpoint.+ */+data class ArtistOverviewModel(+ val id: String = "",+ val name: String = "",+ val verified: Boolean = false,+ val monthlyListeners: Long? = null,+ val biography: String? = null,+ val headerImage: String = "",+ val avatarImage: String = "",+ val topTracks: List<ArtistTrackUi> = emptyList(),+ val popularReleases: List<AlbumsModel> = emptyList(),+ val appearsOn: List<AlbumsModel> = emptyList(),+ val relatedArtists: List<ArtistsModel> = emptyList(),+)++data class ArtistTrackUi(+ val song: SongsModel,+ val playcount: Long? = null,+)diff --git a/base/app/src/main/java/com/music/spotui/data/entity/ArtistsModel.kt b/base/app/src/main/java/com/music/spotui/data/entity/ArtistsModel.ktnew file mode 100644index 00000000..986748ea--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/entity/ArtistsModel.kt@@ -0,0 +1,12 @@+package com.music.spotui.data.entity++data class ArtistsModel(+ val name : String,+ val coverUri : String,+ // Real Spotify artist id — open the EXACT artist (so "RAM" doesn't resolve to+ // "Rammstein" via a fuzzy name search). Empty when unknown.+ val id : String = "",+){+ constructor() : this("", "", "")+}diff --git a/base/app/src/main/java/com/music/spotui/data/entity/ContextPageModel.kt b/base/app/src/main/java/com/music/spotui/data/entity/ContextPageModel.ktnew file mode 100644index 00000000..63ea72b4--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/entity/ContextPageModel.kt@@ -0,0 +1,17 @@+package com.music.spotui.data.entity++/** Everything the album / playlist page shows, loaded by Spotify id. */+data class ContextPageModel(+ val uri: String,+ val type: String, // "album" | "playlist"+ val name: String,+ val coverUri: String,+ val description: String = "",+ val ownerName: String = "",+ val ownerAvatar: String = "",+ val ownerUri: String = "",+ val metaLine: String = "",+ val explicit: Boolean = false,+ val tracks: List<SongsModel> = emptyList(),+ val complete: Boolean = true,+)diff --git a/base/app/src/main/java/com/music/spotui/data/entity/HomeFeedModel.kt b/base/app/src/main/java/com/music/spotui/data/entity/HomeFeedModel.ktnew file mode 100644index 00000000..caa67f30--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/entity/HomeFeedModel.kt@@ -0,0 +1,58 @@+package com.music.spotui.data.entity++/**+ * Personalized Spotify home feed (the `home` GQL operation): a greeting plus an+ * ordered list of titled sections ("Your top mixes", "Jump back in", "Your+ * favorite artists", …), each holding albums / artists / playlists.+ */+data class HomeFeedModel(+ val greeting: String = "",+ val sections: List<HomeSection> = emptyList(),+)++data class HomeSection(+ val title: String,+ val items: List<HomeItem>,+)++sealed class HomeItem {+ abstract val name: String+ abstract val imageUrl: String++ @kotlinx.serialization.Serializable+ data class Album(+ val id: String = "",+ override val name: String,+ override val imageUrl: String,+ val subtitle: String,+ val artists: String = "",+ ) : HomeItem()++ @kotlinx.serialization.Serializable+ data class Artist(+ override val name: String,+ override val imageUrl: String,+ val id: String = "",+ ) : HomeItem()++ /** Podcast show / audiobook, or a single episode ([isEpisode]). */+ @kotlinx.serialization.Serializable+ data class Show(+ val id: String,+ override val name: String,+ override val imageUrl: String,+ val subtitle: String,+ val isEpisode: Boolean,+ ) : HomeItem()++ @kotlinx.serialization.Serializable+ data class Playlist(+ override val name: String,+ override val imageUrl: String,+ val subtitle: String,+ val id: String = "",+ ) : HomeItem()+}diff --git a/base/app/src/main/java/com/music/spotui/data/entity/LibraryEntry.kt b/base/app/src/main/java/com/music/spotui/data/entity/LibraryEntry.ktnew file mode 100644index 00000000..2ce0fa75--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/entity/LibraryEntry.kt@@ -0,0 +1,22 @@+package com.music.spotui.data.entity++/**+ * A single row in "Your Library": either a saved album or a saved/followed+ * playlist. [spotifyId] is the Spotify string id used to open the detail screen+ * (playlistRoute for playlists, name-based albumRoute for albums).+ */+data class LibraryEntry(+ val spotifyId: String,+ val name: String,+ val subtitle: String,+ val coverUri: String,+ val isPlaylist: Boolean,+ val artists: String = "",+ /** A Spotify library folder (its full `spotify:user:…:folder:…` uri); empty otherwise. */+ val folderUri: String = "",+ /** Playlists and folders inside a folder. */+ val childCount: Int = 0,+) {+ val isFolder: Boolean get() = folderUri.isNotBlank()+}diff --git a/base/app/src/main/java/com/music/spotui/data/entity/Lyrics.kt b/base/app/src/main/java/com/music/spotui/data/entity/Lyrics.ktnew file mode 100644index 00000000..35121711--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/entity/Lyrics.kt@@ -0,0 +1,44 @@+package com.music.spotui.data.entity++/** One word (or syllable) of word-synced lyrics; [endMs] 0 = until the next word. */+data class LyricWord(+ val startMs: Long,+ val endMs: Long,+ val text: String,+)++/**+ * One line of lyrics. [timeMs] is the start time in ms (0 for unsynced lyrics);+ * [words] is set only when the source is word-synced (karaoke-style highlight).+ */+data class LyricLine(+ val timeMs: Long,+ val text: String,+ val words: List<LyricWord>? = null,+)++/** Spotify's per-track lyrics colours (color-lyrics `colors`), ARGB ints. */+data class LyricsColors(+ val background: Int,+ val text: Int,+ val highlight: Int,+)++/**+ * Lyrics for a track. When [synced] is true [lines] carry real timestamps and the+ * UI highlights/scrolls in time with playback; otherwise [lines] are just the+ * plain lyric lines (timeMs = 0) shown statically.+ */+data class Lyrics(+ val lines: List<LyricLine>,+ val synced: Boolean,+ val language: String? = null,+ /** Who provides the text, as Spotify credits it ("Musixmatch"), or our source name. */+ val provider: String? = null,+ val colors: LyricsColors? = null,+ /** False when Spotify only gives a preview (Free cap): the card says "Aperçu des paroles". */+ val uncapped: Boolean = true,+) {+ val isEmpty: Boolean get() = lines.isEmpty()+ val wordSynced: Boolean get() = lines.any { it.words != null }+}diff --git a/base/app/src/main/java/com/music/spotui/data/entity/PodcastModel.kt b/base/app/src/main/java/com/music/spotui/data/entity/PodcastModel.ktnew file mode 100644index 00000000..c72d4294--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/entity/PodcastModel.kt@@ -0,0 +1,16 @@+package com.music.spotui.data.entity++/**+ * A podcast show (search result / show header). [id] is the RAW Spotify show id+ * so the detail screen can fetch its episodes. Episodes themselves are modelled+ * as [SongsModel] with url = "episode:<rawId>" so they flow through the existing+ * queue/player (SongPlayer routes that prefix to the web player's episode page).+ */+data class PodcastModel(+ val id: String,+ val name: String,+ val publisher: String,+ val coverUri: String,+) {+ constructor() : this("", "", "", "")+}diff --git a/base/app/src/main/java/com/music/spotui/data/entity/SearchResults.kt b/base/app/src/main/java/com/music/spotui/data/entity/SearchResults.ktnew file mode 100644index 00000000..adca136d--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/entity/SearchResults.kt@@ -0,0 +1,11 @@+package com.music.spotui.data.entity++/** Combined Spotify search results: tracks, albums, artists, podcasts + episodes. */+data class SearchResults(+ val songs: List<SongsModel> = emptyList(),+ val albums: List<AlbumsModel> = emptyList(),+ val artists: List<ArtistsModel> = emptyList(),+ val shows: List<PodcastModel> = emptyList(),+ val episodes: List<SongsModel> = emptyList(),+ val playlists: List<LibraryEntry> = emptyList(),+)diff --git a/base/app/src/main/java/com/music/spotui/data/entity/SongsModel.kt b/base/app/src/main/java/com/music/spotui/data/entity/SongsModel.ktnew file mode 100644index 00000000..91b7de6e--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/entity/SongsModel.kt@@ -0,0 +1,24 @@+package com.music.spotui.data.entity++data class SongsModel(+ val id : Int,+ val title : String,+ val album : String,+ val singer : String,+ val coverUri : String,+ val url : String,+ // Real Spotify track id (e.g. "3n3Ppam7vgaVa1iaRUc9Lp"), kept so playback can+ // seed Spotify's recommendations endpoint for autoplay radio. Empty when unknown.+ val spotifyTrackId : String = "",+ // Whether the Spotify track is the explicit version, so the YouTube fallback+ // can pick the matching (explicit vs clean) edit.+ val explicit : Boolean = false,+ // Track length in ms (from Spotify). Used to disambiguate the YouTube match:+ // a same-title-different-artist song almost always has a different duration.+ val durationMs : Int = 0,+ // Spotify album id of the track, when known (opens the album page by id).+ val albumId : String = "",+){+ constructor() : this(-1 ,"" ,"" ,"" ,"" ,"", "")+}diff --git a/base/app/src/main/java/com/music/spotui/data/local/LibraryOrder.kt b/base/app/src/main/java/com/music/spotui/data/local/LibraryOrder.ktnew file mode 100644index 00000000..e85b3da8--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/local/LibraryOrder.kt@@ -0,0 +1,95 @@+package com.music.spotui.data.local++import android.content.Context+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.setValue+import com.music.spotui.data.entity.LibraryEntry+import java.text.Collator++/**+ * How "Your Library" is sorted: the user's own order (Spotify's until they move+ * something), alphabetical, or by creator. The custom order is kept on the phone, one+ * list per level (the root, or a folder's uri). Pinned entries (Liked Songs, Local+ * Files, Downloaded) always stay on top, as in the official app.+ */+object LibraryOrder {+ enum class Sort { CUSTOM, ALPHABETICAL, CREATOR }++ const val ROOT = "root"+ private const val PREFS = "library_order"+ private const val KEY_SORT = "sort"+ private const val SEP = "\u001F"++ var sort by mutableStateOf(Sort.CUSTOM)+ private set+ /** Bumped on every change, so screens re-arrange. */+ var version by mutableStateOf(0)+ private set+ private var context: Context? = null++ fun init(c: Context) {+ context = c.applicationContext+ sort = runCatching { Sort.valueOf(prefs()?.getString(KEY_SORT, null) ?: "") }.getOrDefault(Sort.CUSTOM)+ }++ private fun prefs() = context?.getSharedPreferences(PREFS, Context.MODE_PRIVATE)++ fun choose(s: Sort) {+ sort = s+ prefs()?.edit()?.putString(KEY_SORT, s.name)?.apply()+ version+++ }++ fun custom(level: String): List<String> =+ prefs()?.getString("order:$level", null)?.split(SEP)?.filter { it.isNotEmpty() } ?: emptyList()++ /** The user moved something: [keys] is the level's new order, and the sort becomes custom. */+ fun saveCustom(level: String, keys: List<String>) {+ prefs()?.edit()?.putString("order:$level", keys.joinToString(SEP))?.apply()+ if (sort != Sort.CUSTOM) choose(Sort.CUSTOM) else version+++ }++ /** Back to Spotify's order, everywhere. */+ fun reset() {+ val p = prefs() ?: return+ p.edit().apply { p.all.keys.filter { it.startsWith("order:") }.forEach { remove(it) } }.apply()+ choose(Sort.CUSTOM)+ }++ fun key(e: LibraryEntry): String = e.folderUri.ifBlank { e.spotifyId }++ /** Who made it: the owner of a playlist, the artists of an album; folders have none. */+ fun creator(e: LibraryEntry): String = when {+ e.isFolder -> ""+ !e.isPlaylist -> e.artists.ifBlank { e.subtitle.substringAfter(" • ", "") }+ else -> e.subtitle.substringAfter(" • ", "")+ }++ /**+ * [entries] in the chosen order, the first [pinned] untouched. In the custom order,+ * entries never moved (new playlists) come first, in Spotify's order, as new+ * playlists do in the official app.+ */+ fun arrange(entries: List<LibraryEntry>, sort: Sort, saved: List<String>, pinned: Int): List<LibraryEntry> {+ val head = entries.take(pinned)+ val rest = entries.drop(pinned)+ val collator = Collator.getInstance().apply { strength = Collator.PRIMARY }+ val sorted = when (sort) {+ Sort.CUSTOM -> {+ if (saved.isEmpty()) rest+ else {+ val at = saved.withIndex().associate { it.value to it.index }+ rest.withIndex().sortedWith(compareBy({ at[key(it.value)] ?: -1 }, { it.index })).map { it.value }+ }+ }+ Sort.ALPHABETICAL -> rest.sortedWith { a, b -> collator.compare(a.name, b.name) }+ Sort.CREATOR -> rest.sortedWith(+ compareBy<LibraryEntry> { !it.isFolder }+ .then { a, b -> collator.compare(creator(a), creator(b)) }+ .then { a, b -> collator.compare(a.name, b.name) },+ )+ }+ return head + sorted+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/local/ListenHistory.kt b/base/app/src/main/java/com/music/spotui/data/local/ListenHistory.ktnew file mode 100644index 00000000..6b1fccd4--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/local/ListenHistory.kt@@ -0,0 +1,85 @@+package com.music.spotui.data.local++import android.content.Context+import org.json.JSONObject+import java.io.File++/**+ * Every listen on this phone, whatever the source (Spotify, downloads, local files), for the+ * in-app recap. Stays on the phone; nothing is reported to Spotify or anyone else.+ * A listen counts after 30 s, like most services.+ */+object ListenHistory {+ enum class Source { SPOTIFY, DOWNLOAD, LOCAL }++ data class Listen(+ val atMs: Long,+ val key: String,+ val title: String,+ val artist: String,+ val album: String,+ val cover: String,+ val playedMs: Long,+ val source: Source,+ )++ const val MIN_PLAYED_MS = 30_000L+ private var file: File? = null+ private val lock = Any()++ fun init(context: Context) {+ file = File(context.filesDir, "listen_history.jsonl")+ }++ fun record(listen: Listen) {+ if (listen.playedMs < MIN_PLAYED_MS || listen.title.isBlank()) return+ val f = file ?: return+ val line = JSONObject()+ .put("at", listen.atMs).put("key", listen.key).put("title", listen.title).put("artist", listen.artist)+ .put("album", listen.album).put("cover", listen.cover).put("ms", listen.playedMs).put("src", listen.source.name)+ .toString()+ synchronized(lock) { f.appendText(line + "\n") }+ }++ fun all(): List<Listen> = synchronized(lock) {+ val f = file?.takeIf { it.exists() } ?: return emptyList()+ f.readLines().mapNotNull { line ->+ runCatching {+ val o = JSONObject(line)+ Listen(o.getLong("at"), o.getString("key"), o.getString("title"), o.optString("artist"), o.optString("album"),+ o.optString("cover"), o.getLong("ms"), Source.valueOf(o.optString("src", "SPOTIFY")))+ }.getOrNull()+ }+ }++ fun clear() = synchronized(lock) { file?.delete() }++ data class Ranked(val name: String, val subtitle: String, val cover: String, val count: Int, val minutes: Long)++ data class Recap(+ val listens: Int,+ val minutes: Long,+ val bySource: Map<Source, Long>,+ val topTracks: List<Ranked>,+ val topArtists: List<Ranked>,+ val topAlbums: List<Ranked>,+ )++ /** Totals and top lists for listens since [sinceMs]. */+ fun recap(sinceMs: Long): Recap {+ val list = all().filter { it.atMs >= sinceMs }+ fun rank(group: (Listen) -> String, subtitle: (Listen) -> String) = list.groupBy(group)+ .filterKeys { it.isNotBlank() }+ .map { (name, l) -> Ranked(name, subtitle(l.first()), l.first().cover, l.size, l.sumOf { it.playedMs } / 60_000) }+ .sortedWith(compareByDescending<Ranked> { it.count }.thenByDescending { it.minutes })+ .take(10)+ return Recap(+ listens = list.size,+ minutes = list.sumOf { it.playedMs } / 60_000,+ bySource = list.groupBy { it.source }.mapValues { (_, l) -> l.sumOf { it.playedMs } / 60_000 },+ topTracks = rank({ it.title + "\u0000" + it.artist }, { it.artist }).map { it.copy(name = it.name.substringBefore('\u0000')) },+ topArtists = rank({ it.artist.substringBefore(",").trim() }, { "" }),+ topAlbums = rank({ it.album }, { it.artist }),+ )+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/local/LocalMusic.kt b/base/app/src/main/java/com/music/spotui/data/local/LocalMusic.ktnew file mode 100644index 00000000..ba9730f7--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/local/LocalMusic.kt@@ -0,0 +1,73 @@+package com.music.spotui.data.local++import android.Manifest+import android.content.ContentUris+import android.content.Context+import android.content.pm.PackageManager+import android.net.Uri+import android.os.Build+import android.provider.MediaStore+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.withContext++/** An audio file on this device (MediaStore), played by [com.music.spotui.di.LocalPlayer]. */+data class LocalTrack(+ val id: Long,+ val uri: Uri,+ val title: String,+ val artist: String,+ val album: String,+ val durationMs: Long,+ val artUri: Uri,+)++/** The device's music files, read through MediaStore (no file access beyond audio). */+object LocalMusic {+ /** Audio read permission for this Android version. */+ val permission: String =+ if (Build.VERSION.SDK_INT >= 33) Manifest.permission.READ_MEDIA_AUDIO else Manifest.permission.READ_EXTERNAL_STORAGE++ fun hasPermission(context: Context) =+ context.checkSelfPermission(permission) == PackageManager.PERMISSION_GRANTED++ @Volatile private var cache: List<LocalTrack>? = null++ suspend fun tracks(context: Context, refresh: Boolean = false): List<LocalTrack> = withContext(Dispatchers.IO) {+ if (!hasPermission(context)) return@withContext emptyList()+ cache?.takeIf { !refresh }?.let { return@withContext it }+ val collection = if (Build.VERSION.SDK_INT >= 29) MediaStore.Audio.Media.getContentUri(MediaStore.VOLUME_EXTERNAL)+ else MediaStore.Audio.Media.EXTERNAL_CONTENT_URI+ val projection = arrayOf(+ MediaStore.Audio.Media._ID, MediaStore.Audio.Media.TITLE, MediaStore.Audio.Media.ARTIST,+ MediaStore.Audio.Media.ALBUM, MediaStore.Audio.Media.DURATION, MediaStore.Audio.Media.ALBUM_ID,+ )+ val out = ArrayList<LocalTrack>()+ context.contentResolver.query(+ collection, projection,+ "${MediaStore.Audio.Media.IS_MUSIC} != 0 AND ${MediaStore.Audio.Media.DURATION} >= 30000",+ null, "${MediaStore.Audio.Media.TITLE} COLLATE NOCASE ASC",+ )?.use { c ->+ val iId = c.getColumnIndexOrThrow(MediaStore.Audio.Media._ID)+ val iTitle = c.getColumnIndexOrThrow(MediaStore.Audio.Media.TITLE)+ val iArtist = c.getColumnIndexOrThrow(MediaStore.Audio.Media.ARTIST)+ val iAlbum = c.getColumnIndexOrThrow(MediaStore.Audio.Media.ALBUM)+ val iDur = c.getColumnIndexOrThrow(MediaStore.Audio.Media.DURATION)+ val iAlbumId = c.getColumnIndexOrThrow(MediaStore.Audio.Media.ALBUM_ID)+ while (c.moveToNext()) {+ val id = c.getLong(iId)+ val artist = c.getString(iArtist)?.takeIf { it != MediaStore.UNKNOWN_STRING }.orEmpty()+ out += LocalTrack(+ id = id,+ uri = ContentUris.withAppendedId(collection, id),+ title = c.getString(iTitle).orEmpty(),+ artist = artist,+ album = c.getString(iAlbum).orEmpty(),+ durationMs = c.getLong(iDur),+ artUri = ContentUris.withAppendedId(Uri.parse("content://media/external/audio/albumart"), c.getLong(iAlbumId)),+ )+ }+ }+ cache = out+ out+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/local/LocalPlaylists.kt b/base/app/src/main/java/com/music/spotui/data/local/LocalPlaylists.ktnew file mode 100644index 00000000..cfd878bf--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/local/LocalPlaylists.kt@@ -0,0 +1,128 @@+package com.music.spotui.data.local++import android.content.Context+import android.net.Uri+import androidx.compose.runtime.mutableStateMapOf+import androidx.compose.runtime.snapshots.SnapshotStateMap+import org.json.JSONArray+import org.json.JSONObject+import java.io.File+import java.util.UUID++/** One occurrence of a phone file in a list (its own [key]: the same file can be there twice). */+data class LocalItem(+ val key: String,+ val uri: String,+ val title: String,+ val artist: String,+ val album: String,+ val durationMs: Long,+ val artUri: String,+) {+ fun toTrack() = LocalTrack(+ id = key.hashCode().toLong() and 0x7fffffffL,+ uri = Uri.parse(uri), title = title, artist = artist, album = album,+ durationMs = durationMs, artUri = Uri.parse(artUri),+ )++ companion object {+ fun of(t: LocalTrack) = LocalItem(+ key = UUID.randomUUID().toString(), uri = t.uri.toString(), title = t.title,+ artist = t.artist, album = t.album, durationMs = t.durationMs, artUri = t.artUri.toString(),+ )+ }+}++/** A playlist kept on this phone only (Spotify cannot hold phone files). */+data class LocalPlaylist(val id: String, val name: String, val items: List<LocalItem>, val createdAt: Long)++/**+ * Playlists of phone files, and phone files added to Spotify playlists ("Added on this+ * device"). Stored in the app's files; nothing is sent to Spotify, whose API does not+ * accept local files.+ */+object LocalPlaylists {+ private const val VERSION = 1+ private lateinit var file: File+ private val lock = Any()++ val playlists: SnapshotStateMap<String, LocalPlaylist> = mutableStateMapOf()+ /** Spotify playlist id → phone files added to it on this phone. */+ val additions: SnapshotStateMap<String, List<LocalItem>> = mutableStateMapOf()++ fun init(context: Context) {+ if (::file.isInitialized) return+ file = File(context.filesDir, "local_playlists.json")+ runCatching { read(file.readText()) }+ }++ /** Newest first. */+ fun list(): List<LocalPlaylist> = playlists.values.sortedByDescending { it.createdAt }++ fun create(name: String): LocalPlaylist {+ val p = LocalPlaylist(UUID.randomUUID().toString(), name.trim(), emptyList(), System.currentTimeMillis())+ update { playlists[p.id] = p }+ return p+ }++ fun rename(id: String, name: String) = update { playlists[id]?.let { playlists[id] = it.copy(name = name.trim()) } }+ fun delete(id: String) = update { playlists.remove(id) }++ fun add(id: String, track: LocalTrack) =+ update { playlists[id]?.let { playlists[id] = it.copy(items = it.items + LocalItem.of(track)) } }++ fun remove(id: String, key: String) =+ update { playlists[id]?.let { playlists[id] = it.copy(items = it.items.filterNot { i -> i.key == key }) } }++ fun addToSpotify(playlistId: String, track: LocalTrack) =+ update { additions[playlistId] = additions[playlistId].orEmpty() + LocalItem.of(track) }++ fun removeFromSpotify(playlistId: String, key: String) = update {+ val left = additions[playlistId].orEmpty().filterNot { it.key == key }+ if (left.isEmpty()) additions.remove(playlistId) else additions[playlistId] = left+ }++ private fun update(change: () -> Unit) {+ synchronized(lock) {+ change()+ if (::file.isInitialized) {+ val tmp = File(file.parentFile, file.name + ".tmp")+ tmp.writeText(write())+ tmp.renameTo(file)+ }+ }+ }++ // ── JSON ──++ private fun itemJson(i: LocalItem) = JSONObject().put("key", i.key).put("uri", i.uri).put("title", i.title)+ .put("artist", i.artist).put("album", i.album).put("duration", i.durationMs).put("art", i.artUri)++ private fun itemOf(o: JSONObject) = LocalItem(o.getString("key"), o.getString("uri"), o.optString("title"),+ o.optString("artist"), o.optString("album"), o.optLong("duration"), o.optString("art"))++ private fun items(a: JSONArray?) = (0 until (a?.length() ?: 0)).mapNotNull { runCatching { itemOf(a!!.getJSONObject(it)) }.getOrNull() }++ internal fun write(): String {+ val lists = JSONArray()+ playlists.values.forEach { p ->+ lists.put(JSONObject().put("id", p.id).put("name", p.name).put("created", p.createdAt)+ .put("items", JSONArray().apply { p.items.forEach { put(itemJson(it)) } }))+ }+ val adds = JSONObject()+ additions.forEach { (id, list) -> adds.put(id, JSONArray().apply { list.forEach { put(itemJson(it)) } }) }+ return JSONObject().put("version", VERSION).put("playlists", lists).put("additions", adds).toString()+ }++ internal fun read(text: String) {+ val o = JSONObject(text)+ if (o.optInt("version") != VERSION) return+ val lists = o.optJSONArray("playlists") ?: JSONArray()+ for (i in 0 until lists.length()) {+ val p = lists.getJSONObject(i)+ playlists[p.getString("id")] = LocalPlaylist(p.getString("id"), p.optString("name"), items(p.optJSONArray("items")), p.optLong("created"))+ }+ val adds = o.optJSONObject("additions") ?: JSONObject()+ adds.keys().forEach { id -> items(adds.optJSONArray(id)).takeIf { it.isNotEmpty() }?.let { additions[id] = it } }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/offline/OfflineCollections.kt b/base/app/src/main/java/com/music/spotui/data/offline/OfflineCollections.ktnew file mode 100644index 00000000..6fc659d2--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/offline/OfflineCollections.kt@@ -0,0 +1,178 @@+package com.music.spotui.data.offline++import android.content.Context+import android.util.Log+import androidx.compose.runtime.mutableStateMapOf+import androidx.compose.runtime.snapshots.SnapshotStateMap+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.ContextPageModel+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.di.Graph+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.SupervisorJob+import kotlinx.coroutines.delay+import kotlinx.coroutines.flow.first+import kotlinx.coroutines.launch+import kotlinx.coroutines.withContext+import kotlinx.coroutines.withTimeoutOrNull+import org.json.JSONArray+import org.json.JSONObject+import java.io.File++/** A playlist, album or Liked Songs the user downloaded as a whole. */+data class OfflineCollection(+ val uri: String,+ val type: String,+ val name: String,+ val trackIds: Set<String>,+ val syncedAt: Long,+)++/**+ * Lists downloaded as a whole stay in step with Spotify, like the official app: songs+ * added to them are downloaded, songs that left them (a Blend renewed, a song removed)+ * are deleted. A file stays on the phone as long as a downloaded list holds it or it was+ * downloaded on its own (from a song's menu).+ */+object OfflineCollections {+ private const val TAG = "OfflineLists"+ private const val SYNC_EVERY_MS = 6 * 3_600_000L+ private lateinit var file: File+ private val lock = Any()+ private val scope = CoroutineScope(SupervisorJob() + Dispatchers.IO)++ val collections: SnapshotStateMap<String, OfflineCollection> = mutableStateMapOf()+ /** Songs downloaded on their own, kept whatever the lists do. */+ private val singles = HashSet<String>()++ fun init(context: Context) {+ if (::file.isInitialized) return+ file = File(context.filesDir, "offline/collections.json")+ // Songs downloaded before lists existed belong to nothing: they stay until a list+ // that held them is downloaded again and drops them (e.g. a renewed Blend).+ runCatching { read(file.readText()) }+ }++ fun isDownloaded(uri: String) = collections.containsKey(uri)++ /** A song still has a reason to stay on the phone. */+ fun isKept(trackId: String): Boolean = synchronized(lock) { trackId in singles } ||+ collections.values.any { trackId in it.trackIds }++ /** Download a song on its own. */+ fun downloadSong(song: SongsModel) {+ if (song.spotifyTrackId.isBlank()) return+ synchronized(lock) { singles += song.spotifyTrackId }+ save()+ OfflineDownloader.enqueue(listOf(song))+ }++ /**+ * Remove a song downloaded on its own. Returns false when a downloaded list still+ * holds it (the file stays).+ */+ fun removeSong(trackId: String): Boolean {+ synchronized(lock) { singles -= trackId }+ save()+ if (isKept(trackId)) return false+ OfflineDownloader.remove(trackId)+ return true+ }++ /** Download a list as a whole, and keep it in step from now on. */+ fun download(page: ContextPageModel) {+ val ids = page.tracks.map { it.spotifyTrackId }.filter { it.isNotBlank() }.toSet()+ collections[page.uri] = OfflineCollection(page.uri, page.type, page.name, ids, System.currentTimeMillis())+ save()+ OfflineDownloader.enqueue(page.tracks)+ }++ /** Stop keeping a list: its songs go, unless another reason keeps them. */+ fun remove(uri: String) {+ val c = collections.remove(uri) ?: return+ save()+ c.trackIds.filterNot { isKept(it) }.forEach { OfflineDownloader.remove(it) }+ }++ fun removeAll() {+ collections.clear()+ synchronized(lock) { singles.clear() }+ save()+ }++ /**+ * The list's current songs (from a complete page): new ones are downloaded, those+ * that left it are deleted unless something else keeps them.+ */+ fun sync(page: ContextPageModel) {+ val c = collections[page.uri] ?: return+ if (!page.complete) return+ val songs = page.tracks.filter { it.spotifyTrackId.isNotBlank() }+ val ids = songs.map { it.spotifyTrackId }.toSet()+ val gone = c.trackIds - ids+ collections[page.uri] = c.copy(name = page.name, trackIds = ids, syncedAt = System.currentTimeMillis())+ save()+ val missing = songs.filter { !OfflineStore.isDownloaded(it.spotifyTrackId) && OfflineStore.status[it.spotifyTrackId] == null }+ if (missing.isNotEmpty()) OfflineDownloader.enqueue(missing)+ gone.filterNot { isKept(it) }.forEach { OfflineDownloader.remove(it) }+ if (missing.isNotEmpty() || gone.isNotEmpty()) Log.i(TAG, "${page.name}: +${missing.size} -${gone.size}")+ }++ /** Brings every downloaded list up to date (at start, at most every 6 hours, online only). */+ fun refreshAll(context: Context) {+ scope.launch {+ delay(15_000)+ if (!OfflineStore.isOnline(context)) return@launch+ val due = collections.values.filter { System.currentTimeMillis() - it.syncedAt > SYNC_EVERY_MS }+ for (c in due) {+ val page = withTimeoutOrNull(60_000) { loadComplete(c) } ?: continue+ withContext(Dispatchers.Main) { sync(page) }+ }+ }+ }++ private suspend fun loadComplete(c: OfflineCollection): ContextPageModel? {+ val api = Graph.api+ val id = c.uri.substringAfterLast(":")+ val flow = when (c.type) {+ "album" -> api.getAlbumPage(id)+ "liked" -> api.getLikedPage()+ else -> api.getPlaylistPage(id)+ }+ return (flow.first { it is Response.Error || (it is Response.Success && it.data.complete) } as? Response.Success)?.data+ }++ private fun save() {+ if (!::file.isInitialized) return+ val text = synchronized(lock) {+ val lists = JSONArray()+ collections.values.forEach { c ->+ lists.put(JSONObject().put("uri", c.uri).put("type", c.type).put("name", c.name)+ .put("synced", c.syncedAt).put("tracks", JSONArray(c.trackIds.toList())))+ }+ JSONObject().put("version", 1).put("lists", lists).put("singles", JSONArray(singles.toList())).toString()+ }+ runCatching {+ file.parentFile?.mkdirs()+ val tmp = File(file.parentFile, file.name + ".tmp")+ tmp.writeText(text)+ tmp.renameTo(file)+ }+ }++ private fun read(text: String) {+ val o = JSONObject(text)+ val lists = o.optJSONArray("lists") ?: JSONArray()+ for (i in 0 until lists.length()) {+ val c = lists.getJSONObject(i)+ val tracks = c.optJSONArray("tracks") ?: JSONArray()+ collections[c.getString("uri")] = OfflineCollection(+ c.getString("uri"), c.optString("type"), c.optString("name"),+ (0 until tracks.length()).map { tracks.getString(it) }.toSet(), c.optLong("synced"),+ )+ }+ val s = o.optJSONArray("singles") ?: JSONArray()+ synchronized(lock) { (0 until s.length()).forEach { singles += s.getString(it) } }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/offline/OfflineDownloader.kt b/base/app/src/main/java/com/music/spotui/data/offline/OfflineDownloader.ktnew file mode 100644index 00000000..5090786b--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/offline/OfflineDownloader.kt@@ -0,0 +1,396 @@+package com.music.spotui.data.offline++import android.util.Log+import androidx.compose.runtime.mutableStateMapOf+import androidx.compose.runtime.snapshots.SnapshotStateMap+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.di.Graph+import com.music.spotui.video.AudioAlign+import com.music.spotui.video.InterruptibleHttp+import com.music.spotui.video.MusicVideoController+import com.music.spotui.video.RangeAudioDownload+import com.music.spotui.video.YouTubeSource+import kotlinx.coroutines.CancellationException+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.Job+import kotlinx.coroutines.SupervisorJob+import kotlinx.coroutines.channels.Channel+import kotlinx.coroutines.currentCoroutineContext+import kotlinx.coroutines.delay+import kotlinx.coroutines.ensureActive+import kotlinx.coroutines.isActive+import kotlinx.coroutines.launch+import kotlinx.coroutines.runInterruptible+import kotlinx.coroutines.sync.Mutex+import kotlinx.coroutines.sync.withLock+import kotlinx.coroutines.withContext+import okhttp3.HttpUrl.Companion.toHttpUrl+import org.json.JSONArray+import org.json.JSONObject+import org.schabi.newpipe.extractor.MediaFormat+import java.io.File+import java.io.IOException+import java.util.concurrent.ConcurrentHashMap++/**+ * Downloads songs for offline listening. Spotify only gives the track (title, artist,+ * duration, ISRC); the audio comes from YouTube Music, the same way music videos are+ * found:+ *+ * 1. the YouTube Music "song" of the track (the label's "Artist - Topic" upload of the+ * same master), else a plain "official audio" upload, duration within 3 s;+ * 2. the best audio stream as YouTube serves it (Opus or AAC, never re-encoded);+ * 3. a check against the recording's official 30 s preview (Deezer, looked up by ISRC):+ * the two audios are aligned like a clip's soundtrack, which rejects a live take, a+ * remix or a cover. Without a preview, only the "Topic" upload is trusted.+ *+ * Nothing that fails the check is kept: the song is marked unavailable instead.+ */+object OfflineDownloader {+ private const val TAG = "Offline"+ private const val WORKERS = 2+ private const val MIN_SCORE = 0.5++ data class Request(+ val trackId: String,+ val title: String,+ val artist: String,+ val album: String,+ val albumId: String,+ val durationMs: Long,+ val coverUrl: String,+ ) {+ fun toJson(): JSONObject = JSONObject().put("id", trackId).put("title", title).put("artist", artist)+ .put("album", album).put("albumId", albumId).put("duration", durationMs).put("cover", coverUrl)++ companion object {+ fun of(s: SongsModel) = Request(+ trackId = s.spotifyTrackId, title = s.title, artist = s.singer, album = s.album,+ albumId = s.albumId, durationMs = s.durationMs.toLong(), coverUrl = s.coverUri,+ )+ fun fromJson(o: JSONObject) = Request(+ o.getString("id"), o.optString("title"), o.optString("artist"), o.optString("album"),+ o.optString("albumId"), o.optLong("duration"), o.optString("cover"),+ )+ }+ }++ private class Unavailable(message: String) : Exception(message)++ private val scope = CoroutineScope(SupervisorJob() + Dispatchers.IO)+ /** Songs queued, downloading, or whose download did not succeed (for the Downloaded list). */+ val requests: SnapshotStateMap<String, Request> = mutableStateMapOf()+ private val queue = Channel<Request>(Channel.UNLIMITED)+ /** Requests not finished yet, in order (persisted: a restart resumes them). */+ private val pending = LinkedHashMap<String, Request>()+ private val running = ConcurrentHashMap<String, Job>()+ // One decode + alignment at a time: they are the CPU- and memory-heavy part.+ private val checkLock = Mutex()+ @Volatile private var started = false++ private fun start() {+ if (started) return+ synchronized(this) {+ if (started) return+ started = true+ repeat(WORKERS) { scope.launch { for (r in queue) work(r) } }+ }+ }++ /** Re-queues what was waiting when the app last stopped. */+ fun resumePending() {+ val saved = runCatching {+ val a = JSONArray(OfflineStore.pendingFile.readText())+ (0 until a.length()).map { Request.fromJson(a.getJSONObject(it)) }+ }.getOrDefault(emptyList())+ if (saved.isNotEmpty()) enqueueAll(saved)+ }++ fun enqueue(songs: List<SongsModel>) = enqueueAll(songs.filter { it.spotifyTrackId.isNotBlank() }.map(Request::of))++ private fun enqueueAll(list: List<Request>) {+ val added = synchronized(pending) {+ list.filter { r ->+ !OfflineStore.isDownloaded(r.trackId) && pending.putIfAbsent(r.trackId, r) == null+ }.also { if (it.isNotEmpty()) savePending() }+ }+ if (added.isEmpty()) return+ scope.launch(Dispatchers.Main) {+ added.forEach { requests[it.trackId] = it; OfflineStore.status[it.trackId] = OfflineStatus.Queued }+ }+ start()+ added.forEach { queue.trySend(it) }+ }++ /** Stops a queued or running download (and forgets a failed one). */+ fun cancel(trackId: String) {+ synchronized(pending) { if (pending.remove(trackId) != null) savePending() }+ running.remove(trackId)?.cancel()+ OfflineStore.status.remove(trackId)+ requests.remove(trackId)+ }++ /** Tries a failed song again. */+ fun retry(trackId: String) {+ val r = requests[trackId] ?: return+ enqueueAll(listOf(r))+ }++ /** Removes the song: the file if downloaded, else its download. */+ fun remove(trackId: String) {+ cancel(trackId)+ OfflineStore.remove(trackId)+ }++ fun removeAll() {+ val ids = synchronized(pending) { pending.keys.toList().also { pending.clear(); savePending() } }+ ids.forEach { running.remove(it)?.cancel() }+ running.values.forEach { it.cancel() }+ requests.clear()+ OfflineCollections.removeAll()+ OfflineStore.removeAll()+ }++ private fun savePending() {+ runCatching {+ val a = JSONArray()+ pending.values.forEach { a.put(it.toJson()) }+ OfflineStore.pendingFile.writeText(a.toString())+ }+ }++ private suspend fun setStatus(id: String, s: OfflineStatus?) = withContext(Dispatchers.Main) {+ if (s == null) OfflineStore.status.remove(id) else OfflineStore.status[id] = s+ }++ private suspend fun work(r: Request) {+ // Cancelled while it waited in the queue.+ if (synchronized(pending) { !pending.containsKey(r.trackId) }) return+ // Data saver on mobile data: downloads wait for Wi-Fi.+ while (com.music.spotui.data.DataSaver.active) {+ kotlinx.coroutines.delay(5_000)+ if (synchronized(pending) { !pending.containsKey(r.trackId) }) return+ }+ val job = scope.launch {+ val outcome: OfflineStatus? = try {+ setStatus(r.trackId, OfflineStatus.Downloading(-1f))+ val t = download(r)+ withContext(Dispatchers.Main) { OfflineStore.add(t); requests.remove(r.trackId) }+ null+ } catch (e: CancellationException) {+ throw e+ } catch (e: Unavailable) {+ Log.i(TAG, "${r.title}: ${e.message}")+ OfflineStatus.Unavailable+ } catch (t: Throwable) {+ Log.w(TAG, "${r.title} failed", t)+ OfflineStatus.Failed+ }+ synchronized(pending) { pending.remove(r.trackId); savePending() }+ if (outcome != null) setStatus(r.trackId, outcome)+ }+ running[r.trackId] = job+ job.join()+ running.remove(r.trackId, job)+ }++ private suspend fun download(r: Request): OfflineTrack {+ val tmp = OfflineStore.tmpDir+ val audioTmp = File(tmp, "${r.trackId}.part")+ val previewTmp = File(tmp, "${r.trackId}.preview")+ try {+ val meta = spotifyMeta(r)+ val previewLink = previewUrl(meta)+ val preview = previewLink?.let { url ->+ runCatching { httpGet(url, previewTmp); previewTmp }+ .onFailure { Log.w(TAG, "${meta.title}: preview download failed: $it") }.getOrNull()+ }+ val previewFeatures = preview?.let { f ->+ checkLock.withLock {+ runCatching { runInterruptible(Dispatchers.Default) { AudioAlign.features(AudioAlign.decode(f)) } }+ .onFailure { Log.w(TAG, "${meta.title}: preview decode failed: $it") }.getOrNull()+ }+ }+ Log.i(TAG, "${meta.title}: isrc=${meta.isrc ?: "-"} preview=${if (previewFeatures != null) "ok" else if (previewLink != null) "unusable" else "none"}")+ // An empty search (or YouTube's "results may be inappropriate" page) is no match, not an error.+ fun search(what: String, block: () -> YouTubeSource.Hit?): YouTubeSource.Hit? = try {+ block()+ } catch (e: org.schabi.newpipe.extractor.search.SearchExtractor.NothingFoundException) {+ Log.i(TAG, "${meta.title}: $what: nothing found"); null+ }+ val candidates = buildList {+ runInterruptible { search("song") { YouTubeSource.findSong(meta.title, meta.artist, meta.durationMs) } }?.let { add(it to true) }+ runInterruptible { search("audio") { YouTubeSource.findAudio(meta.title, meta.artist, meta.durationMs) } }?.let { add(it to false) }+ }.distinctBy { it.first.url }+ if (candidates.isEmpty()) throw Unavailable("no YouTube match")+ for ((hit, topic) in candidates) {+ currentCoroutineContext().ensureActive()+ // No preview to compare with: only the label's own upload is trusted.+ if (previewFeatures == null && !topic) continue+ val ext = fetchAudio(r.trackId, hit.url, audioTmp)+ val verified = previewFeatures != null+ if (!verified) Log.i(TAG, "${meta.title}: ${hit.name} (${hit.uploader}) kept unverified (Topic upload)")+ if (verified) {+ val score = checkLock.withLock {+ val full = runInterruptible(Dispatchers.Default) { AudioAlign.features(AudioAlign.decode(audioTmp)) }+ val map = AudioAlign.align(previewFeatures!!, full)+ if (map.segments.isEmpty()) 0.0 else map.score+ }+ Log.i(TAG, "${meta.title}: ${hit.name} (${hit.uploader}) score ${"%.2f".format(score)}")+ if (score < MIN_SCORE) { audioTmp.delete(); continue }+ }+ val file = File(OfflineStore.audioDir, "${r.trackId}.$ext")+ if (!audioTmp.renameTo(file)) throw IOException("could not move the file")+ val cover = runCatching {+ val c = File(OfflineStore.coverDir, "${r.trackId}.jpg")+ httpGet(meta.coverUrl, c); c.name+ }.getOrDefault("")+ return OfflineTrack(+ trackId = r.trackId, title = meta.title, artist = meta.artist, album = meta.album,+ albumId = meta.albumId, durationMs = meta.durationMs, coverUrl = meta.coverUrl,+ file = file.name, cover = cover, source = hit.url, verified = verified,+ bytes = file.length(), addedAt = System.currentTimeMillis(),+ )+ }+ throw Unavailable(if (previewFeatures == null) "no preview and no Topic upload" else "no candidate matched the preview")+ } finally {+ audioTmp.delete(); previewTmp.delete()+ }+ }++ private data class Meta(+ val title: String, val artist: String, val album: String, val albumId: String,+ val durationMs: Long, val coverUrl: String, val isrc: String?,+ )++ /** The request, completed by Spotify's track (ISRC, and anything the list lacked). */+ private suspend fun spotifyMeta(r: Request): Meta {+ val api = app.myspoti.host.android.MyspotiRuntime.api+ val uri = "spotify:track:${r.trackId}"+ val t = runCatching { api.catalog.track(uri) }.onFailure { Log.w(TAG, "${r.title}: Spotify track: $it") }.getOrNull()+ val isrc = runCatching { api.catalog.isrc(uri) }.onFailure { Log.w(TAG, "${r.title}: ISRC: $it") }.getOrNull()+ val cover = r.coverUrl.ifBlank { t?.album?.images?.maxByOrNull { it.width ?: 0 }?.url.orEmpty() }+ return Meta(+ title = r.title.ifBlank { t?.name.orEmpty() },+ artist = r.artist.ifBlank { t?.artists?.joinToString(", ") { it.name }.orEmpty() },+ album = r.album.ifBlank { t?.album?.name.orEmpty() },+ albumId = r.albumId.ifBlank { t?.album?.uri?.substringAfterLast(':').orEmpty() },+ durationMs = r.durationMs.takeIf { it > 0 } ?: t?.durationMs ?: 0L,+ coverUrl = cover,+ isrc = isrc?.let(::normalizeIsrc),+ ).also { if (it.title.isBlank() || it.artist.isBlank()) throw Unavailable("no track metadata") }+ }++ /** The official 30 s preview of the recording: by ISRC, else by artist + title + duration. */+ private suspend fun previewUrl(m: Meta): String? = runInterruptible {+ runCatching {+ if (m.isrc != null) {+ val o = JSONObject(httpText("https://api.deezer.com/track/isrc:${m.isrc}"))+ o.optString("preview").takeIf { !o.has("error") && it.startsWith("http") }?.let { return@runCatching it }+ }+ val main = m.artist.substringBefore(",").trim()+ val url = "https://api.deezer.com/search".toHttpUrl().newBuilder().addQueryParameter("q", "$main ${m.title}").build().toString()+ val data = JSONObject(httpText(url)).optJSONArray("data") ?: JSONArray()+ pickPreview((0 until data.length()).mapNotNull { i ->+ data.optJSONObject(i)?.let {+ PreviewHit(it.optString("preview"), it.optString("title"), it.optJSONObject("artist")?.optString("name").orEmpty(), it.optLong("duration", -1))+ }+ }, m.title, main, m.durationMs)+ }.getOrNull()+ }++ private fun httpText(url: String): String =+ InterruptibleHttp.read(YouTubeSource.http.newCall(okhttp3.Request.Builder().url(url).build())) {+ if (!it.isSuccessful) throw IOException("HTTP ${it.code}")+ it.body?.string().orEmpty()+ }++ private suspend fun httpGet(url: String, out: File) = runInterruptible {+ InterruptibleHttp.read(YouTubeSource.http.newCall(okhttp3.Request.Builder().url(url).build())) { r ->+ if (!r.isSuccessful) throw IOException("HTTP ${r.code}")+ val body = r.body ?: throw IOException("empty body")+ out.outputStream().use { body.byteStream().copyTo(it) }+ }+ }++ /** Downloads the best audio stream of [url] into [out]; returns the file extension. */+ private suspend fun fetchAudio(trackId: String, url: String, out: File): String {+ var info = runInterruptible { YouTubeSource.info(url) }+ var last: Throwable? = null+ for (attempt in 0..1) {+ val streams = rankAudio(info.audioStreams.mapNotNull { a ->+ val ext = when (a.format) { MediaFormat.WEBMA_OPUS -> "webm"; MediaFormat.M4A -> "m4a"; else -> null }+ ext?.let { AudioChoice(it, a.averageBitrate, a.content) }+ })+ if (streams.isEmpty()) throw Unavailable("no audio stream")+ for (a in streams.take(2)) {+ try {+ fetchWithProgress(trackId, a.url, out)+ val expected = if (a.bitrate > 0 && info.duration > 0) a.bitrate * 1000L / 8 * info.duration else 0L+ if (out.length() < 50_000 || (expected > 0 && out.length() < expected * 0.6))+ throw IOException("${out.length() / 1024} KB, expected ~${expected / 1024} KB")+ return a.ext+ } catch (t: Throwable) {+ currentCoroutineContext().ensureActive()+ last = t+ }+ }+ // Stream URLs expire or get refused (403): resolve them again once.+ info = runInterruptible { YouTubeSource.info(url, fresh = true) }+ }+ throw last ?: IOException("download failed")+ }++ private suspend fun fetchWithProgress(trackId: String, url: String, out: File) {+ val total = runCatching { url.toHttpUrl().queryParameter("clen")?.toLongOrNull() }.getOrNull()+ val watcher = if (total != null && total > 0) scope.launch {+ while (isActive) {+ setStatus(trackId, OfflineStatus.Downloading((out.length().toFloat() / total).coerceIn(0f, 1f)))+ delay(400)+ }+ } else null+ try {+ RangeAudioDownload.fetch(YouTubeSource.http, url, out, MusicVideoController.streamHeaders(url))+ } finally {+ watcher?.cancel()+ }+ setStatus(trackId, OfflineStatus.Downloading(-1f))+ }++ // ── Pure helpers (unit-tested) ──++ data class AudioChoice(val ext: String, val bitrate: Int, val url: String)++ /** Highest bitrate first; at equal bitrate Opus (better quality per bit) first. */+ fun rankAudio(streams: List<AudioChoice>): List<AudioChoice> =+ streams.sortedWith(compareByDescending<AudioChoice> { it.bitrate }.thenBy { if (it.ext == "webm") 0 else 1 })++ /** "US-UM7-17-03861" / "usum71703861" → "USUM71703861"; null when not an ISRC. */+ fun normalizeIsrc(raw: String): String? =+ raw.uppercase().filter { it.isLetterOrDigit() }.takeIf { Regex("[A-Z]{2}[A-Z0-9]{3}\\d{7}").matches(it) }++ data class PreviewHit(val url: String, val title: String, val artist: String, val durationSec: Long)++ private fun folded(s: String) = java.text.Normalizer.normalize(s, java.text.Normalizer.Form.NFD)+ .replace(Regex("""\p{M}+"""), "").lowercase()++ /** Title without "(feat. …)", "[Remastered]", " - Radio Edit"…, letters and digits only. */+ internal fun titleKey(s: String) = folded(s)+ .replace(Regex("""\(.*?\)|\[.*?]"""), " ")+ .replace(Regex("""\s+-\s+.*$"""), " ")+ .replace(Regex("""\b(?:feat|ft)\.?\s.*$"""), " ")+ .filter { it.isLetterOrDigit() }++ /** The search result that is the same song: title, main artist, and duration within 3 s. */+ fun pickPreview(results: List<PreviewHit>, title: String, artist: String, durationMs: Long): String? {+ if (durationMs <= 0) return null+ val t = titleKey(title)+ val a = folded(artist).filter { it.isLetterOrDigit() }+ return results.firstOrNull { h ->+ h.url.startsWith("http") && h.durationSec > 0 &&+ kotlin.math.abs(h.durationSec * 1000 - durationMs) <= 3000 &&+ titleKey(h.title) == t && folded(h.artist).filter { it.isLetterOrDigit() } == a+ }?.url+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/offline/OfflineStore.kt b/base/app/src/main/java/com/music/spotui/data/offline/OfflineStore.ktnew file mode 100644index 00000000..a4d595f7--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/offline/OfflineStore.kt@@ -0,0 +1,183 @@+package com.music.spotui.data.offline++import android.content.Context+import android.net.Uri+import androidx.compose.runtime.mutableStateMapOf+import androidx.compose.runtime.snapshots.SnapshotStateMap+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.data.local.LocalTrack+import org.json.JSONArray+import org.json.JSONObject+import java.io.File++/** A song kept for offline listening, in the app's private storage. */+data class OfflineTrack(+ val trackId: String,+ val title: String,+ val artist: String,+ val album: String,+ val albumId: String,+ val durationMs: Long,+ val coverUrl: String,+ /** Audio file name in [OfflineStore]'s audio folder. */+ val file: String,+ /** Cover file name in the covers folder, empty when it could not be fetched. */+ val cover: String,+ /** Where the audio came from (YouTube watch URL). */+ val source: String,+ /** The audio was checked against the recording's official preview. */+ val verified: Boolean,+ val bytes: Long,+ val addedAt: Long,+) {+ fun toJson(): JSONObject = JSONObject()+ .put("id", trackId).put("title", title).put("artist", artist).put("album", album)+ .put("albumId", albumId).put("duration", durationMs).put("coverUrl", coverUrl)+ .put("file", file).put("cover", cover).put("source", source).put("verified", verified)+ .put("bytes", bytes).put("added", addedAt)++ companion object {+ fun fromJson(o: JSONObject) = OfflineTrack(+ trackId = o.getString("id"), title = o.optString("title"), artist = o.optString("artist"),+ album = o.optString("album"), albumId = o.optString("albumId"), durationMs = o.optLong("duration"),+ coverUrl = o.optString("coverUrl"), file = o.getString("file"), cover = o.optString("cover"),+ source = o.optString("source"), verified = o.optBoolean("verified"), bytes = o.optLong("bytes"),+ addedAt = o.optLong("added"),+ )+ }+}++/** Where a download stands, for the badges and buttons. */+sealed interface OfflineStatus {+ data object Queued : OfflineStatus+ /** [progress] 0..1, or -1 while the source is looked up / checked. */+ data class Downloading(val progress: Float) : OfflineStatus+ data object Done : OfflineStatus+ /** No recording that matches the Spotify track was found. */+ data object Unavailable : OfflineStatus+ /** Network or storage error: can be tried again. */+ data object Failed : OfflineStatus+}++/**+ * Downloaded songs. Files live in the app's private storage (filesDir/offline), so+ * only Myspoti plays them: they are not in the phone's Music folder or MediaStore.+ */+object OfflineStore {+ private lateinit var root: File+ private val lock = Any()++ /** Downloaded songs by Spotify track id; every screen reads this. */+ val tracks: SnapshotStateMap<String, OfflineTrack> = mutableStateMapOf()+ /** Songs in the download queue, or whose last attempt did not succeed. */+ val status: SnapshotStateMap<String, OfflineStatus> = mutableStateMapOf()++ fun init(context: Context) {+ if (::root.isInitialized) return+ root = File(context.filesDir, "offline")+ audioDir.mkdirs(); coverDir.mkdirs()+ // The index lists only finished files; anything else in the folders is a leftover.+ val list = readIndex()+ val kept = list.filter { File(audioDir, it.file).isFile }+ kept.forEach { tracks[it.trackId] = it }+ if (kept.size != list.size) writeIndex()+ val names = kept.map { it.file }.toSet()+ audioDir.listFiles()?.forEach { if (it.name !in names) it.delete() }+ val covers = kept.map { it.cover }.toSet()+ coverDir.listFiles()?.forEach { if (it.name !in covers) it.delete() }+ }++ val audioDir: File get() = File(root, "audio")+ val coverDir: File get() = File(root, "covers")+ private val indexFile: File get() = File(root, "index.json")+ internal val pendingFile: File get() = File(root, "pending.json")+ val tmpDir: File get() = File(root, "tmp").apply { mkdirs() }++ fun isDownloaded(trackId: String) = trackId.isNotBlank() && tracks.containsKey(trackId)++ /** What the UI shows for a track: downloaded, in the queue, failed… or nothing. */+ fun statusOf(trackId: String): OfflineStatus? =+ if (isDownloaded(trackId)) OfflineStatus.Done else status[trackId]++ fun add(t: OfflineTrack) {+ synchronized(lock) {+ tracks[t.trackId] = t+ status.remove(t.trackId)+ writeIndex()+ }+ }++ fun remove(trackId: String) {+ synchronized(lock) {+ val t = tracks.remove(trackId) ?: return+ File(audioDir, t.file).delete()+ if (t.cover.isNotBlank()) File(coverDir, t.cover).delete()+ writeIndex()+ }+ }++ fun removeAll() {+ synchronized(lock) {+ tracks.clear()+ status.clear()+ audioDir.listFiles()?.forEach { it.delete() }+ coverDir.listFiles()?.forEach { it.delete() }+ writeIndex()+ }+ }++ fun totalBytes(): Long = tracks.values.sumOf { it.bytes }++ /** A working internet connection (else downloaded songs play from the phone). */+ fun isOnline(context: Context): Boolean {+ // The data saver on mobile data: the app behaves as offline.+ if (com.music.spotui.data.DataSaver.active) return false+ val cm = context.getSystemService(android.net.ConnectivityManager::class.java) ?: return true+ val caps = cm.activeNetwork?.let { cm.getNetworkCapabilities(it) } ?: return false+ // Not "validated" is not offline: some VPNs, private DNS and Wi-Fi networks never pass+ // Android's check, and treating them as offline played only the downloaded songs of a+ // list, skipping all the others (issue #10).+ return caps.hasCapability(android.net.NetworkCapabilities.NET_CAPABILITY_INTERNET)+ }++ /** Downloaded songs, newest first. */+ fun list(): List<OfflineTrack> = tracks.values.sortedByDescending { it.addedAt }++ fun audioFile(t: OfflineTrack) = File(audioDir, t.file)+ fun coverFile(t: OfflineTrack): File? = t.cover.takeIf { it.isNotBlank() }?.let { File(coverDir, it) }?.takeIf { it.isFile }++ /** For the local player (player, mini player, notification…). */+ fun toLocalTrack(t: OfflineTrack) = LocalTrack(+ id = localIdOf(t.trackId),+ uri = Uri.fromFile(audioFile(t)),+ title = t.title,+ artist = t.artist,+ album = t.album,+ durationMs = t.durationMs,+ artUri = coverFile(t)?.let { Uri.fromFile(it) } ?: Uri.parse(t.coverUrl),+ )++ fun toSong(t: OfflineTrack) = SongsModel(+ id = "track:${t.trackId}".hashCode() and 0x7fffffff,+ title = t.title, album = t.album, singer = t.artist,+ coverUri = coverFile(t)?.let { Uri.fromFile(it).toString() } ?: t.coverUrl,+ url = "spotify:track:${t.trackId}", spotifyTrackId = t.trackId,+ durationMs = t.durationMs.toInt(), albumId = t.albumId,+ )++ /** Negative, so it never collides with a MediaStore id (Local Files). */+ fun localIdOf(trackId: String): Long = -1L - (trackId.hashCode().toLong() and 0x7fffffffL)++ private fun readIndex(): List<OfflineTrack> = runCatching {+ val a = JSONArray(indexFile.readText())+ (0 until a.length()).mapNotNull { runCatching { OfflineTrack.fromJson(a.getJSONObject(it)) }.getOrNull() }+ }.getOrDefault(emptyList())++ private fun writeIndex() {+ val a = JSONArray()+ tracks.values.forEach { a.put(it.toJson()) }+ val tmp = File(root, "index.json.tmp")+ tmp.writeText(a.toString())+ tmp.renameTo(indexFile)+ }+}diff --git a/base/app/src/main/java/com/music/spotui/data/preferences/FollowedArtistPref.kt b/base/app/src/main/java/com/music/spotui/data/preferences/FollowedArtistPref.ktnew file mode 100644index 00000000..00f89265--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/preferences/FollowedArtistPref.kt@@ -0,0 +1,23 @@+package com.music.spotui.data.preferences++import android.content.Context++// Local record of artists followed from the app (keyed by Spotify artist id),+// so the Follow button keeps its state across visits. The follow itself is also+// mirrored to the real Spotify account via SpotifySync.++fun addFollowedArtist(context: Context, artistId: String, name: String) {+ if (artistId.isBlank()) return+ context.getSharedPreferences("FollowedArtists", Context.MODE_PRIVATE)+ .edit().putString(artistId, name).apply()+}++fun removeFollowedArtist(context: Context, artistId: String) {+ if (artistId.isBlank()) return+ context.getSharedPreferences("FollowedArtists", Context.MODE_PRIVATE)+ .edit().remove(artistId).apply()+}++fun isArtistFollowed(context: Context, artistId: String): Boolean =+ artistId.isNotBlank() &&+ context.getSharedPreferences("FollowedArtists", Context.MODE_PRIVATE).contains(artistId)diff --git a/base/app/src/main/java/com/music/spotui/data/preferences/LibraryCachePref.kt b/base/app/src/main/java/com/music/spotui/data/preferences/LibraryCachePref.ktnew file mode 100644index 00000000..fa663e90--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/preferences/LibraryCachePref.kt@@ -0,0 +1,77 @@+package com.music.spotui.data.preferences++import android.content.Context+import com.music.spotui.data.entity.ArtistsModel+import com.music.spotui.data.entity.LibraryEntry+import org.json.JSONArray+import org.json.JSONObject++private const val PREF = "LibraryCache"++fun cacheLibraryEntries(context: Context, entries: List<LibraryEntry>) {+ val json = JSONArray().apply {+ entries.forEach { e ->+ put(JSONObject().apply {+ put("spotifyId", e.spotifyId)+ put("name", e.name)+ put("subtitle", e.subtitle)+ put("coverUri", e.coverUri)+ put("isPlaylist", e.isPlaylist)+ put("artists", e.artists)+ put("folderUri", e.folderUri)+ put("childCount", e.childCount)+ })+ }+ }.toString()+ context.getSharedPreferences(PREF, Context.MODE_PRIVATE)+ .edit().putString("entries", json).apply()+}++fun getCachedLibraryEntries(context: Context): List<LibraryEntry> = runCatching {+ val raw = context.getSharedPreferences(PREF, Context.MODE_PRIVATE)+ .getString("entries", null) ?: return emptyList()+ val arr = JSONArray(raw)+ (0 until arr.length()).map { i ->+ arr.getJSONObject(i).let { o ->+ LibraryEntry(+ spotifyId = o.getString("spotifyId"),+ name = o.getString("name"),+ subtitle = o.getString("subtitle"),+ coverUri = o.getString("coverUri"),+ isPlaylist = o.getBoolean("isPlaylist"),+ artists = o.optString("artists", ""),+ folderUri = o.optString("folderUri", ""),+ childCount = o.optInt("childCount", 0),+ )+ }+ }+}.getOrDefault(emptyList())++fun cacheFollowedArtists(context: Context, artists: List<ArtistsModel>) {+ val json = JSONArray().apply {+ artists.forEach { a ->+ put(JSONObject().apply {+ put("name", a.name)+ put("coverUri", a.coverUri)+ put("id", a.id)+ })+ }+ }.toString()+ context.getSharedPreferences(PREF, Context.MODE_PRIVATE)+ .edit().putString("followedArtists", json).apply()+}++fun getCachedFollowedArtists(context: Context): List<ArtistsModel> = runCatching {+ val raw = context.getSharedPreferences(PREF, Context.MODE_PRIVATE)+ .getString("followedArtists", null) ?: return emptyList()+ val arr = JSONArray(raw)+ (0 until arr.length()).map { i ->+ arr.getJSONObject(i).let { o ->+ ArtistsModel(+ name = o.getString("name"),+ coverUri = o.getString("coverUri"),+ id = o.optString("id", ""),+ )+ }+ }+}.getOrDefault(emptyList())diff --git a/base/app/src/main/java/com/music/spotui/data/preferences/LikedAlbumPref.kt b/base/app/src/main/java/com/music/spotui/data/preferences/LikedAlbumPref.ktnew file mode 100644index 00000000..c836265b--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/preferences/LikedAlbumPref.kt@@ -0,0 +1,32 @@+package com.music.spotui.data.preferences++import android.content.Context+import com.music.spotui.data.entity.AlbumsModel++fun addLikedAlbumId(context: Context, albumId: String) {+ val sharedPreferences = context.getSharedPreferences("LikedAlbums", Context.MODE_PRIVATE)+ val editor = sharedPreferences.edit()+ editor.putString(albumId, albumId)+ editor.apply()+}++fun removeLikedAlbumId(context: Context, albumId: String) {+ val sharedPreferences = context.getSharedPreferences("LikedAlbums", Context.MODE_PRIVATE)+ val editor = sharedPreferences.edit()+ editor.remove(albumId)+ editor.apply()+}++fun isAlbumLiked(context: Context, albumId: String): Boolean {+ val sharedPreferences = context.getSharedPreferences("LikedAlbums", Context.MODE_PRIVATE)+ return sharedPreferences.contains(albumId)+}++fun getLikedAlbumIds(context: Context): Set<Int> {+ val sharedPreferences = context.getSharedPreferences("LikedAlbums", Context.MODE_PRIVATE)+ return sharedPreferences.all.keys.mapNotNull { it.toIntOrNull() }.toSet()+}++fun getAlbumsByIds(albumIds: Set<Int>, albums: List<AlbumsModel>): List<AlbumsModel> {+ return albums.filter { album -> album.id in albumIds }+}\ No newline at end of filediff --git a/base/app/src/main/java/com/music/spotui/data/preferences/LikedSongPref.kt b/base/app/src/main/java/com/music/spotui/data/preferences/LikedSongPref.ktnew file mode 100644index 00000000..745cc93d--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/preferences/LikedSongPref.kt@@ -0,0 +1,46 @@+package com.music.spotui.data.preferences++import android.content.Context+import com.music.spotui.data.entity.SongsModel++fun addLikedSongId(context: Context, songId: String) {+ val sharedPreferences = context.getSharedPreferences("LikedSongs", Context.MODE_PRIVATE)+ val editor = sharedPreferences.edit()+ editor.putString(songId, songId)+ editor.apply()+}++fun removeLikedSongId(context: Context, songId: String) {+ val sharedPreferences = context.getSharedPreferences("LikedSongs", Context.MODE_PRIVATE)+ val editor = sharedPreferences.edit()+ editor.remove(songId)+ editor.apply()+}++fun isSongLiked(context: Context, songId: String): Boolean {+ val sharedPreferences = context.getSharedPreferences("LikedSongs", Context.MODE_PRIVATE)+ return sharedPreferences.contains(songId)+}++fun getLikedSongIds(context: Context): Set<Int> {+ val sharedPreferences = context.getSharedPreferences("LikedSongs", Context.MODE_PRIVATE)+ return sharedPreferences.all.keys.mapNotNull { it.toIntOrNull() }.toSet()+}++fun getSongsByIds(songIds: Set<Int>, songs: List<SongsModel>): List<SongsModel> {+ return songs.filter { song -> song.id in songIds }+}+/**+ * Mirrors a Spotify Liked Songs fetch in one write. A [complete] fetch also drops ids+ * an earlier fetch brought in that Spotify no longer has (unliked elsewhere). Likes+ * made only in this app were never in that earlier set, so they stay.+ */+fun syncSpotifyLikedSongIds(context: Context, ids: Set<String>, complete: Boolean) {+ val seed = context.getSharedPreferences("LikedSongsFromSpotify", Context.MODE_PRIVATE)+ val previous = seed.getStringSet("ids", null).orEmpty()+ context.getSharedPreferences("LikedSongs", Context.MODE_PRIVATE).edit().apply {+ if (complete) (previous - ids).forEach { remove(it) }+ ids.forEach { putString(it, it) }+ }.apply()+ if (complete) seed.edit().putStringSet("ids", ids).apply()+}diff --git a/base/app/src/main/java/com/music/spotui/data/preferences/PlaybackStatePref.kt b/base/app/src/main/java/com/music/spotui/data/preferences/PlaybackStatePref.ktnew file mode 100644index 00000000..553689ae--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/preferences/PlaybackStatePref.kt@@ -0,0 +1,59 @@+package com.music.spotui.data.preferences++import android.content.Context+import com.music.spotui.data.entity.SongsModel+import org.json.JSONObject++// Persists the last playing track + position so a fresh app launch can restore+// the session (mini player shows the track, play resumes where it stopped).++private const val PREF = "PlaybackState"+private const val KEY_SONG = "song"+private const val KEY_POSITION = "positionMs"++/** Saves the track (resets the stored position when the track changed). */+fun saveLastPlayback(context: Context, song: SongsModel) {+ if (song.title.isBlank() || song.url.isBlank()) return+ val p = context.getSharedPreferences(PREF, Context.MODE_PRIVATE)+ val prevId = runCatching { p.getString(KEY_SONG, null)?.let { JSONObject(it).optInt("id", -1) } }+ .getOrNull() ?: -1+ val json = JSONObject().apply {+ put("id", song.id); put("title", song.title); put("album", song.album)+ put("singer", song.singer); put("coverUri", song.coverUri)+ put("url", song.url); put("spotifyTrackId", song.spotifyTrackId)+ put("explicit", song.explicit); put("durationMs", song.durationMs)+ }+ p.edit().apply {+ putString(KEY_SONG, json.toString())+ if (prevId != song.id) putLong(KEY_POSITION, 0L)+ }.apply()+}++/** Updates just the position of the stored track (called periodically). */+fun saveLastPosition(context: Context, positionMs: Long) {+ if (positionMs <= 0) return+ context.getSharedPreferences(PREF, Context.MODE_PRIVATE)+ .edit().putLong(KEY_POSITION, positionMs).apply()+}++/** The last track and position, or null if nothing was ever played. */+fun loadLastPlayback(context: Context): Pair<SongsModel, Long>? {+ val p = context.getSharedPreferences(PREF, Context.MODE_PRIVATE)+ val raw = p.getString(KEY_SONG, null) ?: return null+ return runCatching {+ val o = JSONObject(raw)+ val song = SongsModel(+ id = o.optInt("id", -1),+ title = o.optString("title"),+ album = o.optString("album"),+ singer = o.optString("singer"),+ coverUri = o.optString("coverUri"),+ url = o.optString("url"),+ spotifyTrackId = o.optString("spotifyTrackId"),+ explicit = o.optBoolean("explicit", false),+ durationMs = o.optInt("durationMs", 0),+ )+ if (song.title.isBlank() || song.url.isBlank()) null+ else song to p.getLong(KEY_POSITION, 0L)+ }.getOrNull()+}diff --git a/base/app/src/main/java/com/music/spotui/data/preferences/RecentItemsPref.kt b/base/app/src/main/java/com/music/spotui/data/preferences/RecentItemsPref.ktnew file mode 100644index 00000000..570f23e6--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/preferences/RecentItemsPref.kt@@ -0,0 +1,73 @@+package com.music.spotui.data.preferences++import android.content.Context+import org.json.JSONArray+import org.json.JSONObject++/**+ * One "Recent searches" entry — Spotify-style: not the typed query but the+ * actual item the user opened from the results (song / artist / album / show).+ * Carries enough payload to re-launch the item on tap.+ */+data class RecentItem(+ val type: String, // "song" | "artist" | "album" | "show"+ val key: String, // stable id for dedupe (spotify id, or name)+ val name: String,+ val singer: String = "", // artist line (songs/albums)+ val image: String = "",+ // Song-only payload so a tap can replay it.+ val songId: Int = -1,+ val songAlbum: String = "",+ val songUrl: String = "",+ val spotifyTrackId: String = "",+ val explicit: Boolean = false,+ val durationMs: Int = 0,+)++private const val PREF = "RecentItems"+private const val KEY = "items"+private const val MAX_ITEMS = 20++private fun RecentItem.toJson(): JSONObject = JSONObject().apply {+ put("type", type); put("key", key); put("name", name); put("singer", singer)+ put("image", image); put("songId", songId); put("songAlbum", songAlbum)+ put("songUrl", songUrl); put("spotifyTrackId", spotifyTrackId)+ put("explicit", explicit); put("durationMs", durationMs)+}++private fun JSONObject.toRecentItem(): RecentItem = RecentItem(+ type = optString("type"), key = optString("key"), name = optString("name"),+ singer = optString("singer"), image = optString("image"),+ songId = optInt("songId", -1), songAlbum = optString("songAlbum"),+ songUrl = optString("songUrl"), spotifyTrackId = optString("spotifyTrackId"),+ explicit = optBoolean("explicit", false), durationMs = optInt("durationMs", 0),+)++fun getRecentItems(context: Context): List<RecentItem> {+ val raw = context.getSharedPreferences(PREF, Context.MODE_PRIVATE).getString(KEY, null)+ ?: return emptyList()+ return runCatching {+ val arr = JSONArray(raw)+ (0 until arr.length()).map { arr.getJSONObject(it).toRecentItem() }+ }.getOrDefault(emptyList())+}++private fun save(context: Context, items: List<RecentItem>) {+ val arr = JSONArray().also { a -> items.forEach { a.put(it.toJson()) } }+ context.getSharedPreferences(PREF, Context.MODE_PRIVATE)+ .edit().putString(KEY, arr.toString()).apply()+}++fun addRecentItem(context: Context, item: RecentItem) {+ if (item.name.isBlank()) return+ val rest = getRecentItems(context).filterNot { it.type == item.type && it.key == item.key }+ save(context, (listOf(item) + rest).take(MAX_ITEMS))+}++fun removeRecentItem(context: Context, item: RecentItem) {+ save(context, getRecentItems(context).filterNot { it.type == item.type && it.key == item.key })+}++fun clearRecentItems(context: Context) {+ context.getSharedPreferences(PREF, Context.MODE_PRIVATE).edit().remove(KEY).apply()+}diff --git a/base/app/src/main/java/com/music/spotui/data/preferences/SettingsPref.kt b/base/app/src/main/java/com/music/spotui/data/preferences/SettingsPref.ktnew file mode 100644index 00000000..54215617--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/data/preferences/SettingsPref.kt@@ -0,0 +1,27 @@+package com.music.spotui.data.preferences++import android.content.Context++// Trimmed from Spotui: stream quality, crossfade, YouTube and web-playback settings+// are gone (the Web Player engine streams Spotify's own audio).++private const val PREF = "settings_prefs"+private const val KEY_LIBRARY_GRID = "library_grid_view"+private const val KEY_LYRIC_TRANSLATE_LANG = "lyric_translate_lang"+private const val KEY_LYRICS_EXTRA = "lyrics_extra_sources"++/** Word-synced lyrics from third-party Apple Music mirrors (LyricsPlus). Off by default. */+fun isLyricsExtraSources(c: Context): Boolean = prefs(c).getBoolean(KEY_LYRICS_EXTRA, false)+fun setLyricsExtraSources(c: Context, v: Boolean) = prefs(c).edit().putBoolean(KEY_LYRICS_EXTRA, v).apply()++private fun prefs(c: Context) = c.getSharedPreferences(PREF, Context.MODE_PRIVATE)++/** Library layout: false = rows (default), true = Spotify-style 3-column grid. */+fun isLibraryGridView(c: Context): Boolean = prefs(c).getBoolean(KEY_LIBRARY_GRID, false)+fun setLibraryGridView(c: Context, v: Boolean) = prefs(c).edit().putBoolean(KEY_LIBRARY_GRID, v).apply()++fun getLyricTranslateLang(c: Context): String =+ prefs(c).getString(KEY_LYRIC_TRANSLATE_LANG, "").orEmpty()++fun setLyricTranslateLang(c: Context, code: String) =+ prefs(c).edit().putString(KEY_LYRIC_TRANSLATE_LANG, code.trim()).apply()diff --git a/base/app/src/main/java/com/music/spotui/di/AutoBrowser.kt b/base/app/src/main/java/com/music/spotui/di/AutoBrowser.ktnew file mode 100644index 00000000..4fab943c--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/di/AutoBrowser.kt@@ -0,0 +1,146 @@+package com.music.spotui.di++import android.content.Context+import android.net.Uri+import android.os.Bundle+import android.support.v4.media.MediaBrowserCompat.MediaItem+import android.support.v4.media.MediaDescriptionCompat+import app.myspoti.engine.R+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.ContextPageModel+import com.music.spotui.data.entity.SongsModel+import kotlinx.coroutines.flow.first+import kotlinx.coroutines.withTimeoutOrNull++/**+ * Android Auto / media browser tree, built from the app's own data (not the web page):+ * Liked Songs, playlists, albums, followed artists, and search. Tapping a track plays it+ * in its context, the same way the album / playlist screens do.+ *+ * Media ids: "liked", "playlists", "albums", "artists" (lists); "pl:<id>", "al:<id>",+ * "ar:<id>" (contexts); "t|<context uri>|<play key>" (a track to play).+ */+object AutoBrowser {+ const val ROOT = "root"+ private const val TIMEOUT_MS = 15_000L++ // Contexts recently listed, so a tap plays with the right queue.+ private val pages = java.util.concurrent.ConcurrentHashMap<String, ContextPageModel>()++ suspend fun children(context: Context, parentId: String): List<MediaItem> = when {+ parentId == ROOT -> listOf(+ browsable("liked", context.getString(R.string.collection_liked_songs_title), null, grid = false),+ browsable("playlists", context.getString(R.string.aa_playlists), null, grid = false),+ browsable("albums", context.getString(R.string.aa_albums), null, grid = false),+ browsable("artists", context.getString(R.string.aa_artists), null, grid = false),+ )+ parentId == "playlists" || parentId == "albums" -> {+ val wantPlaylists = parentId == "playlists"+ val entries = (firstResult { Graph.api.getLibrary() } ?: emptyList())+ .filter { it.isPlaylist == wantPlaylists && it.spotifyId != com.music.spotui.data.api.Api.HomeCache.LIKED_SONGS_ID }+ entries.map { e ->+ browsable(if (wantPlaylists) "pl:${e.spotifyId}" else "al:${e.spotifyId}", e.name, e.coverUri, subtitle = e.subtitle)+ }+ }+ parentId == "artists" -> Graph.api.getFollowedArtists().filter { it.id.isNotBlank() }.map { a ->+ browsable("ar:${a.id}|${a.name}", a.name, a.coverUri)+ }+ parentId == "liked" -> tracksOf(firstResult { Graph.api.getLikedPage() })+ parentId.startsWith("pl:") -> tracksOf(firstResult { Graph.api.getPlaylistPage(parentId.removePrefix("pl:")) })+ parentId.startsWith("al:") -> tracksOf(firstResult { Graph.api.getAlbumPage(parentId.removePrefix("al:")) })+ parentId.startsWith("ar:") -> {+ val (id, name) = parentId.removePrefix("ar:").split("|", limit = 2).let { it[0] to it.getOrElse(1) { "" } }+ val overview = firstResult { Graph.api.getArtistOverview(name, id) }+ overview?.topTracks?.map { playable("spotify:artist:$id", it.song) }.orEmpty()+ }+ else -> emptyList()+ }++ suspend fun search(query: String): List<MediaItem> {+ val r = firstResult { Graph.api.searchEverything(query) } ?: return emptyList()+ return r.songs.take(20).map { playable("", it) } ++ r.albums.filter { it.spotifyId.isNotBlank() }.take(8).map { browsable("al:${it.spotifyId}", it.name, it.coverUri, subtitle = it.artists) }+ }++ /** Voice search ("play X on Myspoti"): the best matching track. */+ suspend fun playFromSearch(query: String): Boolean {+ val song = (firstResult { Graph.api.searchEverything(query) })?.songs?.firstOrNull() ?: return false+ play("t||${song.url}")+ return true+ }++ fun play(mediaId: String) {+ val parts = mediaId.split("|", limit = 3)+ if (parts.size < 3 || parts[0] != "t") return+ val contextUri = parts[1].ifBlank { null }+ val key = parts[2]+ val page = contextUri?.let { pages[it] }+ val song = page?.tracks?.firstOrNull { it.url == key }+ if (page != null) {+ Graph.currentSongState.updateQueue(page.tracks)+ if (page.type == "liked") SongPlayer.registerLikedSongs(page.tracks.map { it.url })+ }+ SongPlayer.playSong(key, contextUri = contextUri)+ song?.let { Graph.currentSongState.updateSongState(it.coverUri, it.title, it.singer, true, it.id, 0, it.album) }+ }++ private fun tracksOf(page: ContextPageModel?): List<MediaItem> {+ page ?: return emptyList()+ pages[page.uri] = page+ return page.tracks.map { playable(page.uri, it) }+ }++ private suspend fun <T> firstResult(load: suspend () -> kotlinx.coroutines.flow.Flow<Response<T>>): T? =+ withTimeoutOrNull(TIMEOUT_MS) {+ (load().first { it !is Response.Loading } as? Response.Success)?.data+ }++ private fun browsable(id: String, title: String, cover: String?, subtitle: String = "", grid: Boolean = true): MediaItem {+ val extras = Bundle().apply {+ putInt("android.media.browse.CONTENT_STYLE_BROWSABLE_HINT", if (grid) 2 else 1)+ putInt("android.media.browse.CONTENT_STYLE_PLAYABLE_HINT", 1)+ }+ val d = MediaDescriptionCompat.Builder().setMediaId(id).setTitle(title).setSubtitle(subtitle)+ .setIconUri(ArtworkProvider.uriFor(cover)).setExtras(extras).build()+ return MediaItem(d, MediaItem.FLAG_BROWSABLE)+ }++ private fun playable(contextUri: String, s: SongsModel): MediaItem {+ val d = MediaDescriptionCompat.Builder().setMediaId("t|$contextUri|${s.url}")+ .setTitle(s.title).setSubtitle(s.singer).setIconUri(ArtworkProvider.uriFor(s.coverUri)).build()+ return MediaItem(d, MediaItem.FLAG_PLAYABLE)+ }+}++/**+ * Cover art for Android Auto, which only shows local (content://) artwork: serves an+ * image from Spotify's image CDN through Glide's disk cache. Other hosts are refused.+ */+class ArtworkProvider : android.content.ContentProvider() {+ companion object {+ private val AUTHORITY = app.myspoti.engine.BuildConfig.APPLICATION_ID + ".artwork"+ private val allowedHosts = setOf("i.scdn.co", "mosaic.scdn.co", "image-cdn-ak.spotifycdn.com", "image-cdn-fa.spotifycdn.com", "thisis-images.spotifycdn.com", "seeded-session-images.scdn.co", "pickasso.spotifycdn.com")++ fun uriFor(url: String?): Uri? {+ if (url.isNullOrBlank()) return null+ val host = Uri.parse(url).host ?: return null+ if (host !in allowedHosts) return null+ return Uri.Builder().scheme("content").authority(AUTHORITY).appendPath("img").appendQueryParameter("u", url).build()+ }+ }++ override fun openFile(uri: Uri, mode: String): android.os.ParcelFileDescriptor? {+ val url = uri.getQueryParameter("u") ?: return null+ val host = Uri.parse(url).host ?: return null+ if (host !in allowedHosts) return null+ val file = com.bumptech.glide.Glide.with(context!!).asFile().load(url).submit().get()+ return android.os.ParcelFileDescriptor.open(file, android.os.ParcelFileDescriptor.MODE_READ_ONLY)+ }++ override fun getType(uri: Uri) = "image/jpeg"+ override fun onCreate() = true+ override fun query(uri: Uri, p: Array<out String>?, s: String?, a: Array<out String>?, o: String?) = null+ override fun insert(uri: Uri, values: android.content.ContentValues?) = null+ override fun delete(uri: Uri, s: String?, a: Array<out String>?) = 0+ override fun update(uri: Uri, v: android.content.ContentValues?, s: String?, a: Array<out String>?) = 0+}diff --git a/base/app/src/main/java/com/music/spotui/di/CurrentSongState.kt b/base/app/src/main/java/com/music/spotui/di/CurrentSongState.ktnew file mode 100644index 00000000..9709c4a6--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/di/CurrentSongState.kt@@ -0,0 +1,133 @@+package com.music.spotui.di++import androidx.compose.runtime.MutableState+import androidx.compose.runtime.State+import androidx.compose.runtime.mutableStateOf+import com.music.spotui.data.entity.SongsModel++class CurrentSongState constructor() {+ private val _title: MutableState<String> = mutableStateOf("")+ val title: State<String> get() = _title++ private val _album: MutableState<String> = mutableStateOf("")+ val album : State<String> get() = _album++ private val _singer: MutableState<String> = mutableStateOf("")+ val singer: State<String> get() = _singer++ private val _coverUri: MutableState<String> = mutableStateOf("")+ val coverUri: State<String> get() = _coverUri++ private val _playingState: MutableState<Boolean> = mutableStateOf(false)+ val playingState: State<Boolean> get() = _playingState++ private val _songIndex: MutableState<Int> = mutableStateOf(0)+ val songIndex : State<Int> get() = _songIndex++ private val _songId: MutableState<Int> = mutableStateOf(0)+ val songId : State<Int> get() = _songId++ // The actual list the user is playing (album tracks, search results, liked+ // songs…). Next/previous operate on THIS, not on a re-derived global feed.+ private val _queue: MutableState<List<SongsModel>> = mutableStateOf(emptyList())+ val queue: State<List<SongsModel>> get() = _queue++ fun updateQueue(queue: List<SongsModel>) {+ // Playback finds the current track by id, and the queue screen keys rows by+ // id, so a track listed twice (e.g. in a playlist) is queued once.+ val songs = queue.distinctBy { it.id }+ _queue.value = songs+ }++ val shuffle = mutableStateOf(false)+ val repeat = mutableStateOf(false)+ val likeState = mutableStateOf(false)++ // Original queue order, kept while shuffle is on so turning it off restores+ // the list instead of leaving it permanently scrambled.+ private var unshuffledQueue: List<SongsModel>? = null++ /**+ * Toggling shuffle reorders the queue ONCE: the current track stays where it+ * is and the rest follow in random order. (Skipping used to re-shuffle the+ * whole list on every tap, which could repeat or skip songs.)+ */+ fun updateShuffleState(newShuffleState: Boolean) {+ if (newShuffleState == shuffle.value) return+ shuffle.value = newShuffleState+ val q = _queue.value+ if (newShuffleState) {+ unshuffledQueue = q+ val curIdx = q.indexOfFirst { it.id == _songId.value }+ if (curIdx >= 0) {+ _queue.value = listOf(q[curIdx]) ++ q.filterIndexed { i, _ -> i != curIdx }.shuffled()+ _songIndex.value = 0+ } else {+ _queue.value = q.shuffled()+ }+ } else {+ val original = unshuffledQueue+ unshuffledQueue = null+ // Restore only if we're still inside that queue (it may have been+ // replaced by another list while shuffled). Keep tracks appended in+ // the meantime (queue edits, autoplay radio).+ if (original != null && original.any { it.id == _songId.value }) {+ val appended = q.filter { s -> original.none { it.id == s.id } }+ val restored = original + appended+ _queue.value = restored+ val idx = restored.indexOfFirst { it.id == _songId.value }+ if (idx >= 0) _songIndex.value = idx+ }+ }+ }++ /**+ * Starts shuffled playback of a full list (the shuffle button on+ * playlist/album/liked screens): the queue becomes a shuffled copy, shuffle+ * turns on, and the caller plays the returned first track.+ */+ fun startShuffled(songs: List<SongsModel>): SongsModel? {+ if (songs.isEmpty()) return null+ // Spotify shuffles its own context and picks the first track itself; the+ // now-playing state follows the engine (no guessed track shown meanwhile).+ shuffle.value = true+ updateQueue(songs)+ SongPlayer.shufflePlay(songs)+ return null+ }+ fun updateRepeatState(newRepeatState : Boolean){+ repeat.value = newRepeatState+ }++ /** Sync the play/pause state without touching the rest of the now-playing+ * metadata — used to reflect the web player's real state (e.g. after the+ * system notification's pause button) back into the in-app UI. */+ fun updatePlayingState(playing: Boolean) {+ _playingState.value = playing+ }++ fun updateLikeState(newLikeState : Boolean){+ likeState.value = newLikeState+ }++ fun updateSongState(coverUri: String, title: String, singer: String, playingState: Boolean, songId : Int, songIndex : Int, album : String) {+ // The engine re-reports the same track on every state change (pause, like…);+ // only a new track should be persisted / logged / prefetched.+ val newTrack = songId != _songId.value || title != _title.value+ _coverUri.value = coverUri+ _title.value = title+ _album.value = album+ _singer.value = singer+ _playingState.value = playingState+ _songIndex.value = songIndex+ _songId.value = songId+ // Persist the current track so a fresh launch can restore the session.+ if (newTrack && playingState && title.isNotBlank()) {+ _queue.value.firstOrNull { it.id == songId }?.let { track ->+ com.music.spotui.data.preferences.saveLastPlayback(+ com.music.spotui.di.Graph.app, track)+ }+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/di/Graph.kt b/base/app/src/main/java/com/music/spotui/di/Graph.ktnew file mode 100644index 00000000..ce1acb69--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/di/Graph.kt@@ -0,0 +1,34 @@+package com.music.spotui.di++import android.app.Application+import app.myspoti.host.android.MyspotiRuntime+import com.music.spotui.data.api.Api+import com.music.spotui.ui.repository.AppRepository++/** Manual replacement for Spotui's Hilt graph: app-wide singletons. */+object Graph {+ lateinit var app: Application+ private set++ fun init(application: Application) {+ app = application+ // The Spotify session: hidden Web Player + API (operation hashes refresh themselves).+ MyspotiRuntime.start(application)+ com.music.spotui.data.local.ListenHistory.init(application)+ // Downloaded songs (private storage), and the downloads left unfinished last time.+ // Supporter thank-yous (accent colour) before any screen draws.+ com.music.spotui.data.api.SupportReminder.init(application)+ com.music.spotui.data.offline.OfflineStore.init(application)+ com.music.spotui.data.offline.OfflineCollections.init(application)+ com.music.spotui.data.offline.OfflineCollections.refreshAll(application)+ com.music.spotui.data.local.LocalPlaylists.init(application)+ com.music.spotui.data.local.LibraryOrder.init(application)+ com.music.spotui.data.DataSaver.init(application)+ runCatching { com.music.spotui.data.DataSaverGlide.install(application) }+ com.music.spotui.data.offline.OfflineDownloader.resumePending()+ }++ val api: Api by lazy { Api(app) }+ val repository: AppRepository by lazy { AppRepository(api) }+ val currentSongState: CurrentSongState by lazy { CurrentSongState() }+}diff --git a/base/app/src/main/java/com/music/spotui/di/Haptics.kt b/base/app/src/main/java/com/music/spotui/di/Haptics.ktnew file mode 100644index 00000000..62624200--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/di/Haptics.kt@@ -0,0 +1,32 @@+package com.music.spotui.di++import android.os.Build+import android.view.HapticFeedbackConstants+import android.view.View+import java.lang.ref.WeakReference++/** Light, system-native haptics for user actions (respects the system haptics setting). */+object Haptics {+ private var view: WeakReference<View>? = null++ fun attach(v: View) { view = WeakReference(v) }++ private fun perform(constant: Int, fallback: Int = HapticFeedbackConstants.CONTEXT_CLICK) {+ val v = view?.get() ?: return+ // Only while the app is in front (no buzz for notification / headset commands).+ if (v.windowVisibility != View.VISIBLE || !v.hasWindowFocus()) return+ v.post { if (!v.performHapticFeedback(constant)) v.performHapticFeedback(fallback) }+ }++ /** Buttons: play/pause, next/previous, add to queue. */+ fun click() = perform(HapticFeedbackConstants.CONTEXT_CLICK)++ /** Toggles: like, shuffle, repeat. */+ fun toggle(on: Boolean) = perform(+ if (Build.VERSION.SDK_INT >= 34) (if (on) HapticFeedbackConstants.TOGGLE_ON else HapticFeedbackConstants.TOGGLE_OFF)+ else HapticFeedbackConstants.CLOCK_TICK+ )++ /** A completed action (queued, removed, transferred). */+ fun confirm() = perform(HapticFeedbackConstants.CONFIRM)+}diff --git a/base/app/src/main/java/com/music/spotui/di/LibraryState.kt b/base/app/src/main/java/com/music/spotui/di/LibraryState.ktnew file mode 100644index 00000000..ba3eaeee--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/di/LibraryState.kt@@ -0,0 +1,19 @@+package com.music.spotui.di++import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect++/**+ * Saved state of a library item (track in Liked Songs, saved album, followed artist)+ * as Spotify reports it. Every screen reads the same [SongPlayer.library], so a like+ * made anywhere (here or on another device) shows everywhere.+ */+@Composable+fun rememberSaved(uri: String, fallback: Boolean = false): Boolean {+ LaunchedEffect(uri) { SongPlayer.requestSaved(uri) }+ return SongPlayer.library[uri] ?: fallback+}++@Composable+fun rememberTrackSaved(trackId: String): Boolean =+ if (trackId.isBlank()) false else rememberSaved("spotify:track:$trackId")diff --git a/base/app/src/main/java/com/music/spotui/di/LocalPlayer.kt b/base/app/src/main/java/com/music/spotui/di/LocalPlayer.ktnew file mode 100644index 00000000..b671bc22--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/di/LocalPlayer.kt@@ -0,0 +1,78 @@+package com.music.spotui.di++import androidx.compose.runtime.mutableStateOf+import androidx.media3.common.AudioAttributes+import androidx.media3.common.C+import androidx.media3.common.MediaItem+import androidx.media3.common.MediaMetadata+import androidx.media3.common.Player+import androidx.media3.exoplayer.ExoPlayer+import com.music.spotui.data.local.LocalTrack++/**+ * Plays the device's own audio files (Local Files). While it plays, the Spotify engine is+ * paused and SongPlayer routes the controls here (player, mini player, notification);+ * playing anything from Spotify again hands back to the engine.+ */+object LocalPlayer {+ /** Local playback is the current source. */+ val active = mutableStateOf(false)+ private var tracks: List<LocalTrack> = emptyList()+ /** Where the queue comes from (Local Files, Downloaded…), shown in the player. */+ var contextName: String = ""+ private set+ private var exo: ExoPlayer? = null++ private fun player(): ExoPlayer = exo ?: ExoPlayer.Builder(Graph.app)+ .setAudioAttributes(AudioAttributes.Builder().setUsage(C.USAGE_MEDIA).setContentType(C.AUDIO_CONTENT_TYPE_MUSIC).build(), true)+ .setHandleAudioBecomingNoisy(true)+ .build().also { p ->+ p.addListener(object : Player.Listener {+ override fun onEvents(player: Player, events: Player.Events) = publish()+ })+ exo = p+ }++ fun play(list: List<LocalTrack>, index: Int, shuffle: Boolean = false, context: String? = null) {+ if (list.isEmpty()) return+ SongPlayer.pauseEngineForLocal()+ tracks = list+ contextName = context ?: Graph.app.getString(app.myspoti.engine.R.string.local_files_title)+ active.value = true+ val p = player()+ p.setMediaItems(list.map { t ->+ MediaItem.Builder().setUri(t.uri).setMediaId(t.id.toString())+ .setMediaMetadata(MediaMetadata.Builder().setTitle(t.title).setArtist(t.artist).build()).build()+ }, index.coerceIn(0, list.lastIndex), 0L)+ p.shuffleModeEnabled = shuffle+ p.prepare()+ p.play()+ }++ /** Back to Spotify: stop and forget the local queue. */+ fun stop() {+ if (!active.value) return+ active.value = false+ exo?.let { it.stop(); it.clearMediaItems() }+ }++ fun resume() { exo?.play() }+ fun pause() { exo?.pause() }+ fun next() { exo?.let { if (it.hasNextMediaItem()) it.seekToNextMediaItem() } }+ fun previous() { exo?.let { if (it.currentPosition > 3000 || !it.hasPreviousMediaItem()) it.seekTo(0) else it.seekToPreviousMediaItem() } }+ fun seekTo(ms: Long) { exo?.seekTo(ms) }+ fun setShuffle(on: Boolean) { exo?.shuffleModeEnabled = on }+ fun setRepeatMode(mode: Int) {+ exo?.repeatMode = when (mode) { 1 -> Player.REPEAT_MODE_ALL; 2 -> Player.REPEAT_MODE_ONE; else -> Player.REPEAT_MODE_OFF }+ }+ fun isPlaying() = exo?.isPlaying == true+ fun position() = exo?.currentPosition ?: 0L+ fun duration() = exo?.duration?.takeIf { it > 0 } ?: current()?.durationMs ?: 0L+ fun current(): LocalTrack? = exo?.currentMediaItemIndex?.let { tracks.getOrNull(it) }++ private fun publish() {+ if (!active.value) return+ val t = current() ?: return+ SongPlayer.onLocalState(t, exo?.playWhenReady == true, position(), duration())+ }+}diff --git a/base/app/src/main/java/com/music/spotui/di/Palette.kt b/base/app/src/main/java/com/music/spotui/di/Palette.ktnew file mode 100644index 00000000..248df757--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/di/Palette.kt@@ -0,0 +1,95 @@+package com.music.spotui.di++import android.content.Context+import android.graphics.Bitmap+import android.graphics.drawable.Drawable+import androidx.compose.ui.graphics.Color+import androidx.palette.graphics.Palette+import com.bumptech.glide.Glide+import com.bumptech.glide.request.target.CustomTarget+import com.bumptech.glide.request.transition.Transition++class Palette {+ companion object {+ // Cover colours already computed (process-wide): a screen opening on a known+ // cover gets its colour in the first frame instead of popping in afterwards.+ private val colors = java.util.Collections.synchronizedMap(object : java.util.LinkedHashMap<String, Color>(64, 0.75f, true) {+ override fun removeEldestEntry(eldest: MutableMap.MutableEntry<String, Color>?) = size > 200+ })+ fun cachedSecond(imageUrl: String): Color? = colors["2|$imageUrl"]+ fun cachedFirst(imageUrl: String): Color? = colors["1|$imageUrl"]+ }++// fun extractColorFromImageUrl(context: Context, imageUrl: String, onPaletteGenerated: (Palette) -> Unit) {+// Glide.with(context)+// .asBitmap()+// .load(imageUrl)+// .into(object : CustomTarget<Bitmap>() {+// override fun onResourceReady(resource: Bitmap, transition: Transition<in Bitmap>?) {+// Palette.from(resource).generate { palette ->+// palette?.let { onPaletteGenerated(it) }+// }+// }+//+// override fun onLoadCleared(placeholder: Drawable?) {+// // Handle cleanup here if necessary+// }+// })+// }++ fun extractFirstColorFromImageUrl(context: Context, imageUrl: String, onColorExtracted: (Color) -> Unit) {+ val key = "1|$imageUrl"+ colors[key]?.let { onColorExtracted(it); return }+ Glide.with(context)+ .asBitmap()+ .load(imageUrl)+ .override(64, 64)+ .disallowHardwareConfig()+ .into(object : CustomTarget<Bitmap>() {+ override fun onResourceReady(resource: Bitmap, transition: Transition<in Bitmap>?) {+ Palette.from(resource).generate { palette ->+ val dominantColor = palette?.darkVibrantSwatch?.rgb+ dominantColor?.let {+ // Convert RGB color integer to ARGB color integer with full opacity+ val argbColor = Color(it or (0xFF shl 24))+ colors[key] = argbColor; onColorExtracted(argbColor)+ }+ }+ }++ override fun onLoadCleared(placeholder: Drawable?) {+ // Handle cleanup here if necessary+ }+ })+ }+ fun extractSecondColorFromCoverUrl(context: Context, imageUrl: String, onColorExtracted: (Color) -> Unit) {+ val key = "2|$imageUrl"+ colors[key]?.let { onColorExtracted(it); return }+ Glide.with(context)+ .asBitmap()+ .load(imageUrl)+ .override(64, 64)+ .disallowHardwareConfig()+ .into(object : CustomTarget<Bitmap>() {+ override fun onResourceReady(resource: Bitmap, transition: Transition<in Bitmap>?) {+ // Create a scaled down version of the bitmap+ val scaledBitmap = Bitmap.createScaledBitmap(resource, 50, 50, true)++ Palette+ .from(scaledBitmap)+ .generate { palette ->+ val lightVibrantColor = palette?.mutedSwatch?.rgb+ lightVibrantColor?.let {+ // Convert RGB color integer to ARGB color integer with full opacity+ val argbColor = Color(it or (0xFF shl 24))+ colors[key] = argbColor; onColorExtracted(argbColor)+ }+ }+ }++ override fun onLoadCleared(placeholder: Drawable?) {+ // Handle cleanup here if necessary+ }+ })+ }+}\ No newline at end of filediff --git a/base/app/src/main/java/com/music/spotui/di/SessionActions.kt b/base/app/src/main/java/com/music/spotui/di/SessionActions.ktnew file mode 100644index 00000000..5cc54bbd--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/di/SessionActions.kt@@ -0,0 +1,21 @@+package com.music.spotui.di++import app.myspoti.host.android.MyspotiRuntime+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.StateFlow++/** Session-wide actions the screens trigger. */+object SessionActions {+ private val _signedOut = MutableStateFlow(false)+ /** True from a logout until the next sign-in: the activity shows the login page, then starts over. */+ val signedOut: StateFlow<Boolean> = _signedOut++ /** Signs out of Spotify in the Web Player; the login page shows next. */+ fun logout() {+ _signedOut.value = true+ MyspotiRuntime.host.logout()+ }++ /** The new account is signed in. */+ fun signedIn() { _signedOut.value = false }+}diff --git a/base/app/src/main/java/com/music/spotui/di/SongPlayer.kt b/base/app/src/main/java/com/music/spotui/di/SongPlayer.ktnew file mode 100644index 00000000..c5fa0efb--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/di/SongPlayer.kt@@ -0,0 +1,835 @@+package com.music.spotui.di++import android.content.Context+import android.os.Handler+import android.os.Looper+import android.os.SystemClock+import android.util.Log+import androidx.compose.runtime.State+import androidx.compose.runtime.mutableStateOf+import app.myspoti.api.ItemKind+import app.myspoti.api.MyspotiApi+import app.myspoti.api.PlayerState+import app.myspoti.api.Repeat+import app.myspoti.host.android.MyspotiRuntime+import app.myspoti.host.android.NowPlayingInfo+import app.myspoti.host.android.PlaybackService+import com.music.spotui.data.entity.SongsModel+import kotlinx.coroutines.launch+import java.util.concurrent.ConcurrentHashMap++/**+ * The UI's player facade over [MyspotiApi.player].+ *+ * Screens call playSong / play / pause / seekTo / getCurrentPosition… as before; every+ * command goes to the Web Player through the API, and the state comes back from its+ * flows. Spotify owns the queue, so next/previous/shuffle/repeat are Spotify's.+ * Local Files play in [LocalPlayer]; the controls route there while it is active.+ */+object SongPlayer {+ private const val SPOTIFY_TRACK_PREFIX = "spotify:track:"+ private const val PENDING_MS = 6000L+ private const val TAG = "MspPlayer"+ private const val LIKED_CONTEXT = "spotify:collection:tracks"++ private val api: MyspotiApi get() = MyspotiRuntime.api+ private val scope get() = MyspotiRuntime.scope++ // ── Player state ──+ @Volatile private var playing = false+ private val bufferingState = mutableStateOf(false)+ /** Observable startup state: visual lookups wait for the audio transport. */+ val isBuffering: Boolean get() = bufferingState.value+ @Volatile private var durationMs = 0L+ @Volatile private var positionMs = 0L+ @Volatile private var positionAt = 0L+ @Volatile var currentTrackId: String = ""+ private set+ @Volatile var currentContextUri: String = ""+ private set+ @Volatile private var stateSeen = false++ // A track the user just picked: the player reports the previous one for a moment,+ // which must not overwrite the optimistic now-playing state.+ @Volatile private var pendingTrackId: String? = null+ @Volatile private var pendingItemUri: String? = null+ @Volatile private var pendingUntil = 0L++ // After play / pause the player reports the old state for a moment; keep the requested one.+ @Volatile private var wantPlayingUntil = 0L+ @Volatile private var wantPausedUntil = 0L++ private fun intendPlaying() { wantPlayingUntil = SystemClock.elapsedRealtime() + 4000; wantPausedUntil = 0 }+ private fun intendPaused() { wantPausedUntil = SystemClock.elapsedRealtime() + 1500; wantPlayingUntil = 0 }++ private fun resolvePlaying(paused: Boolean): Boolean {+ val now = SystemClock.elapsedRealtime()+ if (now < wantPlayingUntil) {+ if (!paused) wantPlayingUntil = 0+ return true+ }+ if (now < wantPausedUntil) {+ if (paused) wantPausedUntil = 0+ return false+ }+ return !paused+ }++ // Context (album/playlist/artist/liked) a track was listed in, so playing it keeps+ // Spotify's own queue and autoplay for that context.+ private val contextRegistry = ConcurrentHashMap<String, String>()++ @Volatile var currentSource: String = "Spotify"+ @Volatile var currentQuality: String = ""++ /** Spotify's real queue. */+ data class QueueItem(val song: SongsModel, val uri: String, val uid: String, val provider: String)+ data class EngineQueue(+ val current: SongsModel? = null,+ val queued: List<QueueItem> = emptyList(),+ val nextUp: List<QueueItem> = emptyList(),+ )+ private val _queue = mutableStateOf(EngineQueue())+ private var apiQueue: app.myspoti.api.Queue? = null++ /** What the now-playing screen needs beyond the track itself. */+ data class NowPlaying(+ val contextUri: String = "",+ val contextName: String = "",+ val provider: String = "",+ val uri: String = "",+ val explicit: Boolean = false,+ val albumUri: String = "",+ val prev: SongsModel? = null,+ val next: SongsModel? = null,+ )+ private val _nowPlaying = mutableStateOf(NowPlaying())+ val nowPlaying: State<NowPlaying> get() = _nowPlaying+ val engineQueue: State<EngineQueue> get() = _queue++ private val main = Handler(Looper.getMainLooper())+ private var boundState: CurrentSongState? = null++ /** Wires the API's flows into the UI's now-playing state. Call once, on the main thread. */+ fun attachEngine(state: CurrentSongState) {+ boundState = state+ com.music.spotui.data.api.LyricsApi.extraSources =+ com.music.spotui.data.preferences.isLyricsExtraSources(Graph.app)+ restoreLastTrack(state)+ scope.launch { api.player.state.collect { s -> if (acceptsSessionUpdates()) applyState(s) } }+ scope.launch { api.player.queue.collect { q -> if (acceptsSessionUpdates()) applyQueue(q) } }+ scope.launch { api.library.changes.collect { refreshCurrentLiked() } }+ PlaybackService.controls = Controls+ }++ /** System controls (notification, headset, car) land here. */+ private object Controls : app.myspoti.host.android.PlaybackControls {+ override fun play() = SongPlayer.play()+ override fun pause() = SongPlayer.pause()+ override fun next() = SongPlayer.next()+ override fun previous() = SongPlayer.previous()+ override fun seekTo(ms: Long) = SongPlayer.seekTo(ms)+ override fun setLiked(liked: Boolean) = SongPlayer.setLiked(liked)+ override fun playFromMediaId(mediaId: String) = AutoBrowser.play(mediaId)+ override fun playFromSearch(query: String) { scope.launch { AutoBrowser.playFromSearch(query) } }+ override fun setRemoteVolume(volume: Int) = SongPlayer.setRemoteVolume(volume)+ }++ // ── Last track: shown at launch (mini player) before the Web Player reports ──++ private fun lastTrackPrefs() = Graph.app.getSharedPreferences("myspoti_last_track", Context.MODE_PRIVATE)+ private var savedLast = ""+ @Volatile private var resumeWhenReady = false++ private fun restoreLastTrack(state: CurrentSongState) {+ if (state.title.value.isNotBlank() || !acceptsSessionUpdates()) return+ val p = lastTrackPrefs()+ val uri = p.getString("uri", "").orEmpty()+ val title = p.getString("title", "").orEmpty()+ if (uri.isBlank() || title.isBlank()) return+ val id = trackIdOf(uri)+ currentTrackId = id+ durationMs = p.getLong("duration", 0L)+ positionMs = p.getLong("position", 0L)+ positionAt = SystemClock.elapsedRealtime()+ playing = false+ _nowPlaying.value = NowPlaying(uri = uri)+ state.updateSongState(+ coverUri = p.getString("cover", "").orEmpty(),+ title = title,+ singer = p.getString("singer", "").orEmpty(),+ playingState = false,+ songId = songIdFor(id, uri),+ songIndex = 0,+ album = p.getString("album", "").orEmpty(),+ )+ state.likeState.value = p.getBoolean("liked", false)+ }++ /** Saved on track change and on play/pause (not on every state). */+ private fun saveLastTrack(song: SongsModel, uri: String, liked: Boolean) {+ val key = "$uri|$playing|$liked"+ if (uri.isBlank() || key == savedLast) return+ savedLast = key+ lastTrackPrefs().edit()+ .putString("uri", uri).putString("title", song.title).putString("singer", song.singer)+ .putString("album", song.album).putString("cover", song.coverUri)+ .putLong("duration", durationMs).putLong("position", getCurrentPosition())+ .putBoolean("liked", liked)+ .apply()+ }++ private fun acceptsSessionUpdates() = Graph.app.getSharedPreferences("myspoti_prefs", Context.MODE_PRIVATE)+ .getBoolean("LoggedIn", false)++ /** Call on the main thread before navigating to logout. */+ fun clearSession() {+ main.removeCallbacksAndMessages(null)+ pendingTrackId = null+ pendingItemUri = null+ pendingUntil = 0L+ intentUri = ""; intentUntil = 0L+ wantPlayingUntil = 0L; wantPausedUntil = 0L+ stateSeen = false+ playing = false; bufferingState.value = false; durationMs = 0L; positionMs = 0L+ currentTrackId = ""; currentContextUri = ""+ contextRegistry.clear(); library.clear()+ synchronized(wantedSaved) { wantedSaved.clear() }+ _queue.value = EngineQueue(); apiQueue = null; _nowPlaying.value = NowPlaying()+ lastTrackPrefs().edit().clear().apply(); savedLast = ""; resumeWhenReady = false+ _activeDevice.value = null; _sleepEndsAt.value = null; sleepTrackId = null+ _video.value = VideoState(); videoFullscreen.value = false+ boundState?.let { state ->+ state.updateQueue(emptyList())+ state.updateSongState("", "", "", false, 0, 0, "")+ state.likeState.value = false+ }+ }++ private fun trackIdOf(uri: String) = uri.removePrefix(SPOTIFY_TRACK_PREFIX).takeIf { uri.startsWith(SPOTIFY_TRACK_PREFIX) }.orEmpty()++ private fun songIdFor(trackId: String, fallback: String) =+ (if (trackId.isNotBlank()) "track:$trackId" else "uri:$fallback").hashCode() and 0x7fffffff++ private fun songOf(n: app.myspoti.api.NowPlaying): SongsModel {+ val id = trackIdOf(n.uri)+ val artists = n.artists.joinToString(", ") { it.name }+ return SongsModel(+ id = songIdFor(id, n.uri),+ title = n.name,+ album = n.album?.name.orEmpty(),+ singer = artists,+ coverUri = n.imageUrl.orEmpty(),+ url = if (n.kind == ItemKind.EPISODE) "episode:" + n.uri.substringAfterLast(':') else buildSpotifyPlayQuery(id, n.name, artists),+ spotifyTrackId = id,+ explicit = n.explicit,+ durationMs = n.durationMs.toInt(),+ albumId = n.album?.uri?.substringAfterLast(':').orEmpty(),+ )+ }++ /** Notification, lock screen, Bluetooth and Android Auto. */+ private fun pushNotification(song: SongsModel?, liked: Boolean) {+ val st = boundState+ PlaybackService.update(Graph.app, NowPlayingInfo(+ id = _nowPlaying.value.uri,+ title = song?.title ?: st?.title?.value.orEmpty(),+ artist = song?.singer ?: st?.singer?.value.orEmpty(),+ album = song?.album ?: st?.album?.value.orEmpty(),+ coverUrl = song?.coverUri ?: st?.coverUri?.value,+ durationMs = getDuration(),+ positionMs = getCurrentPosition(),+ playing = isPlaying(),+ buffering = isBuffering,+ liked = liked,+ ))+ com.music.spotui.widget.NowPlayingWidget.show(Graph.app,+ title = song?.title ?: st?.title?.value.orEmpty(),+ artist = song?.singer ?: st?.singer?.value.orEmpty(),+ coverUrl = song?.coverUri ?: st?.coverUri?.value,+ playing = isPlaying())+ }++ private fun applyState(s: PlayerState?) {+ if (s == null) return+ stateSeen = true+ if (LocalPlayer.active.value) return+ if (resumeWhenReady) {+ resumeWhenReady = false+ // The Web Player restored the last session paused: play what was tapped.+ if (s.isPaused) command { api.player.resume() }+ }+ val item = s.item+ val uri = item?.uri.orEmpty()+ val id = trackIdOf(uri)+ val pending = pendingTrackId+ if (pending != null) {+ // Rapid A -> B -> C picks can report B while C is pending: keep C until it shows up.+ if (id == pending || pendingItemUri == uri || SystemClock.elapsedRealtime() > pendingUntil) {+ pendingTrackId = null+ pendingItemUri = null+ } else return+ }+ val wasPlaying = playing+ val wasBuffering = isBuffering+ val predicted = getCurrentPosition()+ bufferingState.value = s.isBuffering+ playing = resolvePlaying(s.isPaused)+ durationMs = item?.durationMs ?: 0L+ val reported = s.positionAt(System.currentTimeMillis())+ // Keep the running clock when the player only nudges it (< 1 s).+ if (!(wasPlaying && playing && !wasBuffering && !isBuffering && kotlin.math.abs(reported - predicted) < 1000)) {+ positionMs = reported+ positionAt = SystemClock.elapsedRealtime()+ }+ val trackChanged = uri != _nowPlaying.value.uri+ currentContextUri = s.contextUri.orEmpty()+ if (item != null) { checkEndOfTrackTimer(id); currentTrackId = id }+ _nowPlaying.value = NowPlaying(+ contextUri = s.contextUri.orEmpty(),+ contextName = s.contextName.orEmpty(),+ provider = "",+ uri = uri,+ explicit = item?.explicit == true,+ albumUri = item?.album?.uri.orEmpty(),+ prev = s.previous?.let(::songOf),+ next = s.next?.let(::songOf),+ )+ val state = boundState ?: return+ state.shuffle.value = s.shuffle+ _repeatMode.value = s.repeat.ordinal+ state.repeat.value = s.repeat != Repeat.OFF+ if (item == null) {+ state.updatePlayingState(playing)+ pushNotification(null, state.likeState.value)+ return+ }+ val liked = likedFor(uri, library[uri] ?: false)+ state.likeState.value = liked+ val song = songOf(item)+ state.updateSongState(+ coverUri = song.coverUri,+ title = song.title,+ singer = song.singer,+ playingState = playing,+ songId = song.id,+ songIndex = state.queue.value.indexOfFirst { it.id == song.id }.coerceAtLeast(0),+ album = song.album,+ )+ pushNotification(song, liked)+ saveLastTrack(song, uri, liked)+ trackListen(uri, song, com.music.spotui.data.local.ListenHistory.Source.SPOTIFY, playing)+ if (trackChanged) {+ refreshCurrentLiked()+ refreshDevice()+ }+ val mv = com.music.spotui.video.MusicVideoController+ mv.onAudioBuffering(isBuffering, song.spotifyTrackId)+ if (!isBuffering && playing && mv.inForeground && (app.myspoti.power.EnergySettings.state.value.policy.allowBackgroundLookups || mv.wantVideo) && song.spotifyTrackId.isNotBlank())+ com.music.spotui.video.MusicVideoController.prepare(song.spotifyTrackId, song.title, song.singer, durationMs)+ if (!isBuffering && playing && mv.inForeground && app.myspoti.power.EnergySettings.state.value.policy.allowBackgroundLookups) {+ com.music.spotui.data.api.LyricsApi.prefetch(lyricsTrack(song))+ _nowPlaying.value.next?.let { com.music.spotui.data.api.LyricsApi.prefetch(lyricsTrack(it)) }+ }+ }++ private fun refreshCurrentLiked() {+ val uri = _nowPlaying.value.uri.takeIf { it.startsWith(SPOTIFY_TRACK_PREFIX) || it.startsWith("spotify:episode:") } ?: return+ scope.launch {+ val saved = runCatching { api.library.contains(listOf(uri)).single() }.getOrNull() ?: return@launch+ onLibraryItem(uri, saved)+ }+ }++ private fun applyQueue(q: app.myspoti.api.Queue?) {+ apiQueue = q+ if (q == null) return+ fun items(list: List<app.myspoti.api.NowPlaying>) = list+ .filter { it.uri.startsWith("spotify:track:") || it.uri.startsWith("spotify:episode:") }+ .map { QueueItem(songOf(it), it.uri, it.uid.orEmpty(), "") }+ _queue.value = EngineQueue(+ current = q.current?.let(::songOf),+ queued = items(q.queued),+ nextUp = items(q.nextUp),+ )+ }++ // ── Listen history (in-app recap) ──+ private var listenKey = ""+ private var listenSong: SongsModel? = null+ private var listenSource = com.music.spotui.data.local.ListenHistory.Source.SPOTIFY+ private var listenPlayedMs = 0L+ private var listenTickAt = 0L+ private var listenWasPlaying = false++ /** Adds the time played since the last call; a new [key] closes the previous listen. */+ private fun trackListen(key: String, song: SongsModel?, source: com.music.spotui.data.local.ListenHistory.Source, isPlaying: Boolean) {+ val now = SystemClock.elapsedRealtime()+ if (listenWasPlaying && listenTickAt > 0) listenPlayedMs += now - listenTickAt+ if (key != listenKey) {+ listenSong?.let { s ->+ com.music.spotui.data.local.ListenHistory.record(com.music.spotui.data.local.ListenHistory.Listen(+ System.currentTimeMillis(), listenKey, s.title, s.singer, s.album, s.coverUri, listenPlayedMs, listenSource,+ ))+ }+ listenKey = key; listenSong = song; listenSource = source; listenPlayedMs = 0+ }+ listenTickAt = now+ listenWasPlaying = isPlaying+ }++ // ── Commands ──++ /** Runs an API call off the caller, logging failures instead of crashing the UI. */+ private fun command(block: suspend () -> Unit) {+ scope.launch {+ runCatching { block() }.onFailure { Log.w(TAG, "command failed: ${it.message}") }+ }+ }++ /** Remember the Spotify context the given play keys belong to. */+ fun registerContext(urls: List<String>, contextUri: String) {+ urls.forEach { contextRegistry[it] = contextUri }+ }++ /** Liked Songs plays as its own context: Spotify maps it to the account's liked list. */+ fun registerLikedSongs(urls: List<String>) = registerContext(urls, LIKED_CONTEXT)++ private fun markPending(trackId: String, itemUri: String? = trackId.takeIf { it.isNotBlank() }?.let { SPOTIFY_TRACK_PREFIX + it }) {+ pendingItemUri = itemUri+ bufferingState.value = true+ itemUri?.let { boundState?.likeState?.value = library[it] ?: false }+ intendPlaying()+ pendingTrackId = trackId+ pendingUntil = SystemClock.elapsedRealtime() + PENDING_MS+ playing = true+ positionMs = 0+ positionAt = SystemClock.elapsedRealtime()+ }++ /**+ * Play [song] (a play key "spotify:track:<id>|<text>" or "episode:<id>"). [contextUri] is+ * the list it was picked from; when null, the last list that registered this track is used.+ */+ fun playSong(song: String, context: Context? = null, contextUri: String? = null) {+ // Data saver on mobile data: Spotify can't stream, only downloads and Local Files play.+ if (com.music.spotui.data.DataSaver.active) {+ main.post {+ android.widget.Toast.makeText(Graph.app, app.myspoti.engine.R.string.data_saver_blocked, android.widget.Toast.LENGTH_SHORT).show()+ }+ return+ }+ LocalPlayer.stop()+ val episodeId = song.removePrefix("episode:").takeIf { song.startsWith("episode:") }+ val trackId = episodeId ?: spotifyTrackIdForPlayback(song) ?: return+ val itemUri = if (episodeId != null) "spotify:episode:$episodeId" else SPOTIFY_TRACK_PREFIX + trackId+ val ctx = contextUri ?: contextRegistry[song]+ markPending(if (episodeId != null) "" else trackId, itemUri)+ command {+ if (ctx != null) api.player.play(ctx, trackUri = itemUri)+ else api.player.play(itemUri)+ }+ }++ fun play() {+ if (LocalPlayer.active.value) { Haptics.click(); LocalPlayer.resume(); return }+ Haptics.click(); intendPlaying(); playing = true; positionAt = SystemClock.elapsedRealtime()+ // Tapped on the restored mini player while the Web Player is still loading.+ if (!stateSeen) resumeWhenReady = true+ command { api.player.resume() }+ }++ fun pause() { Haptics.click(); pauseSilently() }++ private fun pauseSilently() {+ if (LocalPlayer.active.value) { LocalPlayer.pause(); return }+ intendPaused()+ positionMs = getCurrentPosition(); positionAt = SystemClock.elapsedRealtime(); playing = false+ command { api.player.pause() }+ }++ fun stop() = pause()+ fun next() { Haptics.click(); if (LocalPlayer.active.value) { LocalPlayer.next(); return }; intendPlaying(); command { api.player.next() } }+ fun previous() { Haptics.click(); if (LocalPlayer.active.value) { LocalPlayer.previous(); return }; intendPlaying(); command { api.player.previous() } }++ /** Shuffle-play a list: Spotify picks the first track of its own shuffled context. */+ fun shufflePlay(songs: List<SongsModel>) {+ if (songs.isEmpty()) return+ LocalPlayer.stop()+ val ctx = contextRegistry[songs.first().url]+ intendPlaying()+ command {+ api.player.setShuffle(true)+ if (ctx == null) playSong(songs.random().url) else api.player.play(ctx)+ // A play command may reset the options: make sure shuffle sticks.+ kotlinx.coroutines.delay(1500)+ api.player.setShuffle(true)+ }+ }++ fun setShuffle(on: Boolean) { Haptics.toggle(on); if (LocalPlayer.active.value) { LocalPlayer.setShuffle(on); return }; command { api.player.setShuffle(on) } }++ /** 0 = off, 1 = context, 2 = track. */+ private val _repeatMode = mutableStateOf(0)+ val repeatMode: State<Int> get() = _repeatMode++ fun setRepeat(on: Boolean) = setRepeatMode(if (on) 1 else 0)++ fun setRepeatMode(mode: Int) {+ if (LocalPlayer.active.value) { _repeatMode.value = mode; LocalPlayer.setRepeatMode(mode); return }+ Haptics.toggle(mode != 0)+ _repeatMode.value = mode+ boundState?.repeat?.value = mode != 0+ command { api.player.setRepeat(Repeat.entries[mode.coerceIn(0, 2)]) }+ }++ fun cycleRepeat() = setRepeatMode((_repeatMode.value + 1) % 3)++ /** Podcast playback speed (Spotify refuses it on music). */+ fun setSpeed(speed: Double) = command { api.player.setSpeed(speed) }++ fun lyricsTrack(s: SongsModel) = com.music.spotui.data.api.LyricsApi.Track(+ trackId = s.spotifyTrackId, title = s.title, artist = s.singer, album = s.album,+ durationMs = s.durationMs.toLong().takeIf { it > 0 } ?: durationMs, coverUrl = s.coverUri,+ )++ /** The lyrics request for what is playing now. */+ fun currentLyricsTrack(): com.music.spotui.data.api.LyricsApi.Track? {+ val st = boundState ?: return null+ val title = st.title.value+ if (title.isBlank()) return null+ return com.music.spotui.data.api.LyricsApi.Track(+ trackId = currentTrackId, title = title, artist = st.singer.value, album = st.album.value,+ durationMs = durationMs, coverUrl = st.coverUri.value,+ )+ }++ /** Save / remove the current track in Liked Songs. */+ fun setLiked(on: Boolean) {+ if (LocalPlayer.active.value) return // a local file is not in the Spotify library+ Haptics.toggle(on)+ val uri = pendingItemUri ?: _nowPlaying.value.uri.ifBlank { if (currentTrackId.isNotBlank()) SPOTIFY_TRACK_PREFIX + currentTrackId else "" }+ if (uri.isBlank()) { boundState?.likeState?.value = on; return }+ setSaved(uri, on)+ }++ // ── Library state (Liked Songs, saved albums / playlists, followed artists) ──+ /** What Spotify's library says about each uri seen so far; every screen reads this. */+ val library: androidx.compose.runtime.snapshots.SnapshotStateMap<String, Boolean> =+ androidx.compose.runtime.mutableStateMapOf()++ // The user's last like/unlike wins briefly over states that were already in flight.+ @Volatile private var intentUri = ""+ @Volatile private var intentValue = false+ @Volatile private var intentUntil = 0L++ private fun likedFor(uri: String, reported: Boolean): Boolean =+ if (uri == intentUri && SystemClock.elapsedRealtime() < intentUntil) intentValue else reported++ private fun onLibraryItem(uri: String, saved: Boolean) {+ if (uri == intentUri && SystemClock.elapsedRealtime() < intentUntil && saved != intentValue) return+ library[uri] = saved+ if (uri == (pendingItemUri ?: _nowPlaying.value.uri)) {+ boundState?.likeState?.value = saved+ pushNotification(null, saved)+ }+ if (!saved && uri.startsWith(SPOTIFY_TRACK_PREFIX)) {+ val id = trackIdOf(uri)+ com.music.spotui.data.api.Api.LikedCache.tracks =+ com.music.spotui.data.api.Api.LikedCache.tracks?.filterNot { it.spotifyTrackId == id }+ }+ }++ // Rows ask for their saved state one by one; ask Spotify in one batch per frame.+ private val wantedSaved = java.util.Collections.synchronizedSet(LinkedHashSet<String>())+ private val flushSaved = Runnable {+ val uris = synchronized(wantedSaved) { wantedSaved.toList().also { wantedSaved.clear() } }+ if (uris.isNotEmpty()) scope.launch { uris.chunked(50).forEach { libraryContains(it) } }+ }++ /** Make sure [uri]'s saved state ends up in [library]. */+ fun requestSaved(uri: String) {+ if (uri.isBlank() || library.containsKey(uri)) return+ if (wantedSaved.add(uri)) { main.removeCallbacks(flushSaved); main.postDelayed(flushSaved, 32) }+ }++ /** Swipe to the next track: show it right away, then skip. */+ fun swipeNext() {+ if (LocalPlayer.active.value) { next(); return }+ _nowPlaying.value.next?.let { n ->+ markPending(n.spotifyTrackId)+ boundState?.updateSongState(n.coverUri, n.title, n.singer, true, n.id, 0, n.album)+ durationMs = n.durationMs.toLong()+ pushNotification(n, false)+ }+ next()+ }++ fun seekTo(ms: Long) {+ if (LocalPlayer.active.value) { LocalPlayer.seekTo(ms); return }+ positionMs = ms+ positionAt = SystemClock.elapsedRealtime()+ command { api.player.seek(ms) }+ }++ /** Which of [uris] are saved in the user's library (Liked Songs / saved albums…). */+ suspend fun libraryContains(uris: List<String>): Set<String> {+ if (uris.isEmpty()) return emptySet()+ val flags = runCatching { api.library.contains(uris) }.getOrNull() ?: return emptySet()+ val saved = uris.filterIndexed { i, _ -> flags.getOrNull(i) == true }.toSet()+ main.post {+ for (u in uris) {+ if (u == intentUri && SystemClock.elapsedRealtime() < intentUntil) continue+ library[u] = u in saved+ }+ }+ return saved+ }++ /** Like / unlike a track by id. */+ fun setTrackSaved(trackId: String, on: Boolean) {+ if (trackId.isBlank()) return+ Haptics.toggle(on)+ setSaved(SPOTIFY_TRACK_PREFIX + trackId, on)+ }++ /** Save / remove any item (album, playlist, track, artist, show, episode) in the user's library. */+ fun setSaved(uri: String, on: Boolean) {+ intentUri = uri+ intentValue = on+ intentUntil = SystemClock.elapsedRealtime() + 3000+ onLibraryItem(uri, on)+ command {+ if (uri.startsWith("spotify:playlist:")) {+ if (on) api.playlists.follow(uri) else api.playlists.unfollow(uri)+ } else {+ if (on) api.library.add(listOf(uri)) else api.library.remove(listOf(uri))+ }+ }+ }++ // ── Music video: Spotify's own clips are not played by this engine; the YouTube+ // clips (MusicVideoController) are. These keep the player screen's contract. ──+ data class VideoState(val available: Boolean = false, val on: Boolean = false, val ready: Boolean = false, val aspect: Float = 0f, val placed: Boolean = false)+ private val _video = mutableStateOf(VideoState())+ val video: State<VideoState> get() = _video++ data class VideoSlot(val left: Float, val top: Float, val width: Float, val height: Float, val visible: android.graphics.RectF)+ val videoSlot = mutableStateOf<VideoSlot?>(null)+ @Volatile var videoSlotOwner: Any? = null+ val videoFullscreen = mutableStateOf(false)++ fun setVideo(on: Boolean) {+ _video.value = _video.value.copy(on = false, ready = false)+ videoFullscreen.value = false+ }++ val engineBounds = mutableStateOf<IntArray?>(null)++ fun setVideoLayout(mode: String?, x: Float = 0f, y: Float = 0f, w: Float = 0f, h: Float = 0f, viewW: Float = 0f) {}++ // ── Spotify Connect ──+ data class ConnectDevice(val id: String, val name: String, val type: String, val isSelf: Boolean, val isActive: Boolean)++ private val _activeDevice = mutableStateOf<ConnectDevice?>(null)+ /** The device currently playing, when known and not this one. */+ val activeDevice: State<ConnectDevice?> get() = _activeDevice++ private fun refreshDevice() {+ scope.launch {+ runCatching { api.devices.refresh() }+ val active = api.devices.devices.value.firstOrNull { it.active }+ _activeDevice.value = active?.takeIf { !it.local }?.let { ConnectDevice(it.id, it.name, it.type, false, true) }+ active?.volume?.let { if (SystemClock.elapsedRealtime() > volumeHoldUntil) remoteVolume = (it * 100).toInt().coerceIn(0, 100) }+ PlaybackService.setPlaybackDevice(_activeDevice.value != null, remoteVolume)+ }+ }++ /** Devices of the account, this phone first. */+ suspend fun devices(): List<ConnectDevice> {+ runCatching { api.devices.refresh() }+ val list = api.devices.devices.value.map { ConnectDevice(it.id, it.name, it.type, it.local, it.active) }+ .sortedWith(compareByDescending<ConnectDevice> { it.isSelf }.thenBy { it.name })+ _activeDevice.value = list.firstOrNull { it.isActive && !it.isSelf }+ return list+ }++ /** Move playback to [device] (Spotify Connect transfer). */+ fun transferTo(device: ConnectDevice) {+ Haptics.confirm()+ _activeDevice.value = if (device.isSelf) null else device+ command { if (device.isSelf) api.devices.pullHere() else api.devices.transfer(device.id) }+ }++ /** Volume (0..100) of the device that plays, as last reported. */+ @Volatile var remoteVolume = 100+ private set+ @Volatile private var volumeHoldUntil = 0L++ /** Set the volume of the device that plays (volume keys, system slider). */+ fun setRemoteVolume(volume: Int) {+ remoteVolume = volume.coerceIn(0, 100)+ volumeHoldUntil = SystemClock.elapsedRealtime() + 1500+ command { api.player.setVolume(remoteVolume / 100.0) }+ PlaybackService.setPlaybackDevice(_activeDevice.value != null, remoteVolume)+ }++ // ── Sleep timer ──+ private val _sleepEndsAt = mutableStateOf<Long?>(null) // elapsedRealtime, or -1 = end of track+ val sleepEndsAt: State<Long?> get() = _sleepEndsAt+ private val sleepRunnable = Runnable { _sleepEndsAt.value = null; pauseSilently() }+ private var sleepTrackId: String? = null++ /** [minutes] null = off, 0 = at the end of the current track. */+ fun setSleepTimer(minutes: Int?) {+ main.removeCallbacks(sleepRunnable)+ sleepTrackId = null+ when {+ minutes == null -> _sleepEndsAt.value = null+ minutes == 0 -> { sleepTrackId = currentTrackId; _sleepEndsAt.value = -1L }+ else -> {+ _sleepEndsAt.value = SystemClock.elapsedRealtime() + minutes * 60_000L+ main.postDelayed(sleepRunnable, minutes * 60_000L)+ }+ }+ }++ private fun checkEndOfTrackTimer(newTrackId: String) {+ val t = sleepTrackId ?: return+ if (newTrackId.isNotBlank() && newTrackId != t) {+ sleepTrackId = null+ _sleepEndsAt.value = null+ pauseSilently()+ }+ }++ // ── Queue (the API pushes every change, nothing to poll) ──+ fun watchQueue(on: Boolean) {}+ fun requestQueue() {}++ private fun apiItem(item: QueueItem): app.myspoti.api.NowPlaying? =+ apiQueue?.let { q -> (q.queued + q.nextUp).firstOrNull { it.uri == item.uri && (item.uid.isBlank() || it.uid == item.uid) } }++ /** "Play next": first in the queue, right after the current track. */+ fun playNext(trackId: String) {+ if (trackId.isBlank()) return+ Haptics.confirm()+ command { api.player.playNext(listOf(SPOTIFY_TRACK_PREFIX + trackId)) }+ }++ fun addToQueue(trackId: String) {+ if (trackId.isBlank()) return+ Haptics.confirm()+ command { api.player.addToQueue(listOf(SPOTIFY_TRACK_PREFIX + trackId)) }+ }++ fun skipTo(item: QueueItem) {+ val id = trackIdOf(item.uri)+ if (id.isNotBlank()) markPending(id)+ boundState?.updateSongState(item.song.coverUri, item.song.title, item.song.singer, true, item.song.id, 0, item.song.album)+ durationMs = item.song.durationMs.toLong()+ pushNotification(item.song, false)+ val target = apiItem(item) ?: return+ command { api.player.skipTo(target) }+ }++ /** "Clear queue": drops the tracks the user queued (not the context's next ones). */+ fun clearQueue() {+ _queue.value = _queue.value.copy(queued = emptyList())+ command { api.player.clearQueue() }+ }++ /** Move [item] just before / after [target] (same section of the queue). */+ fun reorder(item: QueueItem, target: QueueItem, after: Boolean) {+ val a = apiItem(item) ?: return+ val b = apiItem(target) ?: return+ command { api.player.moveInQueue(a, b, after) }+ }++ /** Move a "next up" track into the queue, right after the current one. */+ fun moveToQueueFront(item: QueueItem) {+ val a = apiItem(item) ?: return+ command {+ api.player.addToQueue(listOf(a.uri))+ api.player.removeFromQueue(listOf(a))+ }+ }++ fun removeFromQueue(item: QueueItem) {+ _queue.value = _queue.value.let { q -> q.copy(queued = q.queued - item, nextUp = q.nextUp - item) }+ val a = apiItem(item) ?: return+ command { api.player.removeFromQueue(listOf(a)) }+ }++ fun isPlaying(): Boolean = if (LocalPlayer.active.value) LocalPlayer.isPlaying() else playing+ fun getDuration(): Long = if (LocalPlayer.active.value) LocalPlayer.duration() else durationMs++ fun getCurrentPosition(): Long {+ if (LocalPlayer.active.value) return LocalPlayer.position()+ val base = positionMs+ if (!playing || isBuffering) return base+ val now = base + (SystemClock.elapsedRealtime() - positionAt)+ return if (durationMs > 0) now.coerceAtMost(durationMs) else now+ }++ /** A local file starts: Spotify pauses (wherever it plays). */+ fun pauseEngineForLocal() {+ if (playing) command { api.player.pause() }+ playing = false+ }++ /** The local player's track / state, shown like any other (player, mini player, notification). */+ fun onLocalState(t: com.music.spotui.data.local.LocalTrack, isPlaying: Boolean, pos: Long, dur: Long) {+ main.post {+ currentTrackId = ""+ playing = isPlaying; positionMs = pos; positionAt = SystemClock.elapsedRealtime(); durationMs = dur+ bufferingState.value = false+ val uri = "local:${t.id}"+ if (_nowPlaying.value.uri != uri) _nowPlaying.value = NowPlaying(uri = uri, contextName = LocalPlayer.contextName)+ val song = SongsModel(id = ("local:" + t.id).hashCode() and 0x7fffffff, title = t.title, album = t.album,+ singer = t.artist, coverUri = t.artUri.toString(), url = "local:${t.uri}", durationMs = dur.toInt())+ boundState?.let { st ->+ st.likeState.value = false+ st.updateSongState(song.coverUri, song.title, song.singer, isPlaying, song.id, 0, song.album)+ }+ pushNotification(song, false)+ val source = if (t.uri.scheme == "file") com.music.spotui.data.local.ListenHistory.Source.DOWNLOAD+ else com.music.spotui.data.local.ListenHistory.Source.LOCAL+ trackListen(uri, song, source, isPlaying)+ }+ }++ fun isCrossfadeActive(): Boolean = false+ fun release() {}++ // ── Play-key helpers (url = "spotify:track:<id>|<search text>") ──++ private val featSearchPattern = Regex("""\s*[\(\[]\s*(feat|ft)\..*?[\)\]]""", RegexOption.IGNORE_CASE)++ fun buildSpotifyPlayQuery(spotifyTrackId: String, title: String, artist: String): String {+ val searchText = listOf(title.replace(featSearchPattern, "").trim(), artist)+ .filter { it.isNotBlank() }+ .joinToString(" ")+ return if (spotifyTrackId.isBlank()) searchText else "$SPOTIFY_TRACK_PREFIX$spotifyTrackId|$searchText"+ }++ private fun spotifyTrackIdForPlayback(song: String): String? =+ if (song.startsWith(SPOTIFY_TRACK_PREFIX)) {+ song.removePrefix(SPOTIFY_TRACK_PREFIX).substringBefore('|').takeIf { it.isNotBlank() }+ } else {+ null+ }++ // Media cache for the looping Canvas video on the now-playing screen.+ @Volatile private var mediaCache: androidx.media3.datasource.cache.SimpleCache? = null++ @androidx.annotation.OptIn(androidx.media3.common.util.UnstableApi::class)+ internal fun mediaCache(context: Context): androidx.media3.datasource.cache.SimpleCache =+ mediaCache ?: synchronized(this) {+ mediaCache ?: androidx.media3.datasource.cache.SimpleCache(+ java.io.File(context.cacheDir, "media"),+ androidx.media3.datasource.cache.LeastRecentlyUsedCacheEvictor(64L * 1024 * 1024),+ androidx.media3.database.StandaloneDatabaseProvider(context),+ ).also { mediaCache = it }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/AboutSheet.kt b/base/app/src/main/java/com/music/spotui/ui/components/AboutSheet.ktnew file mode 100644index 00000000..00d20525--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/AboutSheet.kt@@ -0,0 +1,87 @@+package com.music.spotui.ui.components++import android.content.Context+import android.content.Intent+import android.net.Uri+import androidx.compose.foundation.Image+import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.navigationBarsPadding+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.rememberScrollState+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.foundation.verticalScroll+import androidx.compose.material3.ExperimentalMaterial3Api+import androidx.compose.material3.ModalBottomSheet+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.res.stringResource+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import app.myspoti.engine.BuildConfig+import app.myspoti.engine.R+import com.music.spotui.data.api.SupportReminder+import com.music.spotui.ui.theme.AppAccent++const val DISCORD_URL = "https://discord.gg/jXKnGVFnGS"+private val repo get() = BuildConfig.UPDATE_REPO.ifBlank { "kota-zo/myspoti" }++private fun openUrl(context: Context, url: String) {+ runCatching {+ context.startActivity(Intent(Intent.ACTION_VIEW, Uri.parse(url)).addFlags(Intent.FLAG_ACTIVITY_NEW_TASK))+ }+}++/** About: the version, the Discord community, the source code and Ko-fi. */+@OptIn(ExperimentalMaterial3Api::class)+@Composable+fun AboutSheet(onDismiss: () -> Unit) {+ val context = LocalContext.current+ ModalBottomSheet(onDismissRequest = onDismiss, containerColor = Color(0xFF282828)) {+ Column(Modifier.navigationBarsPadding().verticalScroll(rememberScrollState()).padding(bottom = 20.dp)) {+ Row(verticalAlignment = Alignment.CenterVertically, modifier = Modifier.padding(horizontal = 20.dp)) {+ Image(+ painterResource(R.drawable.ic_launcher_foreground), contentDescription = null,+ modifier = Modifier.size(56.dp).clip(RoundedCornerShape(14.dp)).background(Color(0xFF121212)),+ )+ Column(Modifier.padding(start = 14.dp)) {+ Text("Myspoti", color = Color.White, fontSize = 20.sp, fontWeight = FontWeight.Bold)+ Text("${stringResource(R.string.settings_item_version_title)} ${BuildConfig.VERSION_NAME}",+ color = Color(0xFFB3B3B3), fontSize = 13.sp)+ }+ }+ Text(stringResource(R.string.about_free), color = Color(0xFFB3B3B3), fontSize = 13.sp,+ modifier = Modifier.padding(start = 20.dp, end = 20.dp, top = 12.dp, bottom = 8.dp))+ AboutRow(stringResource(R.string.about_discord), stringResource(R.string.about_discord_detail)) { openUrl(context, DISCORD_URL) }+ AboutRow(stringResource(R.string.about_github), stringResource(R.string.about_github_detail)) { openUrl(context, "https://github.com/$repo") }+ Text(stringResource(R.string.support_body), color = Color(0xFFB3B3B3), fontSize = 13.sp,+ modifier = Modifier.padding(start = 20.dp, end = 20.dp, top = 14.dp, bottom = 12.dp))+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.padding(horizontal = 20.dp).fillMaxWidth().height(48.dp).clip(RoundedCornerShape(50))+ .background(AppAccent).pressable(0.96f) { SupportReminder.open(context) },+ ) { Text(stringResource(R.string.support_action), color = Color.Black, fontSize = 16.sp, fontWeight = FontWeight.Bold) }+ }+ }+}++@Composable+private fun AboutRow(title: String, detail: String, onClick: () -> Unit) {+ Column(Modifier.fillMaxWidth().clickable(onClick = onClick).padding(horizontal = 20.dp, vertical = 10.dp)) {+ Text(title, color = Color.White, fontSize = 16.sp)+ Text(detail, color = Color(0xFFB3B3B3), fontSize = 12.sp)+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/AppComponents.kt b/base/app/src/main/java/com/music/spotui/ui/components/AppComponents.ktnew file mode 100644index 00000000..21d52d50--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/AppComponents.kt@@ -0,0 +1,322 @@+package com.music.spotui.ui.components++import androidx.compose.ui.res.stringResource++import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.basicMarquee+import androidx.compose.material.icons.automirrored.filled.VolumeUp+import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.layout.widthIn+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.filled.CheckCircle+import androidx.compose.material3.ExperimentalMaterial3Api+import androidx.compose.material3.Icon+import androidx.compose.material3.Slider+import androidx.compose.material3.SliderColors+import androidx.compose.material3.SliderDefaults+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableFloatStateOf+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.draw.clipToBounds+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.toArgb+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.unit.Dp+import androidx.compose.ui.unit.DpSize+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.lifecycle.viewmodel.compose.viewModel+import androidx.navigation.NavHostController+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.bumptech.glide.integration.compose.placeholder+import app.myspoti.engine.R+import com.music.spotui.data.preferences.addLikedSongId+import com.music.spotui.data.preferences.isSongLiked+import com.music.spotui.data.preferences.removeLikedSongId+import com.music.spotui.di.Palette+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.navigation.Routes+import com.music.spotui.ui.theme.AppBackground+import com.music.spotui.ui.theme.GridBackground+import com.music.spotui.ui.viewmodel.PlayerViewModel+import kotlinx.coroutines.delay++/**+ * Loading placeholder, as in the official app: static grey shapes of the page to+ * come, no spinner. Shown only if loading lasts (cached pages appear without it),+ * and never animated (no frames spent while waiting).+ */+@Composable+fun Loader(kind: SkeletonKind = SkeletonKind.List) {+ var visible by remember { mutableStateOf(false) }+ LaunchedEffect(Unit) { delay(200); visible = true }+ Column(+ Modifier+ .fillMaxSize()+ .background(Color(AppBackground.toArgb()))+ .padding(horizontal = 16.dp, vertical = 12.dp),+ ) {+ if (!visible) return@Column+ val tile = Color(0xFF242424)+ val line = Color(0xFF2A2A2A)+ when (kind) {+ SkeletonKind.Home -> {+ repeat(4) {+ Row(Modifier.fillMaxWidth().padding(bottom = 8.dp), horizontalArrangement = Arrangement.spacedBy(8.dp)) {+ repeat(2) { Box(Modifier.weight(1f).height(56.dp).clip(RoundedCornerShape(4.dp)).background(tile)) }+ }+ }+ repeat(2) {+ Box(Modifier.padding(top = 24.dp, bottom = 12.dp).width(180.dp).height(18.dp).clip(RoundedCornerShape(4.dp)).background(line))+ Row(horizontalArrangement = Arrangement.spacedBy(12.dp)) {+ repeat(3) { Box(Modifier.size(140.dp).clip(RoundedCornerShape(4.dp)).background(tile)) }+ }+ }+ }+ SkeletonKind.Header -> {+ Box(Modifier.align(Alignment.CenterHorizontally).padding(top = 24.dp, bottom = 20.dp).size(220.dp).clip(RoundedCornerShape(4.dp)).background(tile))+ Box(Modifier.width(200.dp).height(22.dp).clip(RoundedCornerShape(4.dp)).background(line))+ Box(Modifier.padding(top = 10.dp, bottom = 20.dp).width(120.dp).height(14.dp).clip(RoundedCornerShape(4.dp)).background(line))+ SkeletonRows(tile, line, 6)+ }+ SkeletonKind.List -> SkeletonRows(tile, line, 9)+ }+ }+}++enum class SkeletonKind { List, Home, Header }++@Composable+private fun SkeletonRows(tile: Color, line: Color, count: Int) {+ repeat(count) {+ Row(Modifier.padding(vertical = 8.dp), verticalAlignment = Alignment.CenterVertically) {+ Box(Modifier.size(48.dp).clip(RoundedCornerShape(4.dp)).background(tile))+ Column(Modifier.padding(start = 12.dp)) {+ Box(Modifier.width(170.dp).height(14.dp).clip(RoundedCornerShape(4.dp)).background(line))+ Box(Modifier.padding(top = 8.dp).width(110.dp).height(12.dp).clip(RoundedCornerShape(4.dp)).background(line))+ }+ }+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun MiniPlayer(navController: NavHostController) {+ val vm : PlayerViewModel = viewModel()+ val songTitle = vm.currentSongTitle.value+ val songSinger = vm.currentSongSinger.value+ val songCoverUri = vm.currentSongCoverUri.value+ val songPlayingState = vm.currentSongPlayingState.value+ val songId = vm.currentSongId.value+ val liked = vm.likeState.value+ val np by SongPlayer.nowPlaying+ val context = LocalContext.current++ // Card tint from the cover — extracted once per cover, not on every recomposition.+ var tint by remember { mutableStateOf(Palette.cachedFirst(songCoverUri) ?: Color(0xFF2A2A2A)) }+ LaunchedEffect(songCoverUri) {+ if (songCoverUri.isNotBlank()) {+ Palette().extractFirstColorFromImageUrl(context, songCoverUri) { tint = it }+ // Warm the full player's background colour: it opens already tinted.+ Palette().extractSecondColorFromCoverUrl(context, songCoverUri) { }+ }+ }++ // The thin bar moves ~2 px/s: 4 ticks a second look identical to 20.+ val frame = rememberFrameClock(songPlayingState, fps = 4)++ var showDevices by remember { mutableStateOf(false) }+ if (showDevices) DevicesSheet { showDevices = false }++ // Swipe the track info left/right to change track: [previous, current, next].+ val pager = androidx.compose.foundation.pager.rememberPagerState(initialPage = 1, pageCount = { 3 })+ LaunchedEffect(songId) { if (pager.currentPage != 1) pager.scrollToPage(1) }+ LaunchedEffect(pager) {+ androidx.compose.runtime.snapshotFlow { pager.settledPage }.collect { page ->+ when (page) {+ 2 -> SongPlayer.swipeNext()+ 0 -> SongPlayer.previous()+ }+ }+ }++ Column(+ modifier = Modifier.pressable(0.96f) { com.music.spotui.ui.navigation.PlayerSheet.show() }+ .padding(horizontal = 8.dp)+ .clip(RoundedCornerShape(8.dp))+ .background(tint)++ ) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .height(54.dp)+ .padding(start = 8.dp, end = 12.dp)+ ) {+ androidx.compose.foundation.pager.HorizontalPager(+ state = pager,+ modifier = Modifier.weight(1f),+ ) { page ->+ val s = when (page) { 0 -> np.prev; 2 -> np.next; else -> null }+ Row(verticalAlignment = Alignment.CenterVertically, modifier = Modifier.fillMaxWidth()) {+ GlideImage(+ modifier = Modifier+ .size(40.dp)+ .clip(RoundedCornerShape(4.dp)),+ model = s?.coverUri ?: songCoverUri,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = ""+ )+ val remote = SongPlayer.activeDevice.value+ Column(modifier = Modifier.padding(start = 12.dp, end = 8.dp)) {+ if (remote == null) {+ Text(text = s?.title ?: songTitle, color = Color.White, fontSize = 13.sp, fontWeight = FontWeight.Bold, maxLines = 1, overflow = androidx.compose.ui.text.style.TextOverflow.Ellipsis)+ Text(text = s?.singer ?: songSinger, color = Color.White.copy(alpha = 0.7f), fontSize = 13.sp, maxLines = 1, overflow = androidx.compose.ui.text.style.TextOverflow.Ellipsis)+ } else {+ // Playing on another device: "Title • Artist", then the device in green.+ Text(+ text = androidx.compose.ui.text.buildAnnotatedString {+ pushStyle(androidx.compose.ui.text.SpanStyle(fontWeight = FontWeight.Bold, color = Color.White))+ append(s?.title ?: songTitle)+ pop()+ pushStyle(androidx.compose.ui.text.SpanStyle(color = Color.White.copy(alpha = 0.7f)))+ append(" • " + (s?.singer ?: songSinger))+ pop()+ },+ fontSize = 13.sp, maxLines = 1, softWrap = false,+ // Scrolls once per track then rests: an endless marquee in the always-visible+ // mini player made the whole app redraw at 120 Hz without pause.+ modifier = Modifier.basicMarquee(iterations = 1, initialDelayMillis = 2_000),+ )+ Row(verticalAlignment = Alignment.CenterVertically) {+ Icon(Icons.AutoMirrored.Filled.VolumeUp, contentDescription = null, tint = com.music.spotui.ui.theme.AppAccent, modifier = Modifier.size(14.dp))+ Text(remote.name, color = com.music.spotui.ui.theme.AppAccent, fontSize = 12.sp, maxLines = 1, modifier = Modifier.padding(start = 4.dp))+ }+ }+ }+ }+ }+ Icon(+ painter = painterResource(id = if (SongPlayer.activeDevice.value != null) R.drawable.ic_devices else R.drawable.ic_devices),+ tint = if (SongPlayer.activeDevice.value != null) com.music.spotui.ui.theme.AppAccent else Color.White.copy(alpha = 0.8f),+ modifier = Modifier.pressable(0.96f) { showDevices = true }+ .size(22.dp)+ ,+ contentDescription = stringResource(R.string.mr_user_route_category_name),+ )+ Spacer(modifier = Modifier.width(20.dp))+ if (!com.music.spotui.di.LocalPlayer.active.value) com.music.spotui.ui.screens.AddButton(song = { com.music.spotui.ui.screens.nowPlayingSong(vm) }, liked = liked, size = 24.dp) { vm.updateLikeState(true) }+ Spacer(modifier = Modifier.width(20.dp))+ Icon(+ painter = if (songPlayingState) painterResource(id = R.drawable.ic_playing)+ else painterResource(id = R.drawable.play_svgrepo_com),+ contentDescription = if (songPlayingState) stringResource(R.string.content_description_pause_button) else stringResource(R.string.content_description_play_button),+ tint = Color.White,+ modifier = Modifier.pressable(0.96f) {+ if (songPlayingState) {+ SongPlayer.pause()+ vm.updateSongState(songCoverUri, songTitle, songSinger, false, songId, vm.currentSongIndex.value, vm.currentSongAlbum.value)+ } else {+ SongPlayer.play()+ vm.updateSongState(songCoverUri, songTitle, songSinger, true, songId, vm.currentSongIndex.value, vm.currentSongAlbum.value)+ }+ }+ .size(26.dp)++ )+ }+ // Thin progress line at the bottom of the card.+ // Drawn every frame from the engine clock: smooth at the display refresh rate.+ androidx.compose.foundation.Canvas(+ modifier = Modifier+ .fillMaxWidth()+ .padding(horizontal = 8.dp)+ .height(2.dp)+ .clip(RoundedCornerShape(1.dp))+ ) {+ frame.value+ val dur = SongPlayer.getDuration().toFloat()+ val p = if (dur > 0f) (SongPlayer.getCurrentPosition() / dur).coerceIn(0f, 1f) else 0f+ drawRect(Color.White.copy(alpha = 0.25f))+ drawRect(Color.White, size = size.copy(width = size.width * p))+ }+ }+}+++@OptIn(ExperimentalMaterial3Api::class)+@Composable+fun CustomSlider(+ modifier: Modifier = Modifier,+ value: Float,+ onValueChange: (Float) -> Unit,+ valueRange: ClosedFloatingPointRange<Float> = 0f..1f,+ steps: Int = 0,+ colors: SliderColors = SliderDefaults.colors(),+) {+ Box(+ //contentAlignment = Alignment.BottomEnd,+ modifier = Modifier+ .fillMaxWidth()+ .height(0.dp)++ ) {++ Slider(+ value = value,+ onValueChange = onValueChange,+ valueRange = valueRange,+ steps = steps,+ colors = colors,+ )+ }+}+++@Composable+fun Snackbar(showMessage : String) {+ Box(+ modifier = Modifier+ .fillMaxWidth()+ .height(48.dp)+ .clip(RoundedCornerShape(4.dp))+ .background(Color.White),+ contentAlignment = Alignment.Center+ ){+ Text(+ fontWeight = FontWeight.W500,+ fontSize = 14.sp,+ color = Color.Black,+ text = showMessage+ )+ }+}+diff --git a/base/app/src/main/java/com/music/spotui/ui/components/BetaLogButton.kt b/base/app/src/main/java/com/music/spotui/ui/components/BetaLogButton.ktnew file mode 100644index 00000000..f1427423--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/BetaLogButton.kt@@ -0,0 +1,141 @@+package com.music.spotui.ui.components++import android.content.ClipData+import android.content.ClipboardManager+import android.content.Context+import android.content.Intent+import android.widget.Toast+import androidx.compose.foundation.background+import androidx.compose.foundation.border+import androidx.compose.foundation.gestures.detectTapGestures+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.ui.input.pointer.pointerInput+import com.music.spotui.di.Haptics+import kotlinx.coroutines.launch+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.navigationBarsPadding+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.rememberScrollState+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.foundation.text.selection.SelectionContainer+import androidx.compose.foundation.verticalScroll+import androidx.compose.material3.CircularProgressIndicator+import androidx.compose.material3.Text+import androidx.compose.material3.TextButton+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.res.stringResource+import androidx.compose.ui.text.font.FontFamily+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.compose.ui.window.Dialog+import androidx.compose.ui.window.DialogProperties+import app.myspoti.engine.R+import com.music.spotui.data.BetaLogs++/**+ * Beta builds: a tiny, faint dot in the bottom-right corner. Holding it makes it grow; held+ * until full size, it opens the app's logs of the last [BetaLogs.MINUTES] minutes, ready to copy+ * into a bug report. A short touch does nothing, so it never gets in the way.+ */+@Composable+fun BetaLogButton(modifier: Modifier = Modifier) {+ var open by remember { mutableStateOf(false) }+ val grow = remember { androidx.compose.animation.core.Animatable(0f) }+ val scope = androidx.compose.runtime.rememberCoroutineScope()+ Box(+ modifier+ .navigationBarsPadding()+ .padding(end = 2.dp, bottom = 132.dp)+ .size(28.dp)+ .pointerInput(Unit) {+ detectTapGestures(onPress = {+ val job = scope.launch {+ grow.animateTo(1f, androidx.compose.animation.core.tween(HOLD_MS, easing = androidx.compose.animation.core.LinearEasing))+ Haptics.click()+ open = true+ }+ tryAwaitRelease()+ job.cancel()+ scope.launch { grow.animateTo(0f, androidx.compose.animation.core.tween(150)) }+ })+ },+ contentAlignment = Alignment.Center,+ ) {+ val g = grow.value+ Box(+ Modifier+ .size((10 + 18 * g).dp)+ .background(Color(0xFF1DB954).copy(alpha = 0.45f + 0.5f * g), CircleShape)+ .border(1.dp, Color.White.copy(alpha = 0.5f), CircleShape),+ contentAlignment = Alignment.Center,+ ) {+ if (g > 0.6f) Text("log", color = Color.Black.copy(alpha = (g - 0.6f) * 2.5f), fontSize = 8.sp, fontFamily = FontFamily.Monospace)+ }+ }+ if (open) LogsDialog(onDismiss = { open = false })+}++private const val HOLD_MS = 900++@Composable+private fun LogsDialog(onDismiss: () -> Unit) {+ val context = LocalContext.current+ var text by remember { mutableStateOf<String?>(null) }+ LaunchedEffect(Unit) { text = BetaLogs.recent() }+ Dialog(onDismissRequest = onDismiss, properties = DialogProperties(usePlatformDefaultWidth = false)) {+ Column(Modifier.fillMaxSize().background(Color(0xFF121212)).statusBarsPadding().navigationBarsPadding()) {+ Row(Modifier.fillMaxWidth().padding(horizontal = 8.dp), verticalAlignment = Alignment.CenterVertically) {+ Text(stringResource(R.string.beta_logs_title, BetaLogs.MINUTES), color = Color.White, fontSize = 17.sp,+ modifier = Modifier.weight(1f).padding(start = 8.dp))+ TextButton(onClick = onDismiss) { Text(stringResource(R.string.beta_logs_close), color = Color(0xFFB3B3B3)) }+ }+ Box(Modifier.weight(1f).fillMaxWidth().padding(horizontal = 8.dp)) {+ val logs = text+ if (logs == null) CircularProgressIndicator(Modifier.align(Alignment.Center), color = Color(0xFF1DB954))+ else SelectionContainer {+ // The newest lines matter most: the view opens scrolled to the end.+ val scroll = rememberScrollState()+ LaunchedEffect(logs) { scroll.scrollTo(scroll.maxValue) }+ Text(logs, color = Color(0xFFDDDDDD), fontSize = 10.sp, fontFamily = FontFamily.Monospace, lineHeight = 13.sp,+ modifier = Modifier.fillMaxSize().verticalScroll(scroll))+ }+ }+ Row(Modifier.fillMaxWidth().padding(8.dp), horizontalArrangement = Arrangement.spacedBy(8.dp, Alignment.End)) {+ TextButton(onClick = { text?.let { share(context, it) } }, enabled = text != null) {+ Text(stringResource(R.string.beta_logs_share), color = Color.White)+ }+ TextButton(onClick = { text?.let { copy(context, it) } }, enabled = text != null,+ modifier = Modifier.background(Color(0xFF1DB954), RoundedCornerShape(20.dp))) {+ Text(stringResource(R.string.beta_logs_copy), color = Color.Black)+ }+ }+ }+ }+}++private fun copy(context: Context, text: String) {+ val clipboard = context.getSystemService(Context.CLIPBOARD_SERVICE) as ClipboardManager+ clipboard.setPrimaryClip(ClipData.newPlainText("Myspoti logs", text))+ Toast.makeText(context, R.string.beta_logs_copied, Toast.LENGTH_SHORT).show()+}++private fun share(context: Context, text: String) {+ val send = Intent(Intent.ACTION_SEND).setType("text/plain").putExtra(Intent.EXTRA_TEXT, text)+ context.startActivity(Intent.createChooser(send, null).addFlags(Intent.FLAG_ACTIVITY_NEW_TASK))+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/DownloadBadge.kt b/base/app/src/main/java/com/music/spotui/ui/components/DownloadBadge.ktnew file mode 100644index 00000000..f802a246--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/DownloadBadge.kt@@ -0,0 +1,70 @@+package com.music.spotui.ui.components++import androidx.compose.foundation.background+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.filled.ArrowDownward+import androidx.compose.material.icons.outlined.ArrowCircleDown+import androidx.compose.material.icons.outlined.DeleteOutline+import androidx.compose.material.icons.outlined.ErrorOutline+import androidx.compose.material3.CircularProgressIndicator+import androidx.compose.material3.Icon+import androidx.compose.runtime.Composable+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.res.stringResource+import androidx.compose.ui.unit.Dp+import androidx.compose.ui.unit.dp+import app.myspoti.engine.R+import com.music.spotui.data.offline.OfflineStatus++private val Green: Color get() = com.music.spotui.ui.theme.AppAccent++/** A track's download state, as the official app draws it next to the title. Nothing when not downloaded. */+@Composable+fun DownloadBadge(status: OfflineStatus?, size: Dp = 16.dp, modifier: Modifier = Modifier) {+ when (status) {+ null -> Unit+ OfflineStatus.Done -> Box(+ contentAlignment = Alignment.Center,+ modifier = modifier.size(size).clip(CircleShape).background(Green),+ ) {+ Icon(Icons.Default.ArrowDownward, stringResource(R.string.download_badge_downloaded_content_description),+ tint = Color.Black, modifier = Modifier.size(size * 0.7f))+ }+ OfflineStatus.Queued -> Icon(Icons.Outlined.ArrowCircleDown,+ stringResource(R.string.download_badge_downloading_content_description),+ tint = Color.White.copy(alpha = 0.5f), modifier = modifier.size(size))+ is OfflineStatus.Downloading -> Box(contentAlignment = Alignment.Center, modifier = modifier.size(size)) {+ if (status.progress < 0f) CircularProgressIndicator(color = Green, strokeWidth = 2.dp, modifier = Modifier.size(size))+ else CircularProgressIndicator(progress = { status.progress }, color = Green, trackColor = Color.White.copy(alpha = 0.2f),+ strokeWidth = 2.dp, modifier = Modifier.size(size))+ }+ OfflineStatus.Failed, OfflineStatus.Unavailable -> Icon(Icons.Outlined.ErrorOutline,+ stringResource(R.string.download_badge_error_content_description),+ tint = Color(0xFFE22134), modifier = modifier.size(size))+ }+}++/**+ * The download button of an album / playlist: outlined arrow, progress ring while songs+ * download, then a bin once all of them are on the phone (tap = remove the downloads).+ */+@Composable+fun DownloadListButton(downloaded: Int, total: Int, busy: Boolean, kept: Boolean, modifier: Modifier = Modifier, onClick: () -> Unit) {+ // A downloaded list shows the bin (tap = stop keeping it); its progress while songs arrive.+ val all = kept && !busy+ Box(contentAlignment = Alignment.Center, modifier = modifier.size(28.dp).pressable(0.92f, onClick = onClick)) {+ when {+ all -> Icon(Icons.Outlined.DeleteOutline, stringResource(R.string.context_menu_undownload),+ tint = Color.White.copy(alpha = 0.8f), modifier = Modifier.size(28.dp))+ busy -> DownloadBadge(OfflineStatus.Downloading(if (total > 0) downloaded.toFloat() / total else -1f), size = 24.dp)+ else -> Icon(Icons.Outlined.ArrowCircleDown, stringResource(R.string.context_menu_download),+ tint = Color.White.copy(alpha = 0.8f), modifier = Modifier.size(28.dp))+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/FindInList.kt b/base/app/src/main/java/com/music/spotui/ui/components/FindInList.ktnew file mode 100644index 00000000..bc856262--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/FindInList.kt@@ -0,0 +1,78 @@+package com.music.spotui.ui.components++import androidx.compose.foundation.background+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.foundation.text.BasicTextField+import androidx.compose.foundation.text.KeyboardOptions+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.filled.Close+import androidx.compose.material.icons.filled.Search+import androidx.compose.material3.Icon+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.SolidColor+import androidx.compose.ui.text.TextStyle+import androidx.compose.ui.text.input.ImeAction+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import java.text.Normalizer+import java.util.Locale++private fun fold(s: String) = Normalizer.normalize(s, Normalizer.Form.NFD)+ .replace(Regex("""\p{M}+"""), "").lowercase(Locale.ROOT)++/**+ * "Find in…" match: every word of [query] appears in one of [fields], ignoring case and+ * accents ("beyonce hal" finds "Halo" by Beyoncé). A blank query matches everything.+ */+fun matchesFind(query: String, vararg fields: String): Boolean {+ val words = fold(query).split(Regex("""\s+""")).filter { it.isNotEmpty() }+ if (words.isEmpty()) return true+ val text = fields.joinToString(" ") { fold(it) }+ return words.all { it in text }+}++/** The "Find in…" field at the top of a list of songs. */+@Composable+fun FindInListField(query: String, onQuery: (String) -> Unit, hint: String, modifier: Modifier = Modifier) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = modifier.fillMaxWidth().clip(RoundedCornerShape(8.dp)).background(Color(0x33FFFFFF)).padding(horizontal = 12.dp),+ ) {+ Icon(Icons.Default.Search, contentDescription = null, tint = Color.White, modifier = Modifier.size(18.dp))+ BasicTextField(+ value = query,+ onValueChange = onQuery,+ singleLine = true,+ textStyle = TextStyle(color = Color.White, fontSize = 15.sp),+ cursorBrush = SolidColor(Color.White),+ keyboardOptions = KeyboardOptions(imeAction = ImeAction.Search),+ modifier = Modifier.weight(1f).padding(8.dp, 10.dp),+ decorationBox = { inner ->+ Box {+ if (query.isEmpty()) Text(hint, color = Color(0xFFB3B3B3), fontSize = 15.sp, maxLines = 1)+ inner()+ }+ },+ )+ if (query.isNotEmpty()) Icon(+ Icons.Default.Close, contentDescription = null, tint = Color(0xFFB3B3B3),+ modifier = Modifier.size(18.dp).pressable(0.92f) { onQuery("") },+ )+ }+}++/** "Couldn't find …" under a "Find in…" field with no match. */+@Composable+fun FindInListEmpty(text: String) {+ Text(text, color = Color(0xFFB3B3B3), fontSize = 14.sp, modifier = Modifier.fillMaxWidth().padding(16.dp, 24.dp))+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/FrameCadence.kt b/base/app/src/main/java/com/music/spotui/ui/components/FrameCadence.ktnew file mode 100644index 00000000..1278e106--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/FrameCadence.kt@@ -0,0 +1,22 @@+package com.music.spotui.ui.components++/** Admits regular display frames without accumulating work after a late frame. */+internal class FrameCadence(fps: Int) {+ private val periodNanos = 1_000_000_000L / fps.coerceIn(1, 120)+ // A nominal VSync period can be rounded or jitter by a fraction of a millisecond.+ // Avoid missing an entire display frame because of this small timestamp error.+ private val earlyToleranceNanos = minOf(500_000L, periodNanos / 16)+ private var hasTicked = false+ private var lastTickNanos = 0L++ fun shouldTick(frameTimeNanos: Long): Boolean {+ if (hasTicked && frameTimeNanos >= lastTickNanos &&+ frameTimeNanos - lastTickNanos < periodNanos - earlyToleranceNanos+ ) return false+ // First frame, clock restart, or a late frame: publish once and rebase.+ // A pause never earns extra ticks on the next adjacent display frames.+ hasTicked = true+ lastTickNanos = frameTimeNanos+ return true+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/FrameClock.kt b/base/app/src/main/java/com/music/spotui/ui/components/FrameClock.ktnew file mode 100644index 00000000..e037f691--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/FrameClock.kt@@ -0,0 +1,38 @@+package com.music.spotui.ui.components++import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.State+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableLongStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.withFrameNanos+import androidx.lifecycle.Lifecycle+import androidx.lifecycle.compose.LocalLifecycleOwner+import androidx.lifecycle.compose.collectAsStateWithLifecycle+import androidx.lifecycle.repeatOnLifecycle+import kotlinx.coroutines.delay+import kotlinx.coroutines.isActive++/** A draw invalidation clock; reads in draw lambdas avoid screen recomposition. */+@Composable+fun rememberFrameClock(running: Boolean, fps: Int = 60): State<Long> {+ val clock = remember { mutableLongStateOf(0L) }+ val energy by app.myspoti.power.EnergySettings.state.collectAsStateWithLifecycle()+ val requestedFps = fps.coerceIn(1, 120)+ val effectiveFps = minOf(requestedFps, energy.policy.progressFps.coerceIn(1, 120))+ val lifecycle = LocalLifecycleOwner.current.lifecycle+ LaunchedEffect(running, effectiveFps, lifecycle) {+ if (!running) return@LaunchedEffect+ lifecycle.repeatOnLifecycle(Lifecycle.State.STARTED) {+ // One frame per tick, then sleep: between ticks nothing asks for a frame, so+ // the LTPO screen can drop its refresh rate (a withFrameNanos loop kept it at max).+ val periodMs = 1000L / effectiveFps+ while (isActive) {+ clock.longValue = withFrameNanos { it }+ delay((periodMs - 4).coerceAtLeast(0))+ }+ }+ }+ return clock+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/Motion.kt b/base/app/src/main/java/com/music/spotui/ui/components/Motion.ktnew file mode 100644index 00000000..9250938f--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/Motion.kt@@ -0,0 +1,64 @@+package com.music.spotui.ui.components++import androidx.compose.animation.core.Spring+import androidx.compose.animation.core.animateFloatAsState+import androidx.compose.animation.core.spring+import androidx.compose.foundation.clickable+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.interaction.collectIsPressedAsState+import androidx.compose.runtime.getValue+import androidx.compose.runtime.remember+import androidx.compose.ui.Modifier+import androidx.compose.ui.composed+import androidx.compose.ui.graphics.graphicsLayer+import androidx.compose.foundation.gestures.awaitEachGesture+import androidx.compose.foundation.gestures.awaitFirstDown+import androidx.compose.ui.input.pointer.PointerEventPass+import androidx.compose.ui.input.pointer.pointerInput++/**+ * Official-app press feedback: the control shrinks a little under the finger and+ * springs back on release, no ripple. Animates only while pressed.+ */+fun Modifier.pressable(+ pressedScale: Float = 0.9f,+ enabled: Boolean = true,+ onPressHint: (() -> Unit)? = null,+ onClick: () -> Unit,+): Modifier = composed {+ val source = remember { MutableInteractionSource() }+ val hinted = if (onPressHint == null) Modifier else Modifier.pressHint(onPressHint)+ hinted.then(pressScale(source, pressedScale)).clickable(source, indication = null, enabled = enabled, onClick = onClick)+}++/**+ * Calls [onHint] when a finger rests on the element (80 ms without moving past the+ * touch slop) or taps it: the page behind it starts loading ~100 ms before the+ * click. A touch that turns into a scroll asks for nothing.+ */+fun Modifier.pressHint(onHint: () -> Unit): Modifier = pointerInput(onHint) {+ awaitEachGesture {+ val down = awaitFirstDown(requireUnconsumed = false, pass = PointerEventPass.Initial)+ val slop = viewConfiguration.touchSlop+ var moved = false+ withTimeoutOrNull(80) {+ while (true) {+ val change = awaitPointerEvent(PointerEventPass.Initial).changes.firstOrNull { it.id == down.id } ?: break+ if ((change.position - down.position).getDistance() > slop) { moved = true; break }+ if (!change.pressed) break+ }+ }+ if (!moved) onHint()+ }+}++/** The shrink of [pressable], for a control whose clickable sits further down the chain. */+fun Modifier.pressScale(source: MutableInteractionSource, pressedScale: Float = 0.9f): Modifier = composed {+ val pressed by source.collectIsPressedAsState()+ val scale by animateFloatAsState(+ if (pressed) pressedScale else 1f,+ spring(dampingRatio = Spring.DampingRatioMediumBouncy, stiffness = Spring.StiffnessMedium),+ label = "press",+ )+ graphicsLayer { scaleX = scale; scaleY = scale }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/MusicVideo.kt b/base/app/src/main/java/com/music/spotui/ui/components/MusicVideo.ktnew file mode 100644index 00000000..814f88d5--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/MusicVideo.kt@@ -0,0 +1,265 @@+package com.music.spotui.ui.components++import androidx.compose.ui.res.stringResource++import androidx.activity.compose.BackHandler+import androidx.compose.animation.AnimatedVisibility+import androidx.compose.animation.fadeIn+import androidx.compose.animation.fadeOut+import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.gestures.detectTapGestures+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.aspectRatio+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.filled.Fullscreen+import androidx.compose.material.icons.filled.FullscreenExit+import androidx.compose.material.icons.filled.MusicNote+import androidx.compose.material.icons.filled.OndemandVideo+import androidx.compose.material3.Icon+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.runtime.DisposableEffect+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableFloatStateOf+import androidx.compose.runtime.mutableIntStateOf+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Brush+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.graphicsLayer+import androidx.compose.ui.input.pointer.pointerInput+import androidx.compose.ui.layout.boundsInRoot+import androidx.compose.ui.layout.onGloballyPositioned+import androidx.compose.ui.layout.positionInRoot+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import com.music.spotui.di.Graph+import com.music.spotui.di.SongPlayer+import com.music.spotui.video.MusicVideoController+import com.music.spotui.ui.screens.SpotifySeekBar+import app.myspoti.engine.R+import kotlinx.coroutines.delay++/**+ * Spotify music videos. The clip is the Web Player's own (`Switch to video`), played+ * by the engine WebView; the native UI only reserves where it appears ([VideoSlot])+ * and MainActivity shows that part of the WebView there (see EngineFrame).+ */++/**+ * The music video (YouTube, synced to Spotify by [MusicVideoController]) rendered by+ * ExoPlayer into a TextureView: a normal view, so it scrolls, clips and animates with+ * the rest of the UI. Only the [active] surface receives the frames.+ */+@Composable+fun VideoSurface(modifier: Modifier = Modifier, active: Boolean = true, fitHeight: Boolean = false, onTap: (() -> Unit)? = null) {+ val ratio = MusicVideoController.aspect.floatValue.coerceIn(0.4f, 3f)+ var view by remember { mutableStateOf<android.view.TextureView?>(null) }+ val player = MusicVideoController.player+ DisposableEffect(player, view, active) {+ val v = view+ val attached = player != null && v != null && active+ if (attached) { player!!.setVideoTextureView(v); MusicVideoController.surfaces++ }+ onDispose {+ if (attached) MusicVideoController.surfaces--+ if (player != null && v != null) player.clearVideoTextureView(v)+ }+ }+ androidx.compose.ui.viewinterop.AndroidView(+ factory = { ctx -> android.view.TextureView(ctx).also { view = it } },+ modifier = modifier+ .then(if (fitHeight) Modifier.aspectRatio(ratio, matchHeightConstraintsFirst = true) else Modifier.fillMaxWidth().aspectRatio(ratio))+ .background(Color.Black)+ .then(+ if (onTap != null) Modifier.clickable(+ interactionSource = remember { MutableInteractionSource() }, indication = null, onClick = onTap,+ ) else Modifier+ ),+ )+}++// The official AV button (layout animated_av_button): a black pill drawn over the+// media (overMediaBackgroundBase), 16 dp video icon, BodySmallBold white label.+private val OverMedia = Color.Black.copy(alpha = 0.6f)++/** Spotify's "Passer à la vidéo" / "Passer à l'audio" pill. */+@Composable+fun VideoSwitchPill(on: Boolean, modifier: Modifier = Modifier) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = modifier+ .height(32.dp)+ .clip(RoundedCornerShape(50))+ .background(OverMedia)+ .clickable { MusicVideoController.setOn(!on) }+ .padding(start = 10.dp, end = 12.dp),+ ) {+ Icon(+ if (on) Icons.Default.MusicNote else Icons.Default.OndemandVideo,+ contentDescription = stringResource(R.string.av_content_desc),+ tint = Color.White,+ modifier = Modifier.size(16.dp),+ )+ Spacer(Modifier.width(8.dp))+ Text(+ stringResource(if (on) R.string.av_switch_to_audio else R.string.av_switch_to_video),+ color = Color.White,+ fontSize = 13.sp,+ fontWeight = FontWeight.Bold,+ maxLines = 1,+ )+ }+}++/** Full-screen button shown under the video. */+@Composable+fun VideoFullscreenButton(modifier: Modifier = Modifier) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = modifier+ .size(48.dp)+ .clickable { MusicVideoController.fullscreen.value = true },+ ) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.size(32.dp).clip(CircleShape).background(OverMedia),+ ) {+ Icon(+ Icons.Default.Fullscreen,+ contentDescription = stringResource(R.string.video_fullscreen_enter),+ tint = Color.White,+ modifier = Modifier.size(20.dp),+ )+ }+ }+}++/** Controls over the full-screen video; a tap shows / hides them. */+@Composable+fun VideoFullscreenOverlay() {+ BackHandler { MusicVideoController.fullscreen.value = false }+ var controls by remember { mutableStateOf(true) }+ var touch by remember { mutableIntStateOf(0) }+ LaunchedEffect(controls, touch) {+ if (controls) { delay(3500); controls = false }+ }+ val state = Graph.currentSongState+ val playing = state.playingState.value+ val frame = rememberFrameClock(playing && controls, fps = 30)+ var dragging by remember { mutableStateOf(false) }+ var dragValue by remember { mutableFloatStateOf(0f) }+ Box(+ Modifier+ .fillMaxSize()+ .pointerInput(Unit) { detectTapGestures { controls = !controls } },+ ) {+ AnimatedVisibility(visible = controls, enter = fadeIn(), exit = fadeOut()) {+ Box(+ Modifier+ .fillMaxSize()+ .background(Brush.verticalGradient(listOf(Color.Black.copy(alpha = 0.6f), Color.Transparent, Color.Black.copy(alpha = 0.7f)))),+ ) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().padding(horizontal = 24.dp, vertical = 16.dp),+ ) {+ Column(Modifier.weight(1f)) {+ Text(state.title.value, color = Color.White, fontSize = 16.sp, fontWeight = FontWeight.Bold, maxLines = 1, overflow = TextOverflow.Ellipsis)+ Text(state.singer.value, color = Color.White.copy(alpha = 0.7f), fontSize = 13.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ VideoSwitchPill(on = true)+ }+ Row(+ verticalAlignment = Alignment.CenterVertically,+ horizontalArrangement = Arrangement.spacedBy(40.dp),+ modifier = Modifier.align(Alignment.Center),+ ) {+ RoundIcon(R.drawable.ic_player_skip, stringResource(R.string.np_content_desc_prev), 30, flip = true) { touch++; SongPlayer.previous() }+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier+ .size(64.dp)+ .clip(CircleShape)+ .background(Color.White)+ .clickable { touch++; if (playing) SongPlayer.pause() else SongPlayer.play() },+ ) {+ Icon(+ painterResource(if (playing) R.drawable.ic_playing else R.drawable.play_svgrepo_com),+ contentDescription = if (playing) stringResource(R.string.content_description_pause_button) else stringResource(R.string.content_description_play_button),+ tint = Color.Black,+ modifier = Modifier.size(30.dp),+ )+ }+ RoundIcon(R.drawable.ic_player_skip, stringResource(R.string.np_content_desc_next), 30) { touch++; SongPlayer.next() }+ }+ Column(Modifier.align(Alignment.BottomCenter).fillMaxWidth().padding(horizontal = 24.dp, vertical = 12.dp)) {+ SpotifySeekBar(+ fraction = {+ frame.value+ if (dragging) dragValue else {+ val d = MusicVideoController.duration()+ if (d > 0) (MusicVideoController.position().toFloat() / d).coerceIn(0f, 1f) else 0f+ }+ },+ onDrag = { touch++; dragging = true; dragValue = it },+ onRelease = { MusicVideoController.seekTo((dragValue * MusicVideoController.duration()).toLong()); dragging = false },+ modifier = Modifier.fillMaxWidth(),+ )+ Row(verticalAlignment = Alignment.CenterVertically, modifier = Modifier.fillMaxWidth().height(48.dp)) {+ Spacer(Modifier.weight(1f))+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.size(48.dp).clickable(+ interactionSource = remember { MutableInteractionSource() }, indication = null,+ ) { MusicVideoController.fullscreen.value = false },+ ) {+ Icon(+ Icons.Default.FullscreenExit,+ contentDescription = stringResource(R.string.video_fullscreen_exit),+ tint = Color.White,+ modifier = Modifier.size(26.dp),+ )+ }+ }+ }+ }+ }+ }+}++@Composable+private fun RoundIcon(icon: Int, description: String, sizeDp: Int, flip: Boolean = false, onClick: () -> Unit) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.size((sizeDp + 18).dp).clickable(+ interactionSource = remember { MutableInteractionSource() }, indication = null, onClick = onClick,+ ),+ ) {+ Icon(+ painterResource(icon), contentDescription = description, tint = Color.White,+ modifier = Modifier.size(sizeDp.dp).graphicsLayer { if (flip) scaleX = -1f },+ )+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/PlayerSheets.kt b/base/app/src/main/java/com/music/spotui/ui/components/PlayerSheets.ktnew file mode 100644index 00000000..4fed75f0--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/PlayerSheets.kt@@ -0,0 +1,653 @@+package com.music.spotui.ui.components++import androidx.compose.ui.res.stringResource+import app.myspoti.engine.R++import androidx.compose.foundation.gestures.detectHorizontalDragGestures+import androidx.compose.foundation.background+import androidx.compose.foundation.gestures.detectDragGestures+import androidx.compose.material.icons.filled.DragHandle+import androidx.compose.material.icons.filled.Delete+import kotlinx.coroutines.launch+import androidx.compose.runtime.collectAsState+import androidx.compose.material.icons.filled.RemoveCircleOutline+import androidx.compose.ui.graphics.graphicsLayer+import androidx.compose.ui.input.pointer.pointerInput+import androidx.compose.ui.zIndex+import kotlin.math.roundToInt+import androidx.compose.foundation.clickable+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxHeight+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.navigationBarsPadding+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.lazy.items+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.filled.Computer+import androidx.compose.material.icons.filled.Equalizer+import androidx.compose.material.icons.filled.Pause+import androidx.compose.material.icons.filled.PlayArrow+import androidx.compose.material.icons.filled.Repeat+import androidx.compose.material.icons.filled.RepeatOne+import androidx.compose.material.icons.filled.Shuffle+import androidx.compose.material.icons.filled.Smartphone+import androidx.compose.material.icons.filled.Speaker+import androidx.compose.material.icons.filled.Tv+import androidx.compose.material.icons.outlined.Timer+import androidx.compose.material3.CircularProgressIndicator+import androidx.compose.material3.ExperimentalMaterial3Api+import androidx.compose.material3.HorizontalDivider+import androidx.compose.material3.Icon+import androidx.compose.material3.ModalBottomSheet+import androidx.compose.material3.SwipeToDismissBox+import androidx.compose.material3.SwipeToDismissBoxValue+import androidx.compose.material3.Text+import androidx.compose.material3.rememberModalBottomSheetState+import androidx.compose.material3.rememberSwipeToDismissBoxState+import androidx.compose.runtime.Composable+import androidx.compose.runtime.DisposableEffect+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.vector.ImageVector+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.di.Graph+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.screens.ExplicitBadge++private val Green: Color get() = com.music.spotui.ui.theme.AppAccent+private val SheetColor = Color(0xFF282828)++/** Name of the device playing now ("This phone" when it's this phone). */+@Composable+fun activeDeviceLabel(): String = SongPlayer.activeDevice.value?.name ?: stringResource(R.string.connect_phone_is_self)++private fun deviceIcon(type: String): ImageVector = when (type.uppercase()) {+ "SMARTPHONE", "TABLET" -> Icons.Default.Smartphone+ "SPEAKER", "AVR", "STB", "AUDIO_DONGLE" -> Icons.Default.Speaker+ "TV", "CAST_VIDEO", "GAME_CONSOLE" -> Icons.Default.Tv+ else -> Icons.Default.Computer+}++// ── Spotify Connect device picker ──++@OptIn(ExperimentalMaterial3Api::class)+@Composable+fun DevicesSheet(onDismiss: () -> Unit) {+ var devices by remember { mutableStateOf<List<SongPlayer.ConnectDevice>?>(null) }+ LaunchedEffect(Unit) { devices = SongPlayer.devices() }+ ModalBottomSheet(onDismissRequest = onDismiss, containerColor = SheetColor) {+ Column(modifier = Modifier.fillMaxWidth().navigationBarsPadding().padding(bottom = 16.dp)) {+ Text(+ stringResource(R.string.listen_on),+ color = Color.White, fontSize = 20.sp, fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(horizontal = 20.dp, vertical = 8.dp),+ )+ val list = devices+ if (list == null) {+ Box(Modifier.fillMaxWidth().padding(24.dp), contentAlignment = Alignment.Center) {+ CircularProgressIndicator(color = Green, modifier = Modifier.size(28.dp))+ }+ } else if (list.isEmpty()) {+ Text(stringResource(R.string.no_devices), color = Color.White.copy(alpha = 0.7f), modifier = Modifier.padding(20.dp))+ } else {+ val anyActive = list.any { it.isActive }+ list.forEach { d ->+ // This phone counts as current when nothing else is playing.+ val current = d.isActive || (d.isSelf && !anyActive)+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .clickable {+ if (!current) SongPlayer.transferTo(d)+ onDismiss()+ }+ .padding(horizontal = 20.dp, vertical = 14.dp),+ ) {+ Icon(+ if (d.isSelf) Icons.Default.Smartphone else deviceIcon(d.type),+ contentDescription = null,+ tint = if (current) Green else Color.White,+ modifier = Modifier.size(28.dp),+ )+ Spacer(Modifier.width(16.dp))+ Column {+ Text(+ if (d.isSelf) stringResource(R.string.connect_phone_is_self) else d.name,+ color = if (current) Green else Color.White,+ fontSize = 16.sp, fontWeight = FontWeight.Medium,+ )+ if (current) Text(stringResource(R.string.default_notification_channel_name), color = Green.copy(alpha = 0.8f), fontSize = 12.sp)+ }+ }+ }+ }+ JamSection(onDismiss)+ }+ }+}++/** Spotify Jam: listen together. Free accounts can join (Spotify keeps starting one to Premium). */+@Composable+private fun JamSection(onDismiss: () -> Unit) {+ val jam = app.myspoti.host.android.MyspotiRuntime.api.jam+ val context = androidx.compose.ui.platform.LocalContext.current+ val scope = androidx.compose.runtime.rememberCoroutineScope()+ val session by jam.session.collectAsState()+ val availability by androidx.compose.runtime.produceState<app.myspoti.api.JamAvailability?>(null) {+ value = runCatching { jam.refresh(); jam.availability() }.getOrDefault(app.myspoti.api.JamAvailability.UNKNOWN)+ }+ fun failed() = android.widget.Toast.makeText(context, context.getString(R.string.jam_failed), android.widget.Toast.LENGTH_SHORT).show()+ Column(Modifier.fillMaxWidth().padding(horizontal = 20.dp, vertical = 12.dp)) {+ Text(stringResource(R.string.jam_title), color = Color.White, fontSize = 18.sp, fontWeight = FontWeight.Bold)+ val s = session+ if (s != null) {+ Text(stringResource(R.string.jam_members, s.members.size), color = Green, fontSize = 13.sp, modifier = Modifier.padding(top = 4.dp))+ Text(stringResource(R.string.jam_invite), color = Color.White, fontSize = 15.sp,+ modifier = Modifier.fillMaxWidth().clickable {+ scope.launch {+ val url = runCatching { jam.inviteLink() }.getOrNull() ?: return@launch failed()+ val send = android.content.Intent(android.content.Intent.ACTION_SEND).setType("text/plain").putExtra(android.content.Intent.EXTRA_TEXT, url)+ context.startActivity(android.content.Intent.createChooser(send, null).addFlags(android.content.Intent.FLAG_ACTIVITY_NEW_TASK))+ }+ }.padding(vertical = 10.dp))+ Text(stringResource(R.string.jam_leave), color = Color.White, fontSize = 15.sp,+ modifier = Modifier.fillMaxWidth().clickable {+ scope.launch { runCatching { if (s.isHost) jam.end() else jam.leave() }; onDismiss() }+ }.padding(vertical = 10.dp))+ return@Column+ }+ if (availability == app.myspoti.api.JamAvailability.AVAILABLE) Text(stringResource(R.string.jam_start), color = Green, fontSize = 15.sp,+ modifier = Modifier.fillMaxWidth().clickable {+ scope.launch { if (runCatching { jam.start() }.isFailure) failed() }+ }.padding(vertical = 10.dp))+ // Join: scan the QR code another phone shows in its Jam.+ Text(stringResource(R.string.jam_scan), color = Green, fontSize = 15.sp,+ modifier = Modifier.fillMaxWidth().clickable {+ com.google.mlkit.vision.codescanner.GmsBarcodeScanning.getClient(context).startScan()+ .addOnSuccessListener { code ->+ val raw = code.rawValue.orEmpty()+ scope.launch {+ val token = JamLinks.token(raw)+ if (token == null || runCatching { jam.join(token) }.isFailure) failed() else onDismiss()+ }+ }+ }.padding(vertical = 10.dp))+ }+}++/** Jam invite codes: `open.spotify.com/socialsession/<token>`, or a spotify.link short link to it. */+private object JamLinks {+ private val http = okhttp3.OkHttpClient.Builder().followRedirects(true).build()++ suspend fun token(raw: String): String? {+ val url = if (raw.contains("spotify.link") || raw.contains("spoti.fi")) resolve(raw) ?: raw else raw+ Regex("socialsession/([A-Za-z0-9_-]+)").find(url)?.let { return it.groupValues[1] }+ Regex("spotify:socialsession:([A-Za-z0-9_-]+)").find(url)?.let { return it.groupValues[1] }+ return null+ }++ /** Where a short link leads (its final URL after redirects). */+ private suspend fun resolve(link: String): String? = kotlinx.coroutines.withContext(kotlinx.coroutines.Dispatchers.IO) {+ runCatching {+ http.newCall(okhttp3.Request.Builder().url(link).header("user-agent", "Mozilla/5.0").build()).execute().use { r ->+ val final = r.request.url.toString()+ // Some short links answer with a page that holds the target in a meta refresh / link.+ if (final.contains("socialsession")) final+ else Regex("https://open\\.spotify\\.com/socialsession/[A-Za-z0-9_-]+").find(r.body.string())?.value ?: final+ }+ }.getOrNull()+ }+}++// ── Sleep timer ──++@OptIn(ExperimentalMaterial3Api::class)+@Composable+fun SleepTimerSheet(onDismiss: () -> Unit) {+ val active = SongPlayer.sleepEndsAt.value != null+ ModalBottomSheet(onDismissRequest = onDismiss, containerColor = SheetColor) {+ Column(modifier = Modifier.fillMaxWidth().navigationBarsPadding().padding(bottom = 16.dp)) {+ Text(+ stringResource(R.string.context_menu_sleep_timer),+ color = Color.White, fontSize = 20.sp, fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(horizontal = 20.dp, vertical = 8.dp),+ )+ val endOfTrack = stringResource(R.string.context_menu_sleep_timer_end_of_track)+ val options = buildList {+ for (m in listOf(5, 10, 15, 30, 45)) add(stringResource(R.string.sleep_minutes, m) to m)+ add(stringResource(R.string.mute_chat_duration_one_hour) to 60)+ add(endOfTrack to 0)+ }+ options.forEach { (label, minutes) ->+ Text(+ label,+ color = Color.White, fontSize = 16.sp,+ modifier = Modifier+ .fillMaxWidth()+ .clickable { SongPlayer.setSleepTimer(minutes); onDismiss() }+ .padding(horizontal = 20.dp, vertical = 14.dp),+ )+ }+ if (active) {+ Text(+ stringResource(R.string.context_menu_sleep_timer_turn_off),+ color = Green, fontSize = 16.sp, fontWeight = FontWeight.Bold,+ modifier = Modifier+ .fillMaxWidth()+ .clickable { SongPlayer.setSleepTimer(null); onDismiss() }+ .padding(horizontal = 20.dp, vertical = 14.dp),+ )+ }+ }+ }+}++// ── Queue (official layout: sheet over the now-playing screen) ──++private val QueueRowHeight = 64.dp++@OptIn(ExperimentalMaterial3Api::class, ExperimentalGlideComposeApi::class)+@Composable+fun QueueSheet(contextName: String, onDismiss: () -> Unit) {+ DisposableEffect(Unit) {+ SongPlayer.watchQueue(true)+ onDispose { SongPlayer.watchQueue(false) }+ }+ val q by SongPlayer.engineQueue+ val state = Graph.currentSongState+ val playing = state.playingState.value+ val shuffle = state.shuffle.value+ var showTimer by remember { mutableStateOf(false) }+ var editing by remember { mutableStateOf(false) }+ if (showTimer) SleepTimerSheet { showTimer = false }++ ModalBottomSheet(+ onDismissRequest = onDismiss,+ sheetState = rememberModalBottomSheetState(skipPartiallyExpanded = true),+ containerColor = SheetColor,+ ) {+ Column(modifier = Modifier.fillMaxWidth().fillMaxHeight(0.92f).navigationBarsPadding()) {+ Row(verticalAlignment = Alignment.Top, modifier = Modifier.fillMaxWidth().padding(horizontal = 20.dp)) {+ Column(modifier = Modifier.weight(1f)) {+ Text(stringResource(R.string.action_queue_label), color = Color.White, fontSize = 22.sp, fontWeight = FontWeight.Bold)+ if (contextName.isNotBlank()) Row(modifier = Modifier.padding(top = 4.dp)) {+ Text(stringResource(R.string.playing_on), color = Color.White.copy(alpha = 0.7f), fontSize = 14.sp)+ Text(contextName, color = Color.White, fontSize = 14.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ Row(verticalAlignment = Alignment.CenterVertically, modifier = Modifier.padding(top = 4.dp, bottom = 8.dp)) {+ Icon(Icons.Default.Smartphone, contentDescription = null, tint = Green, modifier = Modifier.size(16.dp))+ Spacer(Modifier.width(6.dp))+ Text(activeDeviceLabel(), color = Green, fontSize = 13.sp)+ }+ }+ PillButton(if (editing) "OK" else stringResource(R.string.curation_actions_edit_button_title)) { editing = !editing }+ }+ LazyColumn(modifier = Modifier.weight(1f)) {+ q.current?.let { cur ->+ item(key = "current") {+ QueueSheetRow(cur, current = true, trailing = {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier+ .size(36.dp)+ .clip(CircleShape)+ .background(Color.White)+ .clickable { if (playing) SongPlayer.pause() else SongPlayer.play() },+ ) {+ Icon(+ if (playing) Icons.Default.Pause else Icons.Default.PlayArrow,+ contentDescription = if (playing) stringResource(R.string.content_description_pause_button) else stringResource(R.string.content_description_play_button),+ tint = Color.Black, modifier = Modifier.size(22.dp),+ )+ }+ }, onClick = {})+ }+ }+ item(key = "queue") { QueueList(q, contextName, editing) }+ }+ Row(+ horizontalArrangement = Arrangement.spacedBy(10.dp),+ modifier = Modifier.fillMaxWidth().padding(horizontal = 16.dp, vertical = 10.dp),+ ) {+ QueueAction(Icons.Default.Shuffle, stringResource(R.string.play_mode_item_shuffle_title), shuffle, Modifier.weight(1f)) {+ SongPlayer.setShuffle(!shuffle); state.shuffle.value = !shuffle+ }+ val mode = SongPlayer.repeatMode.value+ QueueAction(if (mode == 2) Icons.Default.RepeatOne else Icons.Default.Repeat, stringResource(R.string.np_content_desc_repeat), mode != 0, Modifier.weight(1f)) {+ SongPlayer.cycleRepeat()+ }+ QueueAction(Icons.Outlined.Timer, stringResource(R.string.np_content_desc_sleep_timer), SongPlayer.sleepEndsAt.value != null, Modifier.weight(1f)) {+ showTimer = true+ }+ }+ }+ }+}++@Composable+private fun PillButton(label: String, onClick: () -> Unit) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier+ .clip(RoundedCornerShape(50))+ .background(Color(0xFF3E3E3E))+ .clickable(onClick = onClick)+ .padding(horizontal = 18.dp, vertical = 8.dp),+ ) { Text(label, color = Color.White, fontSize = 14.sp, fontWeight = FontWeight.Bold) }+}++private val QueueHeaderHeight = 48.dp++private sealed class QEntry {+ data class Header(val queuedSection: Boolean) : QEntry()+ data class Row(val item: SongPlayer.QueueItem, val queued: Boolean) : QEntry()+}++/**+ * The upcoming tracks as ONE draggable list: "Prochains titres dans la file d'attente"+ * then "Suivants de : …". Dragging a track above the "Suivants" header moves it into+ * the queue (official behaviour). Drag handle on every row; swipe right removes.+ */+@Composable+private fun QueueList(q: SongPlayer.EngineQueue, contextName: String, editing: Boolean) {+ val haptic = androidx.compose.ui.platform.LocalHapticFeedback.current+ val density = androidx.compose.ui.platform.LocalDensity.current+ val rowPx = with(density) { QueueRowHeight.toPx() }+ val headerPx = with(density) { QueueHeaderHeight.toPx() }++ var queued by remember(q.queued) { mutableStateOf(q.queued) }+ var nextUp by remember(q.nextUp) { mutableStateOf(q.nextUp) }+ var dragging by remember { mutableStateOf<SongPlayer.QueueItem?>(null) }+ var dragOffset by remember { mutableStateOf(0f) }+ var lastSlot by remember { mutableStateOf(-1) }++ val entries = buildList {+ if (queued.isNotEmpty()) add(QEntry.Header(true))+ queued.forEach { add(QEntry.Row(it, true)) }+ if (nextUp.isNotEmpty()) add(QEntry.Header(false))+ nextUp.forEach { add(QEntry.Row(it, false)) }+ }+ fun height(e: QEntry) = if (e is QEntry.Header) headerPx else rowPx+ fun topOf(index: Int) = entries.take(index).sumOf { height(it).toDouble() }.toFloat()++ /** Entry under a y position (list coordinates). */+ fun entryAt(y: Float): Int {+ var acc = 0f+ entries.forEachIndexed { i, e -> acc += height(e); if (y < acc) return i }+ return entries.lastIndex+ }++ fun drop(item: SongPlayer.QueueItem, fromQueued: Boolean, centerY: Float) {+ val nextHeaderIndex = entries.indexOfFirst { it is QEntry.Header && !it.queuedSection }+ val nextHeaderMid = if (nextHeaderIndex >= 0) topOf(nextHeaderIndex) + headerPx / 2 else Float.MAX_VALUE+ val toQueue = fromQueued || centerY < nextHeaderMid+ if (toQueue) {+ val others = queued - item+ if (others.isEmpty()) {+ if (!fromQueued) {+ // Empty queue: becomes the first queued track.+ nextUp = nextUp - item; queued = listOf(item)+ SongPlayer.moveToQueueFront(item)+ }+ return+ }+ // Position among the queued rows (rows start after the queue header).+ val slot = ((centerY - headerPx) / rowPx).toInt().coerceIn(0, others.size)+ val newQueued = others.toMutableList().apply { add(slot, item) }+ if (newQueued == queued) return+ if (!fromQueued) nextUp = nextUp - item+ queued = newQueued+ if (slot < others.size) SongPlayer.reorder(item, others[slot], after = false)+ else SongPlayer.reorder(item, others[slot - 1], after = true)+ } else {+ val others = nextUp - item+ if (others.isEmpty()) return+ val startY = topOf(nextHeaderIndex) + headerPx+ val slot = ((centerY - startY) / rowPx).toInt().coerceIn(0, others.size)+ val newNext = others.toMutableList().apply { add(slot, item) }+ if (newNext == nextUp) return+ nextUp = newNext+ if (slot < others.size) SongPlayer.reorder(item, others[slot], after = false)+ else SongPlayer.reorder(item, others[slot - 1], after = true)+ }+ }++ Column {+ entries.forEachIndexed { index, e ->+ when (e) {+ is QEntry.Header -> Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().height(QueueHeaderHeight),+ ) {+ Box(Modifier.weight(1f)) {+ SheetHeader(+ if (e.queuedSection) stringResource(R.string.next_in_queue)+ else if (contextName.isNotBlank()) stringResource(R.string.next_from, contextName) else stringResource(R.string.next_up)+ )+ }+ if (e.queuedSection) Text(+ stringResource(R.string.clear_queue),+ color = Color.White, fontSize = 13.sp, fontWeight = FontWeight.Bold,+ modifier = Modifier+ .padding(end = 20.dp)+ .clickable {+ haptic.performHapticFeedback(androidx.compose.ui.hapticfeedback.HapticFeedbackType.Confirm)+ queued = emptyList(); SongPlayer.clearQueue()+ },+ )+ }+ is QEntry.Row -> {+ val item = e.item+ val isDragged = dragging == item+ Box(+ modifier = Modifier+ .graphicsLayer { translationY = if (isDragged) dragOffset else 0f }+ .zIndex(if (isDragged) 1f else 0f)+ .background(if (isDragged) Color(0xFF3A3A3A) else SheetColor)+ ) {+ SwipeLeftToRemove(enabled = !editing && dragging == null, onRemove = {+ if (e.queued) queued = queued - item else nextUp = nextUp - item+ SongPlayer.removeFromQueue(item)+ }) {+ QueueSheetRow(item.song, current = false, leading = {+ if (editing) Icon(+ Icons.Default.RemoveCircleOutline,+ contentDescription = stringResource(R.string.aligned_curation_first_save_default_row_remove_action_description),+ tint = Color.White.copy(alpha = 0.8f),+ modifier = Modifier+ .padding(end = 12.dp)+ .size(24.dp)+ .clickable {+ if (e.queued) queued = queued - item else nextUp = nextUp - item+ SongPlayer.removeFromQueue(item)+ },+ )+ }, trailing = {+ Icon(+ Icons.Default.DragHandle,+ contentDescription = stringResource(R.string.edit_playlist_items_move_chip),+ tint = Color.White.copy(alpha = 0.8f),+ modifier = Modifier+ .size(28.dp)+ .pointerInput(item.uid + item.uri) {+ detectDragGestures(+ onDragStart = {+ dragging = item; dragOffset = 0f; lastSlot = index+ haptic.performHapticFeedback(androidx.compose.ui.hapticfeedback.HapticFeedbackType.LongPress)+ },+ onDragEnd = {+ val center = topOf(entries.indexOf(e)) + dragOffset + rowPx / 2+ drop(item, e.queued, center)+ haptic.performHapticFeedback(androidx.compose.ui.hapticfeedback.HapticFeedbackType.GestureEnd)+ dragging = null; dragOffset = 0f+ },+ onDragCancel = { dragging = null; dragOffset = 0f },+ ) { change, amount ->+ change.consume()+ dragOffset += amount.y+ val slot = entryAt(topOf(entries.indexOf(e)) + dragOffset + rowPx / 2)+ if (slot != lastSlot) {+ lastSlot = slot+ haptic.performHapticFeedback(androidx.compose.ui.hapticfeedback.HapticFeedbackType.SegmentTick)+ }+ }+ },+ )+ }, onClick = { if (!editing) SongPlayer.skipTo(item) })+ }+ }+ }+ }+ }+ }+}++/** Swipe a queue row from right to left to remove it (red strip, haptic tick at the threshold). */+@Composable+private fun SwipeLeftToRemove(enabled: Boolean, onRemove: () -> Unit, content: @Composable () -> Unit) {+ val haptic = androidx.compose.ui.platform.LocalHapticFeedback.current+ val scope = androidx.compose.runtime.rememberCoroutineScope()+ val threshold = with(androidx.compose.ui.platform.LocalDensity.current) { 110.dp.toPx() }+ val offset = remember { androidx.compose.animation.core.Animatable(0f) }+ var armed by remember { mutableStateOf(false) }+ Box(modifier = Modifier.fillMaxWidth()) {+ if (offset.value < 0f) Box(+ contentAlignment = Alignment.CenterEnd,+ modifier = Modifier.matchParentSize().background(if (armed) Color(0xFFE22134) else Color(0xFF7A1F1F)),+ ) {+ Icon(Icons.Default.Delete, contentDescription = stringResource(R.string.aligned_curation_first_save_default_row_remove_action_description), tint = Color.White, modifier = Modifier.padding(end = 24.dp).size(24.dp))+ }+ Box(+ modifier = Modifier+ .graphicsLayer { translationX = offset.value }+ .background(SheetColor)+ .pointerInput(enabled) {+ if (!enabled) return@pointerInput+ detectHorizontalDragGestures(+ onDragEnd = {+ if (armed) {+ scope.launch { offset.animateTo(-size.width.toFloat()) ; onRemove(); offset.snapTo(0f) }+ } else scope.launch { offset.animateTo(0f) }+ armed = false+ },+ onDragCancel = { armed = false; scope.launch { offset.animateTo(0f) } },+ ) { change, dx ->+ change.consume()+ val next = (offset.value + dx).coerceIn(-size.width.toFloat(), 0f)+ scope.launch { offset.snapTo(next) }+ val nowArmed = -next >= threshold+ if (nowArmed && !armed) haptic.performHapticFeedback(androidx.compose.ui.hapticfeedback.HapticFeedbackType.GestureThresholdActivate)+ armed = nowArmed+ }+ },+ ) { content() }+ }+}++@Composable+private fun SheetHeader(text: String) {+ Text(+ text, color = Color.White, fontSize = 15.sp, fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(horizontal = 20.dp),+ )+}++@OptIn(ExperimentalMaterial3Api::class)+@Composable+private fun SwipeToRemove(item: SongPlayer.QueueItem) {+ val dismiss = rememberSwipeToDismissBoxState(confirmValueChange = { v ->+ if (v != SwipeToDismissBoxValue.Settled) { SongPlayer.removeFromQueue(item); true } else false+ })+ SwipeToDismissBox(+ state = dismiss,+ backgroundContent = { Box(Modifier.fillMaxWidth().fillMaxHeight().background(Color(0xFF7A1F1F))) },+ ) {+ Box(Modifier.background(SheetColor)) {+ QueueSheetRow(item.song, current = false, trailing = {}, onClick = { SongPlayer.skipTo(item) })+ }+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun QueueSheetRow(+ song: SongsModel,+ current: Boolean,+ leading: @Composable () -> Unit = {},+ trailing: @Composable () -> Unit,+ onClick: () -> Unit,+) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .height(QueueRowHeight)+ .clickable(onClick = onClick)+ .padding(horizontal = 20.dp),+ ) {+ leading()+ GlideImage(+ model = song.coverUri, contentDescription = "", contentScale = ContentScale.Crop,+ modifier = Modifier.size(48.dp).clip(RoundedCornerShape(4.dp)),+ )+ Spacer(Modifier.width(12.dp))+ Column(modifier = Modifier.weight(1f)) {+ Row(verticalAlignment = Alignment.CenterVertically) {+ if (current) {+ Icon(Icons.Default.Equalizer, contentDescription = null, tint = Green, modifier = Modifier.size(16.dp))+ Spacer(Modifier.width(4.dp))+ }+ Text(+ song.title, color = if (current) Green else Color.White, fontSize = 16.sp,+ maxLines = 1, overflow = TextOverflow.Ellipsis,+ )+ }+ Row(verticalAlignment = Alignment.CenterVertically, modifier = Modifier.padding(top = 2.dp)) {+ if (song.explicit) { ExplicitBadge(); Spacer(Modifier.width(6.dp)) }+ Text(song.singer, color = Color.White.copy(alpha = 0.7f), fontSize = 14.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ }+ trailing()+ }+}++@Composable+private fun QueueAction(icon: ImageVector, label: String, active: Boolean, modifier: Modifier, onClick: () -> Unit) {+ Column(+ horizontalAlignment = Alignment.CenterHorizontally,+ modifier = modifier+ .clip(RoundedCornerShape(8.dp))+ .background(Color(0xFF3E3E3E))+ .clickable(onClick = onClick)+ .padding(vertical = 10.dp),+ ) {+ Icon(icon, contentDescription = null, tint = if (active) Green else Color.White, modifier = Modifier.size(26.dp))+ Spacer(Modifier.height(4.dp))+ Text(label, color = if (active) Green else Color.White, fontSize = 13.sp, maxLines = 1)+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/PullToDismiss.kt b/base/app/src/main/java/com/music/spotui/ui/components/PullToDismiss.ktnew file mode 100644index 00000000..baf56df2--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/PullToDismiss.kt@@ -0,0 +1,85 @@+package com.music.spotui.ui.components++import androidx.compose.animation.core.Animatable+import androidx.compose.runtime.Composable+import androidx.compose.runtime.remember+import androidx.compose.runtime.rememberCoroutineScope+import androidx.compose.runtime.rememberUpdatedState+import androidx.compose.ui.geometry.Offset+import androidx.compose.ui.input.nestedscroll.NestedScrollConnection+import androidx.compose.ui.input.nestedscroll.NestedScrollSource+import androidx.compose.ui.platform.LocalDensity+import androidx.compose.ui.unit.Velocity+import androidx.compose.ui.unit.dp+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.launch++/**+ * A full-screen sheet pulled down from the top of its list closes, like the official+ * player: the sheet follows the finger (with some resistance) and closes past+ * [thresholdPx] or on a quick flick down; otherwise it springs back. Attach+ * [connection] to the list's `nestedScroll` and move the sheet by [offset].+ */+class PullToDismissState internal constructor(+ private val scope: CoroutineScope,+ private val thresholdPx: Float,+ private val flingPx: Float,+ private val dismiss: () -> Unit,+) {+ var enabled = true+ private val pull = Animatable(0f)+ private var raw = 0f+ private var dismissed = false++ /** How far the sheet is pulled down, in pixels. */+ val offset: Float get() = pull.value++ private fun follow() {+ scope.launch { pull.snapTo(raw * RESISTANCE) }+ }++ val connection = object : NestedScrollConnection {+ // Pushing back up first undoes the pull, before the list scrolls.+ override fun onPreScroll(available: Offset, source: NestedScrollSource): Offset {+ if (raw <= 0f || available.y >= 0f || source != NestedScrollSource.UserInput) return Offset.Zero+ val used = maxOf(available.y, -raw)+ raw += used+ follow()+ return Offset(0f, used)+ }++ // What the list could not scroll (it is at its top) pulls the sheet down.+ override fun onPostScroll(consumed: Offset, available: Offset, source: NestedScrollSource): Offset {+ if (!enabled || dismissed || available.y <= 0f || source != NestedScrollSource.UserInput) return Offset.Zero+ raw += available.y+ follow()+ return Offset(0f, available.y)+ }++ override suspend fun onPreFling(available: Velocity): Velocity {+ if (raw <= 0f) return Velocity.Zero+ if (raw > thresholdPx || available.y > flingPx) {+ dismissed = true+ dismiss()+ } else {+ raw = 0f+ pull.animateTo(0f)+ }+ return available+ }+ }++ private companion object {+ const val RESISTANCE = 0.6f+ }+}++@Composable+fun rememberPullToDismiss(onDismiss: () -> Unit): PullToDismissState {+ val scope = rememberCoroutineScope()+ val density = LocalDensity.current+ val latest = rememberUpdatedState(onDismiss)+ return remember(density) {+ with(density) { PullToDismissState(scope, 120.dp.toPx(), 1200.dp.toPx()) { latest.value() } }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/SavedInSheet.kt b/base/app/src/main/java/com/music/spotui/ui/components/SavedInSheet.ktnew file mode 100644index 00000000..2d86a5cf--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/SavedInSheet.kt@@ -0,0 +1,284 @@+package com.music.spotui.ui.components++import androidx.compose.ui.res.stringResource++import android.content.Context+import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.heightIn+import androidx.compose.foundation.layout.navigationBarsPadding+import androidx.compose.foundation.layout.imePadding+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.foundation.text.KeyboardActions+import androidx.compose.foundation.text.KeyboardOptions+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.filled.Add+import androidx.compose.material.icons.filled.CheckCircle+import androidx.compose.material.icons.filled.Favorite+import androidx.compose.material3.ExperimentalMaterial3Api+import androidx.compose.material3.Icon+import androidx.compose.material3.ModalBottomSheet+import androidx.compose.material3.Text+import androidx.compose.material3.TextField+import androidx.compose.material3.TextFieldDefaults+import androidx.compose.material3.rememberModalBottomSheetState+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateMapOf+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Brush+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.input.ImeAction+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.bumptech.glide.integration.compose.placeholder+import app.myspoti.engine.R+import androidx.compose.ui.res.pluralStringResource+import com.music.spotui.data.api.SpotifySync+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.data.preferences.addLikedSongId+import com.music.spotui.data.preferences.isSongLiked+import com.music.spotui.data.preferences.removeLikedSongId+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.withContext++private val SpotifyGreen: Color get() = com.music.spotui.ui.theme.AppAccent++/**+ * Spotify's "Saved in" sheet: Liked Songs plus every user playlist, each row+ * toggling the track in/out of it (mirrored to the real Spotify account), and a+ * stringResource(R.string.add_to_playlist_new_playlist_button_text) action that creates one on Spotify with the track in it.+ */+@OptIn(ExperimentalMaterial3Api::class, ExperimentalGlideComposeApi::class)+@Composable+fun SavedInSheet(+ song: SongsModel,+ context: Context,+ onDismiss: () -> Unit,+ onLikedChanged: (Boolean) -> Unit = {},+) {+ val sheetState = rememberModalBottomSheetState(skipPartiallyExpanded = true)+ val liked = com.music.spotui.di.rememberTrackSaved(song.spotifyTrackId)+ var playlists by remember { mutableStateOf<List<com.music.spotui.data.api.EditablePlaylist>?>(null) }+ // playlistId → does it contain this track (filled lazily per row).+ val membership = remember { mutableStateMapOf<String, Boolean>() }+ var creating by remember { mutableStateOf(false) }+ var newName by remember { mutableStateOf("") }++ LaunchedEffect(Unit) {+ // Only playlists the user can change: theirs and collaborative ones.+ playlists = com.music.spotui.data.api.EditablePlaylists.load()+ }++ fun createNow() {+ val name = newName.trim().ifBlank { context.getString(R.string.my_playlist) }+ creating = false+ newName = ""+ SpotifySync.createPlaylistWithTrack(context, name, song.spotifyTrackId)+ onDismiss()+ }++ ModalBottomSheet(+ onDismissRequest = onDismiss,+ sheetState = sheetState,+ containerColor = Color(0xFF1A1A1A),+ ) {+ Column(modifier = Modifier.navigationBarsPadding().imePadding()) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ horizontalArrangement = Arrangement.SpaceBetween,+ modifier = Modifier+ .fillMaxWidth()+ .padding(20.dp, 4.dp, 20.dp, 12.dp),+ ) {+ Text(stringResource(R.string.add_to_playlist_saved_in_section_header), color = Color.White, fontSize = 20.sp, fontWeight = FontWeight.Bold)+ Text(+ stringResource(R.string.add_to_playlist_new_playlist_button_text),+ color = SpotifyGreen,+ fontSize = 14.sp,+ fontWeight = FontWeight.SemiBold,+ modifier = Modifier.clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { creating = true },+ )+ }++ if (creating) {+ TextField(+ value = newName,+ onValueChange = { newName = it },+ singleLine = true,+ placeholder = { Text(stringResource(R.string.playlist_name), color = Color.Gray) },+ keyboardOptions = KeyboardOptions(imeAction = ImeAction.Done),+ keyboardActions = KeyboardActions(onDone = { createNow() }),+ colors = TextFieldDefaults.colors(+ focusedContainerColor = Color(0xFF2A2A2A),+ unfocusedContainerColor = Color(0xFF2A2A2A),+ focusedTextColor = Color.White,+ unfocusedTextColor = Color.White,+ cursorColor = SpotifyGreen,+ focusedIndicatorColor = Color.Transparent,+ unfocusedIndicatorColor = Color.Transparent,+ ),+ modifier = Modifier+ .fillMaxWidth()+ .padding(20.dp, 0.dp, 20.dp, 8.dp)+ .clip(RoundedCornerShape(8.dp)),+ )+ Row(modifier = Modifier.padding(20.dp, 0.dp, 20.dp, 8.dp)) {+ Text(+ stringResource(R.string.create_playlist_create_button),+ color = SpotifyGreen,+ fontSize = 14.sp,+ fontWeight = FontWeight.Bold,+ modifier = Modifier.clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { createNow() },+ )+ Spacer(Modifier.width(24.dp))+ Text(+ stringResource(R.string.add_to_playlist_button_cancel),+ color = Color.Gray,+ fontSize = 14.sp,+ modifier = Modifier.clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { creating = false; newName = "" },+ )+ }+ }++ // ── Liked Songs ──+ SavedInRow(+ name = stringResource(R.string.collection_liked_songs_title),+ subtitle = "",+ saved = liked,+ cover = {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier+ .size(48.dp)+ .clip(RoundedCornerShape(4.dp))+ .background(+ Brush.linearGradient(listOf(Color(0xFF4A39EA), Color(0xFF868AE1)))+ ),+ ) {+ Icon(Icons.Default.Favorite, contentDescription = null, tint = Color.White, modifier = Modifier.size(20.dp))+ }+ },+ ) {+ com.music.spotui.di.SongPlayer.setTrackSaved(song.spotifyTrackId, !liked)+ onLikedChanged(!liked)+ }++ when (val list = playlists) {+ null -> Text(stringResource(R.string.loading_playlists), color = Color.Gray, fontSize = 14.sp, modifier = Modifier.padding(20.dp, 12.dp))+ else -> LazyColumn(modifier = Modifier.heightIn(max = 420.dp)) {+ items(list.size) { i ->+ val pl = list[i]+ // Resolve membership lazily (cached per session in SpotifySync).+ LaunchedEffect(pl.id, song.spotifyTrackId) {+ if (membership[pl.id] == null && song.spotifyTrackId.isNotBlank()) {+ membership[pl.id] = withContext(Dispatchers.IO) {+ SpotifySync.playlistTrackIds(context, pl.id).contains(song.spotifyTrackId)+ }+ }+ }+ val saved = membership[pl.id] == true+ SavedInRow(+ name = pl.name,+ subtitle = pluralStringResource(R.plurals.liked_songs_header_metadata_text, pl.trackCount, pl.trackCount),+ saved = saved,+ cover = {+ GlideImage(+ modifier = Modifier+ .size(48.dp)+ .clip(RoundedCornerShape(4.dp)),+ model = pl.imageUrl,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ },+ ) {+ if (song.spotifyTrackId.isBlank()) return@SavedInRow+ membership[pl.id] = !saved+ // Refused by Spotify: back to the real state, and say so.+ val done: (Boolean) -> Unit = { ok ->+ if (!ok) android.os.Handler(android.os.Looper.getMainLooper()).post {+ membership[pl.id] = saved+ android.widget.Toast.makeText(context, context.getString(R.string.playlist_change_refused), android.widget.Toast.LENGTH_SHORT).show()+ }+ }+ if (saved) SpotifySync.removeTrackFromPlaylist(context, pl.id, song.spotifyTrackId, done)+ else SpotifySync.addTrackToPlaylist(context, pl.id, song.spotifyTrackId, done)+ }+ }+ }+ }+ Spacer(modifier = Modifier.padding(10.dp))+ }+ }+}++@Composable+private fun SavedInRow(+ name: String,+ subtitle: String,+ saved: Boolean,+ cover: @Composable () -> Unit,+ onToggle: () -> Unit,+) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { onToggle() }+ .padding(20.dp, 8.dp),+ ) {+ cover()+ Column(+ modifier = Modifier+ .weight(1f)+ .padding(start = 14.dp, end = 8.dp),+ ) {+ Text(name, color = Color.White, fontSize = 15.sp, fontWeight = FontWeight.Medium, maxLines = 1, overflow = TextOverflow.Ellipsis)+ if (subtitle.isNotBlank()) {+ Text(subtitle, color = Color.Gray, fontSize = 13.sp, maxLines = 1)+ }+ }+ if (saved) {+ Icon(Icons.Default.CheckCircle, contentDescription = stringResource(R.string.curation_button_saved_text), tint = SpotifyGreen, modifier = Modifier.size(26.dp))+ } else {+ Icon(Icons.Default.Add, contentDescription = stringResource(R.string.add_to_playlist_new_playlist_button_text), tint = Color(0xFFB3B3B3), modifier = Modifier.size(26.dp))+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/SongOptionsSheet.kt b/base/app/src/main/java/com/music/spotui/ui/components/SongOptionsSheet.ktnew file mode 100644index 00000000..09522434--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/SongOptionsSheet.kt@@ -0,0 +1,325 @@+package com.music.spotui.ui.components++import app.myspoti.engine.R++import androidx.compose.ui.res.stringResource++import android.content.Context+import android.content.Intent+import android.widget.Toast+import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.navigationBarsPadding+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.rememberScrollState+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.foundation.verticalScroll+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.automirrored.filled.PlaylistAdd+import androidx.compose.material.icons.automirrored.filled.PlaylistPlay+import androidx.compose.material.icons.automirrored.filled.QueueMusic+import androidx.compose.material.icons.filled.Album+import androidx.compose.material.icons.filled.Bedtime+import androidx.compose.material.icons.filled.Check+import androidx.compose.material.icons.outlined.AddCircleOutline+import androidx.compose.material.icons.outlined.ArrowCircleDown+import androidx.compose.material.icons.outlined.Person+import androidx.compose.material.icons.outlined.Radio+import androidx.compose.material.icons.outlined.Share+import androidx.compose.material.icons.outlined.Info+import androidx.compose.material.icons.outlined.Block+import androidx.compose.material.icons.outlined.Speed+import kotlinx.coroutines.launch+import androidx.compose.material3.ExperimentalMaterial3Api+import androidx.compose.material3.HorizontalDivider+import androidx.compose.material3.Icon+import androidx.compose.material3.ModalBottomSheet+import androidx.compose.material3.Text+import androidx.compose.material3.rememberModalBottomSheetState+import androidx.compose.runtime.Composable+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.vector.ImageVector+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.navigation.NavController+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.navigation.albumRoute++private val MenuSheetColor = Color(0xFF282828)+private val MenuIconColor = Color(0xFFB3B3B3)+private val MenuGreen: Color get() = com.music.spotui.ui.theme.AppAccent++/**+ * The track menu, one for the whole app (long press on a track, ⋮ in the player),+ * with the official app's wording and order: like, add to a playlist, play next,+ * add to queue, album, artist, share; plus queue and sleep timer for the track+ * that is playing.+ */+@OptIn(ExperimentalMaterial3Api::class, ExperimentalGlideComposeApi::class)+@Composable+fun SongOptionsSheet(+ song: SongsModel,+ navController: NavController,+ context: Context,+ onDismiss: () -> Unit,+ nowPlaying: Boolean = false,+ onOpenQueue: (() -> Unit)? = null,+) {+ val playerViewModel: com.music.spotui.ui.viewmodel.PlayerViewModel =+ androidx.lifecycle.viewmodel.compose.viewModel()+ val sheetState = rememberModalBottomSheetState(skipPartiallyExpanded = true)+ val liked = com.music.spotui.di.rememberTrackSaved(song.spotifyTrackId)+ var showSavedIn by remember { mutableStateOf(false) }+ var showSleep by remember { mutableStateOf(false) }+ var showCredits by remember { mutableStateOf(false) }+ var showSpeed by remember { mutableStateOf(false) }+ if (showCredits) {+ CreditsSheet(song = song, onDismiss = { showCredits = false; onDismiss() })+ return+ }+ if (showSpeed) {+ SpeedSheet(onDismiss = { showSpeed = false; onDismiss() })+ return+ }+ if (showSavedIn) {+ SavedInSheet(song = song, context = context, onDismiss = { showSavedIn = false; onDismiss() })+ return+ }+ if (showSleep) {+ SleepTimerSheet(onDismiss = { showSleep = false; onDismiss() })+ return+ }+ val hasId = song.spotifyTrackId.isNotBlank()+ fun toast(text: String) = Toast.makeText(context, text, Toast.LENGTH_SHORT).show()++ ModalBottomSheet(+ onDismissRequest = onDismiss,+ sheetState = sheetState,+ containerColor = MenuSheetColor,+ ) {+ Column(modifier = Modifier.navigationBarsPadding().verticalScroll(rememberScrollState())) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().padding(16.dp, 0.dp, 16.dp, 16.dp),+ ) {+ GlideImage(+ modifier = Modifier.size(48.dp).clip(RoundedCornerShape(4.dp)),+ model = song.coverUri,+ contentScale = ContentScale.Crop,+ contentDescription = "",+ )+ Spacer(modifier = Modifier.width(12.dp))+ Column {+ Text(song.title, color = Color.White, fontSize = 16.sp, fontWeight = FontWeight.Bold, maxLines = 1, overflow = TextOverflow.Ellipsis)+ Text(song.singer, color = MenuIconColor, fontSize = 14.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ }+ HorizontalDivider(color = Color(0xFF3E3E3E), thickness = 0.5.dp)+ Spacer(Modifier.height(8.dp))++ MenuRow(+ icon = if (liked) null else Icons.Outlined.AddCircleOutline,+ label = stringResource(if (liked) R.string.collection_liked_songs_title else R.string.aligned_curation_context_menu_item_add_to_liked_songs),+ enabled = hasId,+ leading = if (liked) ({ LikedBadge() }) else null,+ ) {+ SongPlayer.setTrackSaved(song.spotifyTrackId, !liked)+ toast(context.getString(if (liked) R.string.snackbar_removed_from_liked_songs else R.string.snackbar_added_to_liked_songs))+ onDismiss()+ }+ MenuRow(Icons.AutoMirrored.Filled.PlaylistAdd, stringResource(R.string.context_menu_add_to_playlist), enabled = hasId) { showSavedIn = true }+ if (!nowPlaying) {+ MenuRow(Icons.AutoMirrored.Filled.PlaylistPlay, stringResource(R.string.context_menu_play_next), enabled = hasId) {+ playerViewModel.playNext(song)+ com.music.spotui.di.Haptics.confirm()+ toast(context.getString(R.string.context_menu_play_next))+ onDismiss()+ }+ MenuRow(Icons.AutoMirrored.Filled.QueueMusic, stringResource(R.string.context_menu_add_to_queue), enabled = hasId) {+ playerViewModel.addToQueue(song)+ com.music.spotui.di.Haptics.confirm()+ toast(context.getString(R.string.snackbar_added_to_queue))+ onDismiss()+ }+ } else if (onOpenQueue != null) {+ MenuRow(Icons.AutoMirrored.Filled.QueueMusic, stringResource(R.string.context_menu_go_to_queue)) {+ onDismiss()+ onOpenQueue()+ }+ }+ val offline = com.music.spotui.data.offline.OfflineStore.statusOf(song.spotifyTrackId)+ when (offline) {+ com.music.spotui.data.offline.OfflineStatus.Done -> MenuRow(+ null, stringResource(R.string.context_menu_undownload),+ leading = { DownloadBadge(offline, size = 22.dp) },+ ) {+ toast(context.getString(if (com.music.spotui.data.offline.OfflineCollections.removeSong(song.spotifyTrackId)) R.string.toast_undownload else R.string.download_kept_by_list))+ onDismiss()+ }+ com.music.spotui.data.offline.OfflineStatus.Queued, is com.music.spotui.data.offline.OfflineStatus.Downloading -> MenuRow(+ null, stringResource(R.string.download_cancel),+ leading = { DownloadBadge(offline, size = 22.dp) },+ ) {+ com.music.spotui.data.offline.OfflineDownloader.cancel(song.spotifyTrackId)+ onDismiss()+ }+ else -> MenuRow(Icons.Outlined.ArrowCircleDown, stringResource(R.string.context_menu_download), enabled = hasId) {+ com.music.spotui.data.offline.OfflineCollections.downloadSong(song)+ com.music.spotui.di.Haptics.confirm()+ toast(context.getString(R.string.download_notification_downloading))+ onDismiss()+ }+ }+ MenuRow(Icons.Outlined.Radio, stringResource(R.string.context_menu_go_to_song_radio), enabled = hasId) {+ onDismiss()+ playerViewModel.goToSongRadio(song.spotifyTrackId, song.title,+ navigate = { route -> navController.navigate(route) },+ onFailed = { toast(context.getString(R.string.song_radio_failed)) })+ }+ MenuRow(Icons.Default.Album, stringResource(R.string.context_menu_browse_album), enabled = song.album.isNotBlank() || song.albumId.isNotBlank()) {+ onDismiss()+ navController.navigate(albumRoute(song.album, song.singer, song.albumId))+ }+ MenuRow(Icons.Outlined.Person, stringResource(R.string.context_menu_browse_artist), enabled = song.singer.isNotBlank()) {+ onDismiss()+ playerViewModel.goToArtist(song.spotifyTrackId, song.singer) { route -> navController.navigate(route) }+ }+ MenuRow(Icons.Outlined.Info, stringResource(R.string.track_credits), enabled = hasId) { showCredits = true }+ // Taste profile: the server says whether the track is excluded (the page's own cache can lag).+ val trackUri = "spotify:track:${song.spotifyTrackId}"+ val excluded by androidx.compose.runtime.produceState<Boolean?>(null, trackUri) {+ value = if (!hasId) null else runCatching { app.myspoti.host.android.MyspotiRuntime.api.extras.isExcludedFromTaste(listOf(trackUri)).single() }.getOrNull()+ }+ MenuRow(Icons.Outlined.Block, stringResource(if (excluded == true) R.string.include_taste else R.string.exclude_taste), enabled = hasId && excluded != null) {+ val exclude = excluded != true+ app.myspoti.host.android.MyspotiRuntime.scope.launch {+ runCatching { app.myspoti.host.android.MyspotiRuntime.api.extras.setExcludedFromTaste(trackUri, exclude) }+ }+ com.music.spotui.di.Haptics.confirm()+ onDismiss()+ }+ if (nowPlaying && song.url.startsWith("episode:")) {+ MenuRow(Icons.Outlined.Speed, stringResource(R.string.playback_speed)) { showSpeed = true }+ }+ MenuRow(Icons.Outlined.Share, stringResource(R.string.context_menu_share), enabled = hasId) {+ val send = Intent(Intent.ACTION_SEND)+ .setType("text/plain")+ .putExtra(Intent.EXTRA_TEXT, "https://open.spotify.com/track/${song.spotifyTrackId}")+ context.startActivity(Intent.createChooser(send, context.getString(R.string.action_share_label)).addFlags(Intent.FLAG_ACTIVITY_NEW_TASK))+ onDismiss()+ }+ if (nowPlaying) {+ val active = SongPlayer.sleepEndsAt.value != null+ MenuRow(+ Icons.Default.Bedtime,+ stringResource(R.string.context_menu_sleep_timer),+ tint = if (active) MenuGreen else MenuIconColor,+ ) { showSleep = true }+ }+ Spacer(Modifier.height(12.dp))+ }+ }+}++@Composable+private fun LikedBadge() {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.size(24.dp).clip(CircleShape).background(MenuGreen),+ ) {+ Icon(Icons.Default.Check, contentDescription = null, tint = Color.Black, modifier = Modifier.size(16.dp))+ }+}++@Composable+private fun MenuRow(+ icon: ImageVector?,+ label: String,+ enabled: Boolean = true,+ tint: Color = MenuIconColor,+ leading: (@Composable () -> Unit)? = null,+ onClick: () -> Unit,+) {+ val alpha = if (enabled) 1f else 0.4f+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .height(56.dp)+ .then(if (enabled) Modifier.clickable { onClick() } else Modifier)+ .padding(horizontal = 16.dp),+ ) {+ Box(Modifier.size(24.dp), contentAlignment = Alignment.Center) {+ when {+ leading != null -> leading()+ icon != null -> Icon(icon, contentDescription = null, tint = tint.copy(alpha = alpha), modifier = Modifier.size(24.dp))+ }+ }+ Spacer(modifier = Modifier.width(16.dp))+ Text(label, color = Color.White.copy(alpha = alpha), fontSize = 16.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+}+++/** The track's credits (performers, writers, producers), as Spotify lists them. */+@OptIn(androidx.compose.material3.ExperimentalMaterial3Api::class)+@Composable+private fun CreditsSheet(song: SongsModel, onDismiss: () -> Unit) {+ val credits by androidx.compose.runtime.produceState<app.myspoti.api.Credits?>(null, song.spotifyTrackId) {+ value = runCatching { app.myspoti.host.android.MyspotiRuntime.api.extras.credits("spotify:track:${song.spotifyTrackId}") }+ .getOrDefault(app.myspoti.api.Credits(emptyList()))+ }+ ModalBottomSheet(onDismissRequest = onDismiss, containerColor = Color(0xFF282828), sheetState = rememberModalBottomSheetState(skipPartiallyExpanded = true)) {+ Column(Modifier.fillMaxWidth().padding(bottom = 24.dp)) {+ Text(stringResource(R.string.track_credits), color = Color.White, fontSize = 20.sp, fontWeight = androidx.compose.ui.text.font.FontWeight.Bold,+ modifier = Modifier.padding(20.dp, 8.dp))+ Text(song.title, color = Color(0xFFB3B3B3), fontSize = 14.sp, modifier = Modifier.padding(horizontal = 20.dp))+ val roles = credits?.roles+ if (roles == null) androidx.compose.material3.LinearProgressIndicator(Modifier.fillMaxWidth().padding(20.dp))+ else roles.forEach { role ->+ Column(Modifier.padding(20.dp, 10.dp)) {+ Text(role.artists.joinToString(", ") { it.name }, color = Color.White, fontSize = 16.sp)+ Text(role.role, color = Color(0xFFB3B3B3), fontSize = 13.sp)+ }+ }+ }+ }+}++/** Podcast playback speed (Spotify refuses speed changes on music). */+@OptIn(androidx.compose.material3.ExperimentalMaterial3Api::class)+@Composable+private fun SpeedSheet(onDismiss: () -> Unit) {+ ModalBottomSheet(onDismissRequest = onDismiss, containerColor = Color(0xFF282828)) {+ Column(Modifier.fillMaxWidth().padding(bottom = 24.dp)) {+ Text(stringResource(R.string.playback_speed), color = Color.White, fontSize = 20.sp, fontWeight = androidx.compose.ui.text.font.FontWeight.Bold,+ modifier = Modifier.padding(20.dp, 8.dp))+ listOf(0.5, 0.8, 1.0, 1.2, 1.5, 1.8, 2.0, 3.0).forEach { speed ->+ Text("${speed}×", color = Color.White, fontSize = 16.sp,+ modifier = Modifier.fillMaxWidth().clickable { SongPlayer.setSpeed(speed); onDismiss() }.padding(20.dp, 12.dp))+ }+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/SupporterSheet.kt b/base/app/src/main/java/com/music/spotui/ui/components/SupporterSheet.ktnew file mode 100644index 00000000..0ea860cf--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/SupporterSheet.kt@@ -0,0 +1,160 @@+package com.music.spotui.ui.components++import androidx.compose.foundation.Image+import androidx.compose.foundation.background+import androidx.compose.foundation.border+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.navigationBarsPadding+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.rememberScrollState+import androidx.compose.foundation.selection.toggleable+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.foundation.verticalScroll+import androidx.compose.material3.ExperimentalMaterial3Api+import androidx.compose.material3.ModalBottomSheet+import androidx.compose.material3.Switch+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.res.stringResource+import androidx.compose.ui.semantics.Role+import androidx.compose.ui.semantics.contentDescription+import androidx.compose.ui.semantics.semantics+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import app.myspoti.engine.R+import com.music.spotui.data.api.SupportReminder+import com.music.spotui.data.api.SupportReminder.Accent+import com.music.spotui.data.api.SupportReminder.Level+import com.music.spotui.ui.theme.AppAccent++/** The small "Supporter" pill shown next to the profile name. */+@Composable+fun SupporterBadge(modifier: Modifier = Modifier) {+ Text(+ stringResource(R.string.supporter_badge), color = Color.Black, fontSize = 11.sp, fontWeight = FontWeight.Bold,+ modifier = modifier.clip(RoundedCornerShape(50)).background(AppAccent).padding(horizontal = 8.dp, vertical = 2.dp),+ )+}++private fun accentName(a: Accent) = when (a) {+ Accent.GREEN -> R.string.color_green+ Accent.BLUE -> R.string.color_blue+ Accent.PURPLE -> R.string.color_purple+ Accent.PINK -> R.string.color_pink+ Accent.ORANGE -> R.string.color_orange+}++private fun iconMark(a: Accent) = when (a) {+ Accent.GREEN -> R.drawable.ic_launcher_foreground+ Accent.BLUE -> R.drawable.ic_launcher_foreground_blue+ Accent.PURPLE -> R.drawable.ic_launcher_foreground_purple+ Accent.PINK -> R.drawable.ic_launcher_foreground_pink+ Accent.ORANGE -> R.drawable.ic_launcher_foreground_orange+}++/** "I've supported": on trust, a donation or a monthly support. */+@Composable+fun SupportChoice(onChosen: (Level) -> Unit) {+ Text(stringResource(R.string.supporter_how), color = Color.White, fontSize = 15.sp, fontWeight = FontWeight.Bold)+ Row(horizontalArrangement = Arrangement.spacedBy(10.dp), modifier = Modifier.padding(top = 10.dp)) {+ for ((level, label) in listOf(Level.ONCE to R.string.supporter_once, Level.MONTHLY to R.string.supporter_monthly)) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.height(40.dp).clip(RoundedCornerShape(50)).background(Color(0xFF3A3A3A))+ .pressable(0.96f) { onChosen(level) }.padding(horizontal = 18.dp),+ ) { Text(stringResource(label), color = Color.White, fontSize = 14.sp, fontWeight = FontWeight.SemiBold) }+ }+ }+}++/** Supporter perks: thank-yous only (colour, icon, badge); nothing in the app is locked. */+@OptIn(ExperimentalMaterial3Api::class)+@Composable+fun SupporterSheet(onDismiss: () -> Unit) {+ val context = LocalContext.current+ var choosing by remember { mutableStateOf(false) }+ val level = SupportReminder.level+ ModalBottomSheet(onDismissRequest = onDismiss, containerColor = Color(0xFF282828)) {+ Column(Modifier.navigationBarsPadding().verticalScroll(rememberScrollState()).padding(start = 20.dp, end = 20.dp, bottom = 20.dp)) {+ Row(verticalAlignment = Alignment.CenterVertically) {+ Text(stringResource(R.string.supporter_perks_title), color = Color.White, fontSize = 20.sp, fontWeight = FontWeight.Bold)+ if (level != Level.NONE) { Spacer(Modifier.width(10.dp)); SupporterBadge() }+ }+ if (level == Level.NONE) {+ Text(stringResource(R.string.supporter_perks_locked), color = Color(0xFFB3B3B3), fontSize = 14.sp,+ modifier = Modifier.padding(top = 8.dp, bottom = 16.dp))+ if (choosing) SupportChoice { SupportReminder.setLevel(context, it); choosing = false }+ else {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.fillMaxWidth().height(48.dp).clip(RoundedCornerShape(50)).background(AppAccent)+ .pressable(0.96f) { SupportReminder.open(context) },+ ) { Text(stringResource(R.string.support_action), color = Color.Black, fontSize = 16.sp, fontWeight = FontWeight.Bold) }+ Text(stringResource(R.string.supporter_i_supported), color = Color.White, fontSize = 15.sp, fontWeight = FontWeight.Bold,+ modifier = Modifier.align(Alignment.CenterHorizontally).padding(top = 8.dp)+ .pressable(0.96f) { choosing = true }.padding(horizontal = 24.dp, vertical = 12.dp))+ }+ return@Column+ }+ Text(stringResource(R.string.supporter_thanks_title), color = Color(0xFFB3B3B3), fontSize = 14.sp, modifier = Modifier.padding(top = 6.dp))++ Text(stringResource(R.string.supporter_accent), color = Color.White, fontSize = 16.sp, modifier = Modifier.padding(top = 20.dp, bottom = 10.dp))+ Row(horizontalArrangement = Arrangement.spacedBy(14.dp)) {+ for (a in Accent.entries) {+ val selected = SupportReminder.accent == a+ val name = stringResource(accentName(a))+ Box(+ Modifier.size(40.dp).semantics { contentDescription = name }.clip(CircleShape).background(a.color)+ .then(if (selected) Modifier.border(3.dp, Color.White, CircleShape) else Modifier)+ .pressable(0.92f) { SupportReminder.setAccent(context, a) },+ )+ }+ }++ Text(stringResource(R.string.supporter_icon), color = Color.White, fontSize = 16.sp, modifier = Modifier.padding(top = 22.dp, bottom = 10.dp))+ Row(horizontalArrangement = Arrangement.spacedBy(12.dp)) {+ for (a in Accent.entries) {+ val selected = SupportReminder.icon == a+ val name = stringResource(accentName(a))+ Image(+ painterResource(iconMark(a)), contentDescription = name,+ modifier = Modifier.size(52.dp).clip(RoundedCornerShape(14.dp)).background(Color(0xFF121212))+ .then(if (selected) Modifier.border(3.dp, Color.White, RoundedCornerShape(14.dp)) else Modifier)+ .pressable(0.92f) { SupportReminder.setIcon(context, a) },+ )+ }+ }+ Text(stringResource(R.string.supporter_icon_note), color = Color(0xFFB3B3B3), fontSize = 12.sp, modifier = Modifier.padding(top = 8.dp))++ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().padding(top = 18.dp).toggleable(level == Level.MONTHLY, role = Role.Switch) { on ->+ SupportReminder.setLevel(context, if (on) Level.MONTHLY else Level.ONCE)+ },+ ) {+ Text(stringResource(R.string.supporter_monthly_switch), color = Color.White, fontSize = 15.sp, modifier = Modifier.weight(1f))+ Switch(checked = level == Level.MONTHLY, onCheckedChange = null)+ }+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/SwipeToQueue.kt b/base/app/src/main/java/com/music/spotui/ui/components/SwipeToQueue.ktnew file mode 100644index 00000000..33e343e5--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/SwipeToQueue.kt@@ -0,0 +1,100 @@+package com.music.spotui.ui.components++import app.myspoti.engine.R++import androidx.compose.ui.res.stringResource++import androidx.compose.animation.core.Animatable+import androidx.compose.animation.core.spring+import androidx.compose.foundation.background+import androidx.compose.foundation.gestures.detectHorizontalDragGestures+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.offset+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.automirrored.filled.PlaylistAdd+import androidx.compose.material3.Icon+import androidx.compose.runtime.Composable+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.rememberCoroutineScope+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.hapticfeedback.HapticFeedbackType+import androidx.compose.ui.input.pointer.pointerInput+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.platform.LocalDensity+import androidx.compose.ui.platform.LocalHapticFeedback+import androidx.compose.ui.unit.IntOffset+import androidx.compose.ui.unit.dp+import com.music.spotui.data.entity.SongsModel+import kotlinx.coroutines.launch+import kotlin.math.abs+import kotlin.math.roundToInt++/**+ * Spotify's gesture: swipe a song row sideways to add it to the queue. The row+ * follows the finger over a green strip, ticks once with a vibration when it+ * passes the threshold, adds the song ONCE on release, then springs back.+ */+@Composable+fun SwipeToQueue(song: SongsModel, content: @Composable () -> Unit) {+ val context = LocalContext.current+ val haptic = LocalHapticFeedback.current+ val scope = rememberCoroutineScope()+ val threshold = with(LocalDensity.current) { 96.dp.toPx() }+ val maxDrag = threshold * 1.4f+ val offset = remember { Animatable(0f) }+ var armed by remember { mutableStateOf(false) }++ Box(modifier = Modifier.fillMaxWidth()) {+ if (offset.value != 0f) {+ Box(+ contentAlignment = if (offset.value > 0) Alignment.CenterStart else Alignment.CenterEnd,+ modifier = Modifier+ .matchParentSize()+ .background(if (armed) com.music.spotui.ui.theme.AppAccent else com.music.spotui.ui.theme.AppAccent.copy(alpha = 0.6f)),+ ) {+ Icon(+ Icons.AutoMirrored.Filled.PlaylistAdd,+ contentDescription = stringResource(R.string.add_to_queue_action_content_description),+ tint = Color.Black,+ modifier = Modifier.padding(horizontal = 24.dp).size(26.dp),+ )+ }+ }+ Box(+ modifier = Modifier+ .offset { IntOffset(offset.value.roundToInt(), 0) }+ .background(Color(0xFF121212))+ .pointerInput(song.id) {+ detectHorizontalDragGestures(+ onDragEnd = {+ if (armed && song.spotifyTrackId.isNotBlank()) {+ com.music.spotui.di.SongPlayer.addToQueue(song.spotifyTrackId)+ android.widget.Toast.makeText(context, context.getString(R.string.snackbar_added_to_queue), android.widget.Toast.LENGTH_SHORT).show()+ }+ armed = false+ scope.launch { offset.animateTo(0f, spring()) }+ },+ onDragCancel = {+ armed = false+ scope.launch { offset.animateTo(0f, spring()) }+ },+ ) { change, dx ->+ change.consume()+ val next = (offset.value + dx).coerceIn(-maxDrag, maxDrag)+ scope.launch { offset.snapTo(next) }+ val nowArmed = abs(next) >= threshold+ if (nowArmed && !armed) haptic.performHapticFeedback(HapticFeedbackType.GestureThresholdActivate)+ armed = nowArmed+ }+ },+ ) { content() }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/components/SwipeToRemove.kt b/base/app/src/main/java/com/music/spotui/ui/components/SwipeToRemove.ktnew file mode 100644index 00000000..e7bd4020--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/components/SwipeToRemove.kt@@ -0,0 +1,91 @@+package com.music.spotui.ui.components++import androidx.compose.animation.core.Animatable+import androidx.compose.animation.core.spring+import androidx.compose.animation.core.tween+import androidx.compose.foundation.background+import androidx.compose.foundation.gestures.detectHorizontalDragGestures+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.offset+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.outlined.DeleteOutline+import androidx.compose.material3.Icon+import androidx.compose.runtime.Composable+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableFloatStateOf+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.rememberCoroutineScope+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.hapticfeedback.HapticFeedbackType+import androidx.compose.ui.input.pointer.pointerInput+import androidx.compose.ui.layout.onSizeChanged+import androidx.compose.ui.platform.LocalDensity+import androidx.compose.ui.platform.LocalHapticFeedback+import androidx.compose.ui.res.stringResource+import androidx.compose.ui.unit.IntOffset+import androidx.compose.ui.unit.dp+import app.myspoti.engine.R+import kotlinx.coroutines.launch+import kotlin.math.roundToInt++/**+ * Swipe a row from right to left to remove it: the row follows the finger over a red+ * strip with a bin, ticks past the threshold, and slides out before [onRemove].+ */+@Composable+fun SwipeToRemove(key: Any, onRemove: () -> Unit, content: @Composable () -> Unit) {+ val haptic = LocalHapticFeedback.current+ val scope = rememberCoroutineScope()+ val threshold = with(LocalDensity.current) { 120.dp.toPx() }+ val offset = remember(key) { Animatable(0f) }+ var armed by remember(key) { mutableStateOf(false) }+ var width by remember { mutableFloatStateOf(0f) }++ Box(modifier = Modifier.fillMaxWidth().onSizeChanged { width = it.width.toFloat() }) {+ if (offset.value < 0f) {+ Box(+ contentAlignment = Alignment.CenterEnd,+ modifier = Modifier.matchParentSize()+ .background(if (armed) Color(0xFFE22134) else Color(0xFFE22134).copy(alpha = 0.6f)),+ ) {+ Icon(Icons.Outlined.DeleteOutline, stringResource(R.string.context_menu_undownload), tint = Color.White,+ modifier = Modifier.padding(horizontal = 24.dp).size(26.dp))+ }+ }+ Box(+ modifier = Modifier+ .offset { IntOffset(offset.value.roundToInt(), 0) }+ .background(com.music.spotui.ui.theme.AppBackground)+ .pointerInput(key) {+ detectHorizontalDragGestures(+ onDragEnd = {+ if (armed) scope.launch {+ offset.animateTo(-width.coerceAtLeast(threshold), tween(180))+ onRemove()+ } else scope.launch { offset.animateTo(0f, spring()) }+ armed = false+ },+ onDragCancel = {+ armed = false+ scope.launch { offset.animateTo(0f, spring()) }+ },+ ) { change, dx ->+ change.consume()+ // Leftwards only (right to left).+ val next = (offset.value + dx).coerceIn(-(width.coerceAtLeast(threshold)), 0f)+ scope.launch { offset.snapTo(next) }+ val nowArmed = -next >= threshold+ if (nowArmed && !armed) haptic.performHapticFeedback(HapticFeedbackType.GestureThresholdActivate)+ armed = nowArmed+ }+ },+ ) { content() }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/navigation/MainBottomNavigation.kt b/base/app/src/main/java/com/music/spotui/ui/navigation/MainBottomNavigation.ktnew file mode 100644index 00000000..f15c95ca--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/navigation/MainBottomNavigation.kt@@ -0,0 +1,179 @@+package com.music.spotui.ui.navigation++import androidx.navigation.NavGraph.Companion.findStartDestination+import androidx.compose.ui.res.stringResource+import app.myspoti.engine.R++import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.height++import androidx.compose.animation.AnimatedVisibility+import androidx.compose.animation.slideInVertically+import androidx.compose.animation.slideOutVertically+import androidx.compose.foundation.background+import androidx.compose.foundation.interaction.Interaction+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.offset+import androidx.compose.foundation.layout.padding+import androidx.compose.material3.Icon+import androidx.compose.material3.NavigationBar+import androidx.compose.material3.NavigationBarItem+import androidx.compose.material3.NavigationBarItemDefaults+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.runtime.MutableState+import androidx.compose.runtime.getValue+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.graphics.Brush+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.navigation.NavHostController+import androidx.navigation.compose.currentBackStackEntryAsState+import com.music.spotui.ui.components.MiniPlayer+import kotlinx.coroutines.flow.Flow+import kotlinx.coroutines.flow.emptyFlow++import androidx.compose.foundation.layout.navigationBarsPadding++class NoRippleInteractionSource : MutableInteractionSource {++ override val interactions: Flow<Interaction> = emptyFlow()++ override suspend fun emit(interaction: Interaction) {}++ override fun tryEmit(interaction: Interaction) = true+}++@Composable+fun MainBottomNavigation(navController: NavHostController, bottomBarState: MutableState<Boolean>, bottomBarPlayerState : MutableState<Boolean>) {++ val navItems = listOf(+ Routes.Home,+ Routes.Search,+ Routes.Library+ )+ // Visibility follows the screen actually shown (not flags each screen sets,+ // which raced during transitions and left the mini player over the full one).+ val shownRoute = navController.currentBackStackEntryAsState().value?.destination?.route+ val fullScreen = shownRoute == Routes.Player.route || shownRoute == Routes.Queue.route+ val hasTrack = com.music.spotui.di.Graph.currentSongState.title.value.isNotBlank()+ // No motion of its own: the bar sits above the pages, so sliding it while the+ // player rises (or collapses behind it) made one gesture look like two.+ AnimatedVisibility(+ visible = !fullScreen,+ enter = androidx.compose.animation.EnterTransition.None,+ exit = androidx.compose.animation.ExitTransition.None,+ content = {+ Box(+ contentAlignment = Alignment.BottomCenter,+ modifier = Modifier+ .fillMaxWidth()+ .background(+ Brush.verticalGradient(+ colors = listOf(+ Color.Transparent,+ Color.Black+ ),+ startY = 0f+ )+ )+ ) {++ Column(modifier = Modifier.navigationBarsPadding()) {++ AnimatedVisibility(+ visible = hasTrack,+ enter = slideInVertically(initialOffsetY = { it }),+ exit = slideOutVertically(targetOffsetY = { it }),+ content = {+ MiniPlayer(navController)+ }+ )++++ Spacer(modifier = Modifier.height(4.dp))+ NavigationBar(+ modifier = Modifier+ .height(60.dp)+ .padding(30.dp, 0.dp)+ .fillMaxWidth(),+ containerColor = Color.Transparent,+ windowInsets = androidx.compose.foundation.layout.WindowInsets(0, 0, 0, 0)+ ) {+ val navStack by navController.currentBackStackEntryAsState()+ val currentRoute = navStack?.destination?.route+ // The tab the user is in, even on one of its sub-pages (album, artist…).+ var selectedTab by androidx.compose.runtime.saveable.rememberSaveable { androidx.compose.runtime.mutableStateOf(Routes.Home.route) }+ if (currentRoute in navItems.map { it.route }) selectedTab = currentRoute!!++ navItems.forEach { item ->+ NavigationBarItem(+ selected = selectedTab == item.route,+ icon = {+ Icon(+ painter = painterResource(+ id = item.icon+ ), contentDescription = "home"+ )+ },+ label = {+ if (currentRoute == item.route) {+ Text(color = Color.White, text = if (item.labelRes != 0) stringResource(item.labelRes) else item.label, fontSize = 11.sp)+ } else {+ Text(+ color = Color.Gray,+ text = if (item.labelRes != 0) stringResource(item.labelRes) else item.label,+ fontSize = 11.sp+ )+ }+ },+ onClick = {+ // Standard bottom-tab navigation: each tab keeps its+ // state (no reload, scroll kept) when you come back.+ if (item.route == selectedTab) {+ // Same tab again: back to its root page (Spotify behaviour).+ if (currentRoute != item.route && !navController.popBackStack(item.route, inclusive = false)) {+ navController.navigate(item.route) { launchSingleTop = true }+ }+ } else {+ selectedTab = item.route+ navController.navigate(item.route) {+ popUpTo(navController.graph.findStartDestination().id) { saveState = true }+ launchSingleTop = true+ // Home always opens Home itself (its scroll kept), not the+ // page last left open from it (a playlist, an artist…).+ restoreState = item.route != Routes.Home.route+ }+ }+ },+ alwaysShowLabel = true,+ interactionSource = NoRippleInteractionSource(),+ colors = NavigationBarItemDefaults.colors(+ selectedIconColor = Color.White,+ unselectedIconColor = Color.Gray,+ indicatorColor = Color.Transparent+ )+ )++ }+ }++++ }++++ }+ }+ )+}diff --git a/base/app/src/main/java/com/music/spotui/ui/navigation/MyNavHost.kt b/base/app/src/main/java/com/music/spotui/ui/navigation/MyNavHost.ktnew file mode 100644index 00000000..19f47072--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/navigation/MyNavHost.kt@@ -0,0 +1,341 @@+package com.music.spotui.ui.navigation++import android.os.Build+import android.util.Log+import androidx.annotation.RequiresApi+import androidx.compose.animation.AnimatedContentScope+import androidx.compose.animation.EnterTransition+import androidx.compose.animation.ExitTransition+import androidx.compose.animation.core.CubicBezierEasing+import androidx.compose.animation.core.tween+import androidx.compose.animation.fadeIn+import androidx.compose.animation.fadeOut+import androidx.compose.animation.slideInHorizontally+import androidx.compose.animation.slideInVertically+import androidx.compose.animation.slideOutHorizontally+import androidx.compose.animation.slideOutVertically+import androidx.compose.foundation.background+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.ui.Modifier+import androidx.navigation.NamedNavArgument+import androidx.navigation.NavBackStackEntry+import androidx.navigation.NavGraphBuilder+import com.music.spotui.ui.theme.AppBackground+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.MutableState+import androidx.compose.runtime.getValue+import androidx.compose.ui.platform.LocalContext+import androidx.lifecycle.viewmodel.compose.viewModel+import androidx.navigation.NavHostController+import androidx.navigation.compose.NavHost+import androidx.navigation.compose.composable+import androidx.navigation.navArgument+import com.music.spotui.ui.screens.AlbumByIdScreen+import com.music.spotui.ui.screens.ContextScreen+import com.music.spotui.ui.screens.ArtistReleasesScreen+import com.music.spotui.ui.screens.ArtistScreen+import com.music.spotui.ui.screens.CategoryScreen+import com.music.spotui.ui.screens.HomeScreen+import com.music.spotui.ui.screens.LibraryScreen+import com.music.spotui.ui.screens.PlayerScreen+import com.music.spotui.ui.screens.ShowScreen+import com.music.spotui.ui.screens.QueueScreen+import com.music.spotui.ui.screens.SearchScreen+import com.music.spotui.ui.viewmodel.PlayerViewModel++@Composable+fun MyNavHost(+ navHostController: NavHostController,+ bottomBarState: MutableState<Boolean>,+ bottomBarPlayerState: MutableState<Boolean>+) {++ val playerViewModel : PlayerViewModel = viewModel()+ val playerState by playerViewModel.currentSongTitle++ Log.d("player", playerState.toString())++// val context = LocalContext.current+// var player : ExoPlayer? = null+// player = ExoPlayer.Builder(context).build()++ val context = LocalContext.current+ val startDestination = Routes.Home.route++ NavHost(+ navController = navHostController,+ startDestination = startDestination,+ // Same motion as the official app: tabs switch instantly, pages slide in from+ // the right over a slight parallax, the player and queue rise from the bottom.+ // Slides only (no alpha): a fade puts the whole page in an offscreen layer.+ enterTransition = { navEnter(initialState, targetState) },+ exitTransition = { navExit(initialState, targetState) },+ popEnterTransition = { navPopEnter(initialState, targetState) },+ popExitTransition = { navPopExit(initialState, targetState) },+ ){+ page(Routes.Home.route){+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ HomeScreen(navHostController)+ }+ page(Routes.Search.route){+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ SearchScreen(navHostController)+ }+ page(Routes.Library.route) {+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ LibraryScreen(navHostController)+ }+ // Older links to the player route open the player sheet over the page instead.+ page(Routes.Player.route){+ LaunchedEffect(Unit) {+ navHostController.popBackStack()+ PlayerSheet.show()+ }+ }++ page(Routes.Queue.route){+ LaunchedEffect(playerState) {+ bottomBarState.value = false+ bottomBarPlayerState.value = false+ }+ QueueScreen(navHostController)+ }++ page(Routes.LocalFiles.route){+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ com.music.spotui.ui.screens.LocalFilesScreen(navHostController)+ }++ page(Routes.Downloads.route){+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ com.music.spotui.ui.screens.DownloadsScreen(navHostController)+ }++ page(Routes.NewReleases.route) {+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ com.music.spotui.ui.screens.NewReleasesScreen(navHostController)+ }++ page(Routes.Episodes.route) {+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ com.music.spotui.ui.screens.EpisodesScreen(navHostController)+ }++ page(Routes.Recap.route) {+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ com.music.spotui.ui.screens.RecapScreen(navHostController)+ }++ page(Routes.Liked.route){+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ ContextScreen(navHostController, type = "liked", id = "")+ }++++++ page(+ "${Routes.Category.route}/{genre}?title={title}",+ arguments = listOf(navArgument("title") { defaultValue = "" }),+ ) { navBackStackEntry ->+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ val genre = navBackStackEntry.arguments?.getString("genre").orEmpty()+ val title = navBackStackEntry.arguments?.getString("title").orEmpty()+ CategoryScreen(navHostController, genre = genre, title = title.ifBlank { genre })+ }++ page(+ "${Routes.Album.route}/{uString}?artist={artist}&id={albumId}",+ arguments = listOf(+ navArgument("artist") { defaultValue = "" },+ navArgument("albumId") { defaultValue = "" },+ ),+ ) { navBackStackEntry ->+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }++ /* Extracting the id from the route */+ val uId = navBackStackEntry.arguments?.getString("uString")+ val artist = navBackStackEntry.arguments?.getString("artist").orEmpty()+ /* We check if it's not null */+ val albumId = navBackStackEntry.arguments?.getString("albumId").orEmpty()+ uId?.let { name ->+ AlbumByIdScreen(navHostController, name = name, artist = artist, id = albumId)+ }+ }++ page(+ "${Routes.Playlist.route}/{pId}?name={name}",+ arguments = listOf(navArgument("name") { defaultValue = "" }),+ ) { navBackStackEntry ->+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ val pId = navBackStackEntry.arguments?.getString("pId")+ val name = navBackStackEntry.arguments?.getString("name").orEmpty()+ pId?.let { ContextScreen(navHostController, type = "playlist", id = it) }+ }++ page(+ "${Routes.Show.route}/{sId}?name={name}",+ arguments = listOf(navArgument("name") { defaultValue = "" }),+ ) { navBackStackEntry ->+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ val sId = navBackStackEntry.arguments?.getString("sId")+ val name = navBackStackEntry.arguments?.getString("name").orEmpty()+ sId?.let { ShowScreen(navHostController, showId = it, showName = name) }+ }++ page(+ "${Routes.Folder.route}/{uri}?name={name}",+ arguments = listOf(navArgument("name") { defaultValue = "" }),+ ) { navBackStackEntry ->+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ val uri = navBackStackEntry.arguments?.getString("uri")+ val name = navBackStackEntry.arguments?.getString("name").orEmpty()+ uri?.let { com.music.spotui.ui.screens.FolderScreen(navHostController, it, name) }+ }++ page("${Routes.LocalPlaylist.route}/{id}") { navBackStackEntry ->+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ navBackStackEntry.arguments?.getString("id")?.let { com.music.spotui.ui.screens.LocalPlaylistScreen(navHostController, it) }+ }++ page("${Routes.ArtistReleases.route}/{aString}") { navBackStackEntry ->+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }+ val aId = navBackStackEntry.arguments?.getString("aString")+ aId?.let { ArtistReleasesScreen(navHostController, it) }+ }++ page(+ "${Routes.Artist.route}/{aString}?id={artistId}",+ arguments = listOf(navArgument("artistId") { defaultValue = "" }),+ ) { navBackStackEntry ->+ LaunchedEffect(playerState) {+ bottomBarState.value = true+ bottomBarPlayerState.value = playerState != ""+ }++ /* Extracting the id from the route */+ val aId = navBackStackEntry.arguments?.getString("aString")+ val artistId = navBackStackEntry.arguments?.getString("artistId").orEmpty()+ /* We check if it's not null */+ aId?.let { aid->+ ArtistScreen(navHostController, aid, artistId)+ }+ }+ }+}++private val tabRoutes = setOf(Routes.Home.route, Routes.Search.route, Routes.Library.route)+// Full-height sheets over the current page (the official player / queue).+private val sheetRoutes = setOf(Routes.Player.route, Routes.Queue.route)++private fun isTabSwitch(from: NavBackStackEntry, to: NavBackStackEntry) =+ from.destination.route in tabRoutes && to.destination.route in tabRoutes+private fun NavBackStackEntry.isSheet() = destination.route in sheetRoutes++// Material 3 emphasized curves: quick start, long soft landing (and the reverse to leave).+internal val Decelerate = CubicBezierEasing(0.05f, 0.7f, 0.1f, 1f)+internal val Accelerate = CubicBezierEasing(0.3f, 0f, 0.8f, 0.15f)+private const val PAGE_MS = 300+internal const val SHEET_IN_MS = 340+internal const val SHEET_OUT_MS = 240++private fun navEnter(from: NavBackStackEntry, to: NavBackStackEntry): EnterTransition = when {+ isTabSwitch(from, to) -> EnterTransition.None+ to.isSheet() -> slideInVertically(tween(SHEET_IN_MS, easing = Decelerate)) { it }+ else -> slideInHorizontally(tween(PAGE_MS, easing = Decelerate)) { it }+}++private fun navExit(from: NavBackStackEntry, to: NavBackStackEntry): ExitTransition = when {+ isTabSwitch(from, to) -> ExitTransition.None+ // The page stays still under the rising sheet until it covers it.+ to.isSheet() -> fadeOut(tween(durationMillis = 1, delayMillis = SHEET_IN_MS))+ else -> slideOutHorizontally(tween(PAGE_MS, easing = Decelerate)) { -it / 4 }+}++private fun navPopEnter(from: NavBackStackEntry, to: NavBackStackEntry): EnterTransition = when {+ isTabSwitch(from, to) -> EnterTransition.None+ from.isSheet() -> EnterTransition.None+ else -> slideInHorizontally(tween(PAGE_MS, easing = Decelerate)) { -it / 4 }+}++private fun navPopExit(from: NavBackStackEntry, to: NavBackStackEntry): ExitTransition = when {+ isTabSwitch(from, to) -> ExitTransition.None+ from.isSheet() -> slideOutVertically(tween(SHEET_OUT_MS, easing = Accelerate)) { it }+ else -> slideOutHorizontally(tween(PAGE_MS, easing = Decelerate)) { it }+}++/** A destination on an opaque background, so sliding pages never show through each other. */+private fun NavGraphBuilder.page(+ route: String,+ arguments: List<NamedNavArgument> = emptyList(),+ content: @Composable AnimatedContentScope.(NavBackStackEntry) -> Unit,+) = composable(route, arguments = arguments) { entry ->+ val scope = this+ val settled = androidx.compose.runtime.remember {+ androidx.compose.runtime.derivedStateOf {+ scope.transition.currentState == scope.transition.targetState+ }+ }+ androidx.compose.runtime.CompositionLocalProvider(LocalPageSettled provides settled) {+ Box(Modifier.fillMaxSize().background(AppBackground)) { scope.content(entry) }+ }+}++/**+ * false while this page is sliding in or out. Heavy views (video players, surfaces)+ * wait for it: built in the first frame, they stalled it and the motion jumped.+ */+val LocalPageSettled = androidx.compose.runtime.staticCompositionLocalOf<androidx.compose.runtime.State<Boolean>> {+ androidx.compose.runtime.mutableStateOf(true)+}diff --git a/base/app/src/main/java/com/music/spotui/ui/navigation/PlayerSheet.kt b/base/app/src/main/java/com/music/spotui/ui/navigation/PlayerSheet.ktnew file mode 100644index 00000000..e7577563--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/navigation/PlayerSheet.kt@@ -0,0 +1,47 @@+package com.music.spotui.ui.navigation++import androidx.activity.compose.BackHandler+import androidx.compose.animation.AnimatedVisibility+import androidx.compose.animation.core.tween+import androidx.compose.animation.slideInVertically+import androidx.compose.animation.slideOutVertically+import androidx.compose.runtime.Composable+import androidx.compose.runtime.CompositionLocalProvider+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.derivedStateOf+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.navigation.NavController+import com.music.spotui.ui.screens.PlayerScreen+import kotlinx.coroutines.flow.drop++/**+ * The full player, shown over the pages instead of being one of them, like the official+ * app: pulled down, it uncovers the page it was opened from, with the mini player and the+ * tabs already in place, and closing it leaves them there.+ */+object PlayerSheet {+ val open = mutableStateOf(false)++ fun show() { open.value = true }+ fun close() { open.value = false }+}++@Composable+fun PlayerOverlay(navController: NavController) {+ // Any navigation from the player (album, artist, playlist…) lands on that page.+ LaunchedEffect(navController) {+ navController.currentBackStackEntryFlow.drop(1).collect { PlayerSheet.close() }+ }+ AnimatedVisibility(+ visible = PlayerSheet.open.value,+ enter = slideInVertically(tween(SHEET_IN_MS, easing = Decelerate)) { it },+ exit = slideOutVertically(tween(SHEET_OUT_MS, easing = Accelerate)) { it },+ ) {+ BackHandler { PlayerSheet.close() }+ val settled = remember { derivedStateOf { transition.currentState == transition.targetState } }+ CompositionLocalProvider(LocalPageSettled provides settled) {+ PlayerScreen(navController)+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/navigation/Routes.kt b/base/app/src/main/java/com/music/spotui/ui/navigation/Routes.ktnew file mode 100644index 00000000..6c7f3a59--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/navigation/Routes.kt@@ -0,0 +1,70 @@+package com.music.spotui.ui.navigation++import androidx.annotation.DrawableRes+import app.myspoti.engine.R++sealed class Routes(+ @DrawableRes val icon : Int = 0,+ val label : String,+ val route : String,+ /** Official label (per system language) for the bottom navigation, 0 = none. */+ @androidx.annotation.StringRes val labelRes: Int = 0,+) {+ object Home : Routes(icon = R.drawable.ic_home_filled, label = "Accueil", route = "home", labelRes = R.string.navigationbar_musicappitems_home_title)+ object Search : Routes(icon = R.drawable.ic_search_big, label = "Rechercher", route = "search", labelRes = R.string.navigationbar_musicappitems_search_title)+ object Library : Routes(icon = R.drawable.ic_library_big, label = "Bibliothèque", route = "library", labelRes = R.string.navigationbar_musicappitems_yourlibrary_title)+ object Album : Routes(0, "Album", "album")+ object Player : Routes(0, "Player", "player")+ object Artist : Routes(0, "Artist", "artist")+ object ArtistReleases : Routes(0, "ArtistReleases", "artistreleases")+ object Playlist : Routes(0, "Playlist", "playlist")+ object Show : Routes(0, "Show", "show")+ object Queue : Routes(0, "Queue", "queue")+ object Liked : Routes(0, "Liked", "liked")+ object LocalFiles : Routes(0, "LocalFiles", "localfiles")+ object Downloads : Routes(0, "Downloads", "downloads")+ object Folder : Routes(0, "Folder", "folder")+ object LocalPlaylist : Routes(0, "LocalPlaylist", "localplaylist")+ object Category : Routes(0, "Category", "category")+ object NewReleases : Routes(0, "NewReleases", "newreleases")+ object Episodes : Routes(0, "Episodes", "episodes")+ object Recap : Routes(0, "Recap", "recap")+}++/** Builds a Browse-category route carrying the search genre and a display title. */+fun categoryRoute(genre: String, title: String): String =+ "${Routes.Category.route}/${android.net.Uri.encode(genre)}?title=${android.net.Uri.encode(title)}"++/** Builds a playlist route carrying the Spotify playlist id (and a display name). */+fun playlistRoute(id: String, name: String = ""): String =+ "${Routes.Playlist.route}/${android.net.Uri.encode(id)}?name=${android.net.Uri.encode(name)}"++/** A Spotify library folder, by its full uri (and name for the header). */+fun folderRoute(uri: String, name: String): String =+ "${Routes.Folder.route}/${android.net.Uri.encode(uri)}?name=${android.net.Uri.encode(name)}"++/** A playlist kept on this phone (LocalPlaylists id). */+fun localPlaylistRoute(id: String): String = "${Routes.LocalPlaylist.route}/${android.net.Uri.encode(id)}"++/** Builds a podcast-show route carrying the Spotify show id (and a display name). */+fun showRoute(id: String, name: String = ""): String =+ "${Routes.Show.route}/${android.net.Uri.encode(id)}?name=${android.net.Uri.encode(name)}"++/**+ * Builds an artist route. When the exact Spotify artist id is known it is+ * carried along so the artist page opens the exact artist instead of+ * re-resolving the name via a fuzzy search ("RAM" must not open "Rammstein").+ */+fun artistRoute(name: String, id: String = ""): String {+ val base = "${Routes.Artist.route}/${android.net.Uri.encode(name)}"+ return if (id.isBlank()) base+ else "$base?id=${android.net.Uri.encode(id)}"+}++/**+ * Builds an album route, optionally carrying the artist so same-named albums by+ * different artists resolve to the right one. The artist value is URL-encoded.+ */+fun albumRoute(name: String, artist: String = "", id: String = ""): String =+ "${Routes.Album.route}/${android.net.Uri.encode(name.ifBlank { "album" })}" ++ "?artist=${android.net.Uri.encode(artist)}&id=${android.net.Uri.encode(id)}"diff --git a/base/app/src/main/java/com/music/spotui/ui/repository/AppRepository.kt b/base/app/src/main/java/com/music/spotui/ui/repository/AppRepository.ktnew file mode 100644index 00000000..dd7c28d4--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/repository/AppRepository.kt@@ -0,0 +1,48 @@+package com.music.spotui.ui.repository++import com.music.spotui.di.Graph+import com.music.spotui.data.api.Api++class AppRepository constructor(private val api: Api = Graph.api) {++ suspend fun provideAlbums() = api.getAlbums()++ suspend fun provideHomeFeed(facet: String = "") = api.getHomeFeed(facet)++ suspend fun provideArtists() = api.getArtists()++ suspend fun provideSongs() = api.getSongs()++ suspend fun searchSongs(query: String) = api.searchTracks(query)++ suspend fun searchEverything(query: String) = api.searchEverything(query)++ suspend fun provideAlbumSongs(albumName: String, artist: String = "") = api.getAlbumSongs(albumName, artist)++ suspend fun provideArtistSongs(artistName: String) = api.getArtistSongs(artistName)++ suspend fun provideArtistOverview(artistName: String, artistId: String = "") = api.getArtistOverview(artistName, artistId)++ suspend fun providePlaylistSongs(playlistId: String) = api.getPlaylistSongs(playlistId)++ suspend fun providePlaylist(playlistId: String) = api.getPlaylist(playlistId)++ suspend fun provideShowEpisodes(showId: String) = api.getShowEpisodes(showId)++ suspend fun provideShow(showId: String) = api.getShow(showId)++ suspend fun provideLibrary() = api.getLibraryRoot()+ suspend fun provideLibraryFolder(uri: String) = api.getLibraryFolder(uri)++ suspend fun provideFollowedArtists() = api.getFollowedArtists()++ suspend fun provideCategoryPlaylists(genre: String) = api.getCategoryPlaylists(genre)++ suspend fun provideRecommendations(seedTrackIds: List<String>) = api.getRecommendations(seedTrackIds)++ suspend fun provideLikedSongs() = api.getLikedSongs()++ suspend fun provideAccount() = api.getAccount()++ suspend fun provideCanvasUrl(trackId: String) = api.getCanvasUrl(trackId)+}\ No newline at end of filediff --git a/base/app/src/main/java/com/music/spotui/ui/screens/AccountBrowser.kt b/base/app/src/main/java/com/music/spotui/ui/screens/AccountBrowser.ktnew file mode 100644index 00000000..375a69ef--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/AccountBrowser.kt@@ -0,0 +1,52 @@+package com.music.spotui.ui.screens++import android.annotation.SuppressLint+import android.app.Activity+import android.content.Context+import android.content.Intent+import android.os.Bundle+import android.webkit.CookieManager+import android.webkit.WebView+import android.webkit.WebViewClient+import androidx.activity.OnBackPressedCallback+import androidx.activity.ComponentActivity++/**+ * Spotify's account pages (plan, privacy, apps, devices) in a browser that shares the+ * app's sign-in: WebViews of one app share cookies, so no second login.+ */+class AccountBrowser : ComponentActivity() {+ private lateinit var web: WebView++ @SuppressLint("SetJavaScriptEnabled")+ override fun onCreate(savedInstanceState: Bundle?) {+ super.onCreate(savedInstanceState)+ web = WebView(this).apply {+ settings.javaScriptEnabled = true+ settings.domStorageEnabled = true+ CookieManager.getInstance().setAcceptThirdPartyCookies(this, true)+ webViewClient = WebViewClient()+ loadUrl(intent.getStringExtra(EXTRA_URL) ?: ACCOUNT_URL)+ }+ setContentView(web)+ onBackPressedDispatcher.addCallback(this, object : OnBackPressedCallback(true) {+ override fun handleOnBackPressed() { if (web.canGoBack()) web.goBack() else finish() }+ })+ }++ override fun onDestroy() {+ web.destroy()+ super.onDestroy()+ }++ companion object {+ const val ACCOUNT_URL = "https://www.spotify.com/account/overview/"+ private const val EXTRA_URL = "url"++ fun open(context: Context, url: String) {+ context.startActivity(Intent(context, AccountBrowser::class.java)+ .putExtra(EXTRA_URL, url)+ .apply { if (context !is Activity) addFlags(Intent.FLAG_ACTIVITY_NEW_TASK) })+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/AlbumByIdScreen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/AlbumByIdScreen.ktnew file mode 100644index 00000000..46deeec9--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/AlbumByIdScreen.kt@@ -0,0 +1,37 @@+package com.music.spotui.ui.screens++import app.myspoti.engine.R++import androidx.compose.ui.res.stringResource++import com.music.spotui.ui.components.SkeletonKind+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.graphics.Color+import androidx.compose.material3.Text+import androidx.navigation.NavController+import com.music.spotui.di.Graph+import com.music.spotui.ui.components.Loader++/** Opens the album page by Spotify id, resolving it from the name only when needed. */+@Composable+fun AlbumByIdScreen(navController: NavController, name: String, artist: String, id: String) {+ var resolved by remember(name, artist, id) { mutableStateOf(id.ifBlank { null }) }+ var failed by remember { mutableStateOf(false) }+ LaunchedEffect(name, artist, id) {+ if (resolved == null) {+ resolved = Graph.api.resolveAlbumId(name, artist)+ if (resolved == null) failed = true+ }+ }+ val albumId = resolved+ when {+ albumId != null -> ContextScreen(navController, type = "album", id = albumId)+ failed -> Text(stringResource(R.string.album_not_found), color = Color.White)+ else -> Loader(SkeletonKind.Header)+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/ArtistScreen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/ArtistScreen.ktnew file mode 100644index 00000000..a3313f15--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/ArtistScreen.kt@@ -0,0 +1,816 @@+package com.music.spotui.ui.screens++import com.music.spotui.ui.components.SkeletonKind+import com.music.spotui.ui.components.pressable+import androidx.compose.ui.res.stringResource++import androidx.compose.material.icons.filled.Check+import androidx.compose.material.icons.filled.MoreVert+import android.annotation.SuppressLint+import androidx.compose.foundation.ExperimentalFoundationApi+import androidx.compose.foundation.background+import androidx.compose.foundation.border+import androidx.compose.foundation.clickable+import androidx.compose.foundation.combinedClickable+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.PaddingValues+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.lazy.LazyRow+import androidx.compose.foundation.lazy.items+import androidx.compose.foundation.lazy.itemsIndexed+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.automirrored.filled.ArrowBack+import androidx.compose.material3.Icon+import androidx.compose.material3.Surface+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.collectAsState+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import com.music.spotui.ui.components.SongOptionsSheet+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Brush+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.toArgb+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.lifecycle.viewmodel.compose.viewModel+import androidx.navigation.NavController+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.bumptech.glide.integration.compose.placeholder+import app.myspoti.engine.R+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.AlbumsModel+import com.music.spotui.data.entity.ArtistOverviewModel+import com.music.spotui.data.entity.ArtistTrackUi+import com.music.spotui.data.entity.ArtistsModel+import com.music.spotui.data.preferences.addLikedSongId+import com.music.spotui.data.preferences.isSongLiked+import com.music.spotui.data.preferences.removeLikedSongId+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.components.Loader+import com.music.spotui.ui.navigation.Routes+import com.music.spotui.ui.navigation.albumRoute+import com.music.spotui.ui.navigation.artistRoute+import com.music.spotui.ui.theme.AppBackground+import com.music.spotui.ui.theme.AppPalette+import com.music.spotui.ui.viewmodel.ArtistViewModel++private val SpotifyGreen: Color get() = com.music.spotui.ui.theme.AppAccent++private fun grouped(n: Long): String =+ "%,d".format(n)++@Composable+fun ArtistScreen(navController: NavController, artistName: String, artistId: String = "") {+ val artistViewModel: ArtistViewModel = viewModel()+ val overview by artistViewModel.overview.collectAsState()++ LaunchedEffect(artistName, artistId) { artistViewModel.loadArtistOverview(artistName, artistId) }++ Surface(+ modifier = Modifier+ .fillMaxSize()+ .background(Color(AppBackground.toArgb()))+ ) {+ when (val state = overview) {+ is Response.Loading -> Loader(SkeletonKind.Header)+ is Response.Error -> ArtistOverviewContent(+ navController, artistViewModel,+ ArtistOverviewModel(name = artistName), artistName,+ )+ is Response.Success -> ArtistOverviewContent(+ navController, artistViewModel, state.data, artistName,+ )+ }+ }+}++@SuppressLint("DefaultLocale")+@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun ArtistOverviewContent(+ navController: NavController,+ artistViewModel: ArtistViewModel,+ overview: ArtistOverviewModel,+ artistName: String,+) {+ val context = LocalContext.current+ val tracks = overview.topTracks+ val displayName = overview.name.ifBlank { artistName }++ var menuSong by remember { mutableStateOf<com.music.spotui.data.entity.SongsModel?>(null) }+ menuSong?.let { sel ->+ SongOptionsSheet(+ song = sel,+ navController = navController,+ context = context,+ onDismiss = { menuSong = null },+ )+ }++ // Follow + liked tracks straight from the user's Spotify library.+ var following by remember(overview.id) { mutableStateOf(false) }+ var saved by remember(overview.id) { mutableStateOf<Set<String>>(emptySet()) }+ LaunchedEffect(overview.id) {+ val uris = tracks.map { "spotify:track:${it.song.spotifyTrackId}" } + "spotify:artist:${overview.id}"+ val res = SongPlayer.libraryContains(uris)+ saved = res+ following = "spotify:artist:${overview.id}" in res+ }+ var showAllPopular by remember { mutableStateOf(false) }+ val np by SongPlayer.nowPlaying+ val isThisArtist = np.contextUri == "spotify:artist:${overview.id}"+ val playingNow = artistViewModel.currentSongPlayingState.value+ val listState = androidx.compose.foundation.lazy.rememberLazyListState()++ fun playTrackAt(index: Int) {+ if (index !in tracks.indices) return+ val songs = tracks.map { it.song }+ artistViewModel.updateQueue(songs)+ val s = songs[index]+ SongPlayer.playSong(s.url, context)+ artistViewModel.updateSongState(s.coverUri, s.title, s.singer, true, s.id, index)+ }++ Box(modifier = Modifier.fillMaxSize()) {+ LazyColumn(+ state = listState,+ contentPadding = PaddingValues(bottom = 130.dp),+ modifier = Modifier+ .fillMaxSize()+ .background(Color(AppBackground.toArgb()))+ ) {+ // ── Header: big artist image with scrim + name ──+ item {+ Box(modifier = Modifier+ .fillMaxWidth()+ .height(340.dp)+ ) {+ GlideImage(+ modifier = Modifier.fillMaxSize(),+ model = overview.headerImage.ifBlank { overview.avatarImage },+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Box(modifier = Modifier+ .fillMaxSize()+ .background(+ Brush.verticalGradient(+ colors = listOf(+ Color.Black.copy(alpha = 0.35f),+ Color.Transparent,+ Color(AppBackground.toArgb()),+ ),+ )+ )+ )+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier+ .statusBarsPadding()+ .padding(12.dp)+ .size(40.dp)+ .clip(CircleShape)+ .background(Color.Black.copy(alpha = 0.35f))+ .clickable { navController.navigateUp() },+ ) {+ Icon(Icons.AutoMirrored.Filled.ArrowBack, contentDescription = stringResource(R.string.accessibility_navigate_back), tint = Color.White)+ }+ Column(+ modifier = Modifier+ .align(Alignment.BottomStart)+ .padding(16.dp, 0.dp, 16.dp, 12.dp),+ ) {+ Text(+ text = displayName,+ color = Color.White,+ fontSize = 44.sp,+ fontWeight = FontWeight.ExtraBold,+ lineHeight = 46.sp,+ maxLines = 2,+ )+ if (overview.verified) Row(verticalAlignment = Alignment.CenterVertically, modifier = Modifier.padding(top = 6.dp)) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.size(18.dp).clip(CircleShape).background(SpotifyGreen),+ ) {+ Icon(Icons.Default.Check, contentDescription = null, tint = Color.Black, modifier = Modifier.size(13.dp))+ }+ Spacer(Modifier.width(6.dp))+ Text(stringResource(R.string.verified_artist), color = Color.White, fontSize = 14.sp, fontWeight = FontWeight.Bold)+ }+ }+ }+ }++ // ── Monthly listeners (compact, like "4,3 M auditeurs et auditrices par mois") ──+ item {+ overview.monthlyListeners?.let {+ val compact = android.icu.text.CompactDecimalFormat+ .getInstance(java.util.Locale.getDefault(), android.icu.text.CompactDecimalFormat.CompactStyle.SHORT)+ .format(it)+ Text(+ text = stringResource(R.string.monthly_listeners_text, compact),+ color = Color.White.copy(alpha = 0.7f),+ fontSize = 14.sp,+ modifier = Modifier.padding(16.dp, 12.dp, 16.dp, 0.dp),+ )+ }+ }++ // ── Action row: Follow + shuffle + play ──+ item {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ horizontalArrangement = Arrangement.SpaceBetween,+ modifier = Modifier+ .fillMaxWidth()+ .padding(16.dp, 16.dp),+ ) {+ Row(verticalAlignment = Alignment.CenterVertically) {+ overview.popularReleases.firstOrNull()?.let { latest ->+ GlideImage(+ model = latest.coverUri,+ contentDescription = latest.name,+ contentScale = ContentScale.Crop,+ modifier = Modifier+ .size(width = 36.dp, height = 48.dp)+ .clip(RoundedCornerShape(4.dp))+ .clickable { navController.navigate(albumRoute(latest.name, displayName, latest.spotifyId)) },+ )+ Spacer(Modifier.width(16.dp))+ }+ Box(modifier = Modifier.pressable(0.96f) {+ val on = !(SongPlayer.library["spotify:artist:${overview.id}"] ?: following)+ following = on+ com.music.spotui.di.Haptics.toggle(on)+ SongPlayer.setSaved("spotify:artist:${overview.id}", on)+ }+ .clip(RoundedCornerShape(20.dp))+ .border(1.dp, Color.Gray, RoundedCornerShape(20.dp))++ .padding(16.dp, 7.dp),+ ) {+ Text(+ text = stringResource(if (SongPlayer.library["spotify:artist:${overview.id}"] ?: following) R.string.curation_button_following_state_text else R.string.curation_button_follow_state_text),+ color = Color.White,+ fontSize = 13.sp,+ fontWeight = FontWeight.SemiBold,+ )+ }+ Spacer(Modifier.width(16.dp))+ Icon(+ Icons.Default.MoreVert,+ contentDescription = stringResource(R.string.content_description_context_menu),+ tint = Color.White.copy(alpha = 0.7f),+ modifier = Modifier.size(24.dp),+ )+ }++ Row(verticalAlignment = Alignment.CenterVertically) {+ Icon(+ painter = painterResource(id = R.drawable.ic_player_shuffle),+ contentDescription = stringResource(R.string.play_mode_item_shuffle_title),+ tint = if (isThisArtist && com.music.spotui.di.Graph.currentSongState.shuffle.value) SpotifyGreen else Color.White,+ modifier = Modifier.pressable(0.96f) {+ if (tracks.isNotEmpty()) {+ com.music.spotui.di.Graph.currentSongState.startShuffled(tracks.map { it.song })+ }+ }+ .size(26.dp)+ ,+ )+ Spacer(Modifier.width(20.dp))+ Box(modifier = Modifier.pressable(0.96f) {+ when {+ isThisArtist && playingNow -> SongPlayer.pause()+ isThisArtist -> SongPlayer.play()+ else -> playTrackAt(0)+ }+ }+ .size(56.dp)+ .clip(CircleShape)+ .background(SpotifyGreen)+ ,+ contentAlignment = Alignment.Center,+ ) {+ Icon(+ painter = painterResource(id = if (isThisArtist && playingNow) R.drawable.ic_playing else R.drawable.play_svgrepo_com),+ contentDescription = if (isThisArtist && playingNow) stringResource(R.string.content_description_pause_button) else stringResource(R.string.content_description_play_button),+ tint = Color.Black,+ modifier = Modifier.size(26.dp),+ )+ }+ }+ }+ }++ // ── Popular tracks ──+ if (tracks.isNotEmpty()) {+ item {+ Text(+ text = stringResource(R.string.artist_popular_tracks),+ color = Color.White,+ fontSize = 20.sp,+ fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(16.dp, 8.dp, 16.dp, 4.dp),+ )+ }+ itemsIndexed(tracks.take(if (showAllPopular) 10 else 5)) { index, item ->+ com.music.spotui.ui.components.SwipeToQueue(item.song) {+ PopularTrackRow(+ item, index, artistViewModel,+ saved = SongPlayer.library["spotify:track:${item.song.spotifyTrackId}"] ?: ("spotify:track:${item.song.spotifyTrackId}" in saved),+ onToggleSaved = { on ->+ SongPlayer.setTrackSaved(item.song.spotifyTrackId, on)+ },+ onMore = { menuSong = item.song },+ onPlay = { playTrackAt(index) },+ )+ }+ }+ if (tracks.size > 5) item {+ Box(contentAlignment = Alignment.Center, modifier = Modifier.fillMaxWidth().padding(vertical = 12.dp)) {+ Box(+ modifier = Modifier+ .clip(RoundedCornerShape(50))+ .border(1.dp, Color.White.copy(alpha = 0.5f), RoundedCornerShape(50))+ .clickable { showAllPopular = !showAllPopular }+ .padding(horizontal = 20.dp, vertical = 8.dp),+ ) {+ Text(if (showAllPopular) stringResource(R.string.profile_bio_show_less) else stringResource(R.string.audiobook_series_see_more_button), color = Color.White, fontSize = 14.sp, fontWeight = FontWeight.Bold)+ }+ }+ }+ }++ // ── Popular releases (discography) — vertical list, first few + "Show all" ──+ if (overview.popularReleases.isNotEmpty()) {+ item { SectionHeader(stringResource(R.string.popular_releases_section_title)) }+ itemsIndexed(overview.popularReleases.take(4)) { _, album ->+ ReleaseRow(album) {+ navController.navigate(albumRoute(album.name, album.artists.ifBlank { displayName }, album.spotifyId))+ }+ }+ if (overview.popularReleases.size > 4) {+ item {+ ShowAllButton {+ navController.navigate("${Routes.ArtistReleases.route}/$artistName")+ }+ }+ }+ }++ // ── About ──+ if (!overview.biography.isNullOrBlank()) {+ item { SectionHeader(stringResource(R.string.creator_biography_section_title)) }+ item {+ Box(modifier = Modifier+ .fillMaxWidth()+ .padding(16.dp, 4.dp)+ .clip(RoundedCornerShape(10.dp))+ .background(Color.White.copy(alpha = 0.06f))+ ) {+ Column {+ if (overview.avatarImage.isNotBlank()) {+ GlideImage(+ modifier = Modifier+ .fillMaxWidth()+ .height(200.dp),+ model = overview.avatarImage,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ }+ overview.monthlyListeners?.let {+ Text(+ text = stringResource(R.string.monthly_listeners_text, grouped(it)),+ color = Color.White,+ fontSize = 15.sp,+ fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(14.dp, 12.dp, 14.dp, 4.dp),+ )+ }+ Text(+ text = overview.biography.orEmpty(),+ color = Color.Gray,+ fontSize = 13.sp,+ modifier = Modifier.padding(14.dp, 4.dp, 14.dp, 16.dp),+ )+ }+ }+ }+ }++ // ── Fans also like ──+ if (overview.relatedArtists.isNotEmpty()) {+ item { SectionHeader(stringResource(R.string.fans_also_like_section_title)) }+ item {+ LazyRow(+ contentPadding = androidx.compose.foundation.layout.PaddingValues(12.dp, 0.dp),+ ) {+ items(overview.relatedArtists.size) { i ->+ RelatedArtistCard(overview.relatedArtists[i]) {+ navController.navigate(artistRoute(overview.relatedArtists[i].name, overview.relatedArtists[i].id))+ }+ }+ }+ }+ }++ // ── Appears on ──+ if (overview.appearsOn.isNotEmpty()) {+ item { SectionHeader(stringResource(R.string.appears_on_section_title)) }+ item {+ LazyRow(+ contentPadding = androidx.compose.foundation.layout.PaddingValues(12.dp, 0.dp),+ ) {+ items(overview.appearsOn.size) { i ->+ ReleaseCard(overview.appearsOn[i]) {+ navController.navigate(albumRoute(overview.appearsOn[i].name, overview.appearsOn[i].artists, overview.appearsOn[i].spotifyId))+ }+ }+ }+ }+ }+ }+ // Title bar that fades in once the header has scrolled away (official app).+ val collapsed by remember { androidx.compose.runtime.derivedStateOf { listState.firstVisibleItemIndex > 0 } }+ androidx.compose.animation.AnimatedVisibility(+ visible = collapsed,+ enter = androidx.compose.animation.fadeIn(),+ exit = androidx.compose.animation.fadeOut(),+ ) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .background(Color(0xFF2A2A2A))+ .statusBarsPadding()+ .height(56.dp)+ .padding(horizontal = 12.dp),+ ) {+ Icon(+ Icons.AutoMirrored.Filled.ArrowBack, contentDescription = stringResource(R.string.accessibility_navigate_back), tint = Color.White,+ modifier = Modifier.size(26.dp).clickable { navController.navigateUp() },+ )+ Text(+ displayName, color = Color.White, fontSize = 18.sp, fontWeight = FontWeight.Bold,+ maxLines = 1, overflow = androidx.compose.ui.text.style.TextOverflow.Ellipsis,+ textAlign = androidx.compose.ui.text.style.TextAlign.Center,+ modifier = Modifier.weight(1f).padding(end = 26.dp),+ )+ }+ }+ }+}++@OptIn(ExperimentalGlideComposeApi::class, ExperimentalFoundationApi::class)+@Composable+private fun PopularTrackRow(+ item: ArtistTrackUi,+ index: Int,+ artistViewModel: ArtistViewModel,+ saved: Boolean,+ onToggleSaved: (Boolean) -> Unit,+ onMore: () -> Unit,+ onPlay: () -> Unit,+) {+ val song = item.song+ val titleColor =+ if (song.id == artistViewModel.currentSongId.value) SpotifyGreen else Color.White++ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .combinedClickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ onLongClick = onMore,+ onClick = onPlay,+ )+ .padding(16.dp, 6.dp),+ ) {+ Text(+ text = "${index + 1}",+ color = Color.White.copy(alpha = 0.7f),+ fontSize = 15.sp,+ modifier = Modifier.width(24.dp),+ )+ GlideImage(+ modifier = Modifier+ .padding(8.dp, 0.dp, 12.dp, 0.dp)+ .size(48.dp)+ .clip(RoundedCornerShape(4.dp)),+ model = song.coverUri,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Column(modifier = Modifier.weight(1f)) {+ Text(text = song.title, color = titleColor, fontSize = 16.sp, maxLines = 1, overflow = androidx.compose.ui.text.style.TextOverflow.Ellipsis)+ Row(verticalAlignment = Alignment.CenterVertically) {+ if (song.explicit) { ExplicitBadge(); Spacer(Modifier.width(6.dp)) }+ Text(text = item.playcount?.let { grouped(it) } ?: song.singer, color = Color.White.copy(alpha = 0.7f), fontSize = 13.sp, maxLines = 1)+ }+ }+ if (saved) {+ LikeButton(liked = true, size = 22.dp) { onToggleSaved(false) }+ Spacer(Modifier.width(16.dp))+ }+ Icon(+ Icons.Default.MoreVert,+ contentDescription = stringResource(R.string.content_description_context_menu),+ tint = Color.White.copy(alpha = 0.7f),+ modifier = Modifier.pressable(0.96f) { onMore() }+ .size(24.dp)+ ,+ )+ }+}++@Composable+private fun SectionHeader(title: String) {+ Text(+ text = title,+ color = Color.White,+ fontSize = 20.sp,+ fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(16.dp, 20.dp, 16.dp, 8.dp),+ )+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun ReleaseCard(album: AlbumsModel, onClick: () -> Unit) {+ Column(+ modifier = Modifier.pressable(0.96f) { onClick() }+ .width(140.dp)+ .padding(4.dp)+ ,+ ) {+ GlideImage(+ modifier = Modifier+ .size(132.dp)+ .clip(RoundedCornerShape(6.dp)),+ model = album.coverUri,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Spacer(Modifier.height(6.dp))+ Text(text = album.name, color = Color.White, fontSize = 13.sp, fontWeight = FontWeight.Medium, maxLines = 1)+ Text(+ text = album.time.ifBlank { album.artists }.let { if (album.time.isNotBlank()) "${album.time} • Album" else it },+ color = Color.Gray,+ fontSize = 11.sp,+ maxLines = 1,+ )+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun ReleaseRow(album: AlbumsModel, onClick: () -> Unit) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.pressable(0.96f) { onClick() }+ .fillMaxWidth()+ .padding(16.dp, 6.dp)+ ,+ ) {+ GlideImage(+ modifier = Modifier+ .size(88.dp)+ .clip(RoundedCornerShape(4.dp)),+ model = album.coverUri,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Spacer(Modifier.width(14.dp))+ Column(modifier = Modifier.weight(1f)) {+ Text(text = album.name, color = Color.White, fontSize = 17.sp, fontWeight = FontWeight.Bold, maxLines = 1)+ val kind = album.type.replaceFirstChar { it.uppercase() }.ifBlank { "" }+ val year = releaseYear(album)+ Text(+ text = listOf(year, kind).filter { it.isNotBlank() }.joinToString(" • "),+ color = Color.Gray,+ fontSize = 13.sp,+ maxLines = 1,+ modifier = Modifier.padding(top = 2.dp),+ )+ }+ }+}++@Composable+private fun ShowAllButton(onClick: () -> Unit) {+ Box(modifier = Modifier.pressable(0.96f) { onClick() }+ .padding(16.dp, 10.dp, 16.dp, 4.dp)+ .clip(RoundedCornerShape(20.dp))+ .border(1.dp, Color.Gray, RoundedCornerShape(20.dp))++ .padding(20.dp, 8.dp),+ ) {+ Text(text = stringResource(R.string.composer_section_button_show_all), color = Color.White, fontSize = 13.sp, fontWeight = FontWeight.SemiBold)+ }+}++/** Release-year helper: Spotify release dates come as "2024" or "2024-05-17". */+private fun releaseYear(album: AlbumsModel): String = album.time.take(4)++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun ArtistReleasesScreen(navController: NavController, artistName: String) {+ val artistViewModel: ArtistViewModel = viewModel()+ val overview by artistViewModel.overview.collectAsState()++ LaunchedEffect(artistName) { artistViewModel.loadArtistOverview(artistName) }++ Surface(+ modifier = Modifier+ .fillMaxSize()+ .background(Color(AppBackground.toArgb()))+ ) {+ val data = (overview as? Response.Success)?.data+ val releases = data?.popularReleases ?: emptyList()+ val featuredOn = data?.appearsOn ?: emptyList()+ // Spotify's Releases view: filter chips + a "Latest release" spotlight,+ // then releases grouped by kind, newest first.+ val albums = releases.filter { it.type == "album" || it.type == "compilation" }+ val singles = releases.filter { it.type == "single" || it.type == "ep" }+ val untyped = releases.filter { it.type.isBlank() }+ val latest = releases.maxByOrNull { it.time }+ var filter by remember { mutableStateOf("") } // "" | "albums" | "singles" | "featured"++ fun openAlbum(album: AlbumsModel) {+ navController.navigate(albumRoute(album.name, album.artists.ifBlank { artistName }, album.spotifyId))+ }++ LazyColumn(+ contentPadding = PaddingValues(bottom = 130.dp),+ modifier = Modifier+ .fillMaxSize()+ .background(Color(AppBackground.toArgb()))+ ) {+ item {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .statusBarsPadding()+ .padding(16.dp, 12.dp, 16.dp, 12.dp),+ ) {+ Icon(+ imageVector = Icons.AutoMirrored.Filled.ArrowBack,+ contentDescription = "",+ tint = Color.White,+ modifier = Modifier.pressable(0.96f) { navController.navigateUp() }+ .size(26.dp)+ ,+ )+ Spacer(Modifier.width(16.dp))+ Text(+ text = stringResource(R.string.releases_title),+ color = Color.White,+ fontSize = 20.sp,+ fontWeight = FontWeight.Bold,+ )+ }+ }+ item {+ Row(modifier = Modifier.padding(12.dp, 0.dp, 12.dp, 8.dp)) {+ ReleaseFilterChip(stringResource(R.string.artist_releases_albums), filter == "albums") {+ filter = if (filter == "albums") "" else "albums"+ }+ Spacer(Modifier.width(8.dp))+ ReleaseFilterChip(stringResource(R.string.artist_releases_singles), filter == "singles") {+ filter = if (filter == "singles") "" else "singles"+ }+ if (featuredOn.isNotEmpty()) {+ Spacer(Modifier.width(8.dp))+ ReleaseFilterChip("Featured on", filter == "featured") {+ filter = if (filter == "featured") "" else "featured"+ }+ }+ }+ }+ if (overview is Response.Loading) {+ item { Loader() }+ }+ when (filter) {+ "albums" -> items(albums.size) { i -> ReleaseRow(albums[i]) { openAlbum(albums[i]) } }+ "singles" -> items(singles.size) { i -> ReleaseRow(singles[i]) { openAlbum(singles[i]) } }+ "featured" -> items(featuredOn.size) { i -> ReleaseRow(featuredOn[i]) { openAlbum(featuredOn[i]) } }+ else -> {+ latest?.let {+ item { ReleaseSectionHeader(stringResource(R.string.latest_release_title)) }+ item { ReleaseRow(it) { openAlbum(it) } }+ }+ if (albums.isNotEmpty()) {+ item { ReleaseSectionHeader(stringResource(R.string.artist_releases_albums)) }+ items(albums.size) { i -> ReleaseRow(albums[i]) { openAlbum(albums[i]) } }+ }+ if (singles.isNotEmpty()) {+ item { ReleaseSectionHeader(stringResource(R.string.artist_releases_singles)) }+ items(singles.size) { i -> ReleaseRow(singles[i]) { openAlbum(singles[i]) } }+ }+ if (untyped.isNotEmpty()) {+ if (albums.isEmpty() && singles.isEmpty()) {+ item { ReleaseSectionHeader(stringResource(R.string.popular_releases_section_title)) }+ }+ items(untyped.size) { i -> ReleaseRow(untyped[i]) { openAlbum(untyped[i]) } }+ }+ }+ }+ }+ }+}++@Composable+private fun ReleaseSectionHeader(title: String) {+ Text(+ text = title,+ color = Color.White,+ fontSize = 22.sp,+ fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(16.dp, 18.dp, 16.dp, 8.dp),+ )+}++@Composable+private fun ReleaseFilterChip(label: String, selected: Boolean, onClick: () -> Unit) {+ Box(+ modifier = Modifier.pressable(0.96f) { onClick() }+ .clip(RoundedCornerShape(20.dp))+ .background(if (selected) Color.White else Color(0xFF2A2A2A))++ .padding(14.dp, 8.dp),+ ) {+ Text(+ text = label,+ color = if (selected) Color.Black else Color.White,+ fontSize = 13.sp,+ fontWeight = FontWeight.SemiBold,+ )+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun RelatedArtistCard(artist: ArtistsModel, onClick: () -> Unit) {+ Column(+ horizontalAlignment = Alignment.CenterHorizontally,+ modifier = Modifier.pressable(0.96f) { onClick() }+ .width(130.dp)+ .padding(4.dp)+ ,+ ) {+ GlideImage(+ modifier = Modifier+ .size(122.dp)+ .clip(CircleShape),+ model = artist.coverUri,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Spacer(Modifier.height(6.dp))+ Text(text = artist.name, color = Color.White, fontSize = 13.sp, fontWeight = FontWeight.Medium, maxLines = 1)+ Text(text = stringResource(R.string.artist_subtitle), color = Color.Gray, fontSize = 11.sp)+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/CategoryScreen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/CategoryScreen.ktnew file mode 100644index 00000000..1e50f6d5--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/CategoryScreen.kt@@ -0,0 +1,153 @@+package com.music.spotui.ui.screens++import androidx.compose.ui.res.stringResource++import com.music.spotui.ui.components.pressable+import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.PaddingValues+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.aspectRatio+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.lazy.grid.GridCells+import androidx.compose.foundation.lazy.grid.LazyVerticalGrid+import androidx.compose.foundation.lazy.grid.items+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.automirrored.filled.ArrowBack+import androidx.compose.material3.Icon+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.collectAsState+import androidx.compose.runtime.getValue+import androidx.compose.runtime.remember+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.lifecycle.viewmodel.compose.viewModel+import androidx.navigation.NavController+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.bumptech.glide.integration.compose.placeholder+import app.myspoti.engine.R+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.LibraryEntry+import com.music.spotui.ui.components.Loader+import com.music.spotui.ui.components.Snackbar+import com.music.spotui.ui.navigation.playlistRoute+import com.music.spotui.ui.viewmodel.CategoryViewModel++@Composable+fun CategoryScreen(navController: NavController, genre: String, title: String) {+ val viewModel: CategoryViewModel = viewModel()+ LaunchedEffect(genre) { viewModel.load(genre) }+ val playlists by viewModel.playlists.collectAsState()++ Column(+ modifier = Modifier+ .fillMaxSize()+ .background(Color(0xFF0E0E13))+ .statusBarsPadding()+ ) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .padding(8.dp, 12.dp, 16.dp, 8.dp)+ ) {+ Icon(+ imageVector = Icons.AutoMirrored.Filled.ArrowBack,+ contentDescription = stringResource(R.string.accessibility_navigate_back),+ tint = Color.White,+ modifier = Modifier+ .size(40.dp)+ .clip(RoundedCornerShape(20.dp))+ .clickable { navController.popBackStack() }+ .padding(8.dp)+ )+ Text(+ text = title,+ fontWeight = FontWeight.Bold,+ color = Color.White,+ fontSize = 22.sp,+ maxLines = 1,+ overflow = TextOverflow.Ellipsis,+ modifier = Modifier.padding(start = 6.dp),+ )+ }++ when (playlists) {+ is Response.Loading -> Loader()+ is Response.Success -> CategoryGrid((playlists as Response.Success).data, navController)+ else -> Box(modifier = Modifier.padding(20.dp, 60.dp)) { Snackbar(showMessage = stringResource(R.string.couldnt_load, title)) }+ }+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun CategoryGrid(entries: List<LibraryEntry>, navController: NavController) {+ if (entries.isEmpty()) {+ Box(modifier = Modifier.padding(20.dp, 40.dp)) { Snackbar(showMessage = stringResource(R.string.nothing_here)) }+ return+ }+ LazyVerticalGrid(+ columns = GridCells.Fixed(2),+ contentPadding = PaddingValues(12.dp, 8.dp, 12.dp, 130.dp),+ horizontalArrangement = Arrangement.spacedBy(12.dp),+ verticalArrangement = Arrangement.spacedBy(16.dp),+ modifier = Modifier.fillMaxSize(),+ ) {+ items(entries) { entry ->+ Column(+ modifier = Modifier.pressable(0.96f, onPressHint = { if (entry.isPlaylist) ContextViewModel.prefetch("playlist", entry.spotifyId) }) {+ navController.navigate(if (entry.isPlaylist) playlistRoute(entry.spotifyId, entry.name) else com.music.spotui.ui.navigation.albumRoute(entry.name, entry.subtitle, entry.spotifyId))+ }++ ) {+ GlideImage(+ modifier = Modifier+ .fillMaxWidth()+ .aspectRatio(1f)+ .clip(RoundedCornerShape(6.dp)),+ model = entry.coverUri,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Text(+ text = entry.name,+ color = Color.White,+ fontSize = 13.sp,+ fontWeight = FontWeight.Bold,+ maxLines = 2,+ overflow = TextOverflow.Ellipsis,+ modifier = Modifier.padding(top = 6.dp),+ )+ Text(+ text = entry.subtitle,+ color = Color.Gray,+ fontSize = 11.sp,+ maxLines = 1,+ overflow = TextOverflow.Ellipsis,+ )+ }+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/ContextScreen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/ContextScreen.ktnew file mode 100644index 00000000..f303a427--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/ContextScreen.kt@@ -0,0 +1,594 @@+package com.music.spotui.ui.screens++import androidx.compose.material.icons.filled.SwapVert+import androidx.compose.ui.res.stringResource++import kotlinx.coroutines.flow.first+import kotlinx.coroutines.async+import com.music.spotui.ui.components.SkeletonKind+import com.music.spotui.ui.components.pressable+import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.aspectRatio+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.lazy.itemsIndexed+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.automirrored.filled.ArrowBack+import androidx.compose.material.icons.filled.Check+import androidx.compose.material.icons.filled.Favorite+import androidx.compose.material.icons.filled.MoreVert+import androidx.compose.material3.Icon+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.collectAsState+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.draw.drawWithContent+import androidx.compose.ui.draw.shadow+import androidx.compose.ui.graphics.Brush+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.lerp+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.lifecycle.ViewModel+import androidx.lifecycle.viewModelScope+import androidx.lifecycle.viewmodel.compose.viewModel+import androidx.navigation.NavController+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.music.spotui.data.api.Api+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.ContextPageModel+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.di.CurrentSongState+import com.music.spotui.di.Graph+import com.music.spotui.di.Palette+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.components.Loader+import com.music.spotui.ui.navigation.artistRoute+import app.myspoti.engine.R+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.StateFlow+import kotlinx.coroutines.launch++private val SpotifyGreen: Color get() = com.music.spotui.ui.theme.AppAccent+private val PageBackground: Color get() = com.music.spotui.ui.theme.AppBackground++/** Album / playlist page, loaded by Spotify id and laid out like the official app. */+class ContextViewModel(+ private val api: Api = Graph.api,+ private val state: CurrentSongState = Graph.currentSongState,+) : ViewModel() {+ companion object {+ // Last pages shown, process-wide (back / forward / reopen are instant).+ private val recent = object : java.util.LinkedHashMap<String, Response<ContextPageModel>>(16, 0.75f, true) {+ override fun removeEldestEntry(eldest: MutableMap.MutableEntry<String, Response<ContextPageModel>>?) = size > 12+ }.let { java.util.Collections.synchronizedMap(it) }++ // Look-ups started by a touch (see pressHint), joined by the page when it opens.+ private val inflight = java.util.concurrent.ConcurrentHashMap<String, kotlinx.coroutines.Deferred<Unit>>()+ private val prefetchScope = kotlinx.coroutines.CoroutineScope(kotlinx.coroutines.SupervisorJob() + Dispatchers.IO)++ /** Start loading a page the user is about to open (first page of tracks). */+ fun prefetch(type: String, id: String) {+ if (id.isBlank() && type != "liked") return+ val key = "$type:$id"+ if (recent[key] is Response.Success || inflight.containsKey(key)) return+ inflight[key] = prefetchScope.async {+ try {+ val api = Graph.api+ val flow = when (type) {+ "album" -> api.getAlbumPage(id)+ "liked" -> api.getLikedPage()+ else -> api.getPlaylistPage(id)+ }+ val first = flow.first { it !is Response.Loading }+ if (first is Response.Success) recent[key] = first+ } catch (t: kotlinx.coroutines.CancellationException) {+ throw t+ } catch (_: Throwable) {+ } finally {+ inflight.remove(key)+ }+ }+ }+ }+ private val _page = MutableStateFlow<Response<ContextPageModel>>(Response.Loading())+ val page: StateFlow<Response<ContextPageModel>> = _page+ val savedUris = mutableStateOf<Set<String>>(emptySet())+ val contextSaved = mutableStateOf(false)+ private var key: String? = null+ private var savedChecked = 0++ fun load(type: String, id: String) {+ if (key == "$type:$id") return+ key = "$type:$id"+ // A page seen recently is on screen from the first frame (no blank, then pop,+ // in the middle of the slide); the network still refreshes it behind.+ recent[key]?.let { _page.value = it }+ val pending = inflight[key]+ viewModelScope.launch(Dispatchers.IO) {+ // Touched a moment ago: join that look-up instead of sending a second one.+ if (pending != null && _page.value !is Response.Success) {+ runCatching { pending.await() }+ recent[key]?.let { _page.value = it }+ }+ val flow = when (type) {+ "album" -> api.getAlbumPage(id)+ "liked" -> api.getLikedPage()+ else -> api.getPlaylistPage(id)+ }+ flow.collect { r ->+ if (r is Response.Loading && _page.value is Response.Success) return@collect+ _page.value = r+ if (r is Response.Success) {+ recent[key!!] = r+ val p = r.data+ // Check saved state on the first page and again once complete.+ if ((savedChecked == 0 && p.tracks.isNotEmpty()) || (p.complete && savedChecked < 2)) {+ savedChecked = if (p.complete) 2 else 1+ refreshSaved(p)+ }+ }+ }+ }+ }++ private fun refreshSaved(p: ContextPageModel) = viewModelScope.launch {+ if (p.type == "liked") {+ // Everything here is liked by definition.+ savedUris.value = p.tracks.map { "spotify:track:${it.spotifyTrackId}" }.toSet()+ return@launch+ }+ val uris = p.tracks.mapNotNull { s -> s.spotifyTrackId.takeIf { it.isNotBlank() }?.let { "spotify:track:$it" } } + p.uri+ val saved = SongPlayer.libraryContains(uris)+ savedUris.value = saved+ contextSaved.value = p.uri in saved+ }++ fun toggleContextSaved(p: ContextPageModel) {+ val on = !(SongPlayer.library[p.uri] ?: contextSaved.value)+ com.music.spotui.di.Haptics.toggle(on)+ contextSaved.value = on+ SongPlayer.setSaved(p.uri, on)+ }++ fun play(p: ContextPageModel, song: SongsModel) {+ // No connection (the Web Player cannot stream), or the data saver on mobile data:+ // the page's downloaded songs play from the phone.+ val app = Graph.app+ if (com.music.spotui.data.offline.OfflineStore.isDownloaded(song.spotifyTrackId) &&+ (com.music.spotui.data.DataSaver.active || !com.music.spotui.data.offline.OfflineStore.isOnline(app))) {+ val local = p.tracks.mapNotNull { com.music.spotui.data.offline.OfflineStore.tracks[it.spotifyTrackId] }.distinctBy { it.trackId }+ val at = local.indexOfFirst { it.trackId == song.spotifyTrackId }.coerceAtLeast(0)+ if (local.size < p.tracks.size)+ android.widget.Toast.makeText(app, app.getString(R.string.offline_only_downloaded, local.size, p.tracks.size), android.widget.Toast.LENGTH_SHORT).show()+ com.music.spotui.di.LocalPlayer.play(local.map(com.music.spotui.data.offline.OfflineStore::toLocalTrack), at, context = p.name)+ return+ }+ state.updateQueue(p.tracks)+ if (p.type == "liked") SongPlayer.registerLikedSongs(p.tracks.map { it.url })+ SongPlayer.playSong(song.url, contextUri = p.uri)+ state.updateSongState(song.coverUri, song.title, song.singer, true, song.id, 0, song.album)+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun ContextScreen(navController: NavController, type: String, id: String) {+ val vm: ContextViewModel = viewModel(key = "$type:$id")+ // During composition, so a cached page is there for the very first frame.+ remember(type, id) { vm.load(type, id) }+ val resp by vm.page.collectAsState()+ Box(modifier = Modifier.fillMaxSize().background(PageBackground)) {+ when (val r = resp) {+ is Response.Loading -> Loader(SkeletonKind.Header)+ is Response.Error -> Text(+ r.error,+ color = Color.White,+ modifier = Modifier.align(Alignment.Center).padding(24.dp),+ )+ is Response.Success -> ContextContent(navController, vm, r.data)+ }+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun ContextContent(navController: NavController, vm: ContextViewModel, p: ContextPageModel) {+ val context = LocalContext.current+ val playerVm: com.music.spotui.ui.viewmodel.PlayerViewModel = viewModel()+ val currentSongId = playerVm.currentSongId.value+ val playing = playerVm.currentSongPlayingState.value+ val shuffle = playerVm.shuffleState.value+ val np by SongPlayer.nowPlaying+ val isThisContext = np.contextUri == p.uri || (p.type == "liked" && np.contextUri.contains(":collection"))+ val saved by vm.savedUris+ val contextSaved by vm.contextSaved++ var tintTarget by remember { mutableStateOf(Palette.cachedSecond(p.coverUri) ?: Color(0xFF3A3A3A)) }+ LaunchedEffect(p.coverUri) {+ if (p.coverUri.isNotBlank()) Palette().extractSecondColorFromCoverUrl(context, p.coverUri) { tintTarget = it }+ }+ val tint by androidx.compose.animation.animateColorAsState(tintTarget, androidx.compose.animation.core.tween(350), label = "tint")+ var menuSong by remember { mutableStateOf<SongsModel?>(null) }+ // "Find in Liked Songs / in playlist".+ var find by remember { mutableStateOf("") }+ // "Sort by" for the list (kept per list while the screen lives).+ var sort by remember(p.uri) { mutableStateOf(TrackSort.CUSTOM) }+ var askRemoveDownloads by remember { mutableStateOf(false) }+ if (askRemoveDownloads) androidx.compose.material3.AlertDialog(+ onDismissRequest = { askRemoveDownloads = false },+ containerColor = Color(0xFF282828),+ title = { Text(stringResource(R.string.playlist_entity_remove_download_dialog_title), color = Color.White) },+ text = { Text(stringResource(R.string.playlist_entity_remove_download_dialog_description), color = Color(0xFFB3B3B3)) },+ confirmButton = {+ androidx.compose.material3.TextButton(onClick = {+ askRemoveDownloads = false+ com.music.spotui.data.offline.OfflineCollections.remove(p.uri)+ android.widget.Toast.makeText(context, context.getString(R.string.toast_undownload), android.widget.Toast.LENGTH_SHORT).show()+ }) { Text(stringResource(R.string.playlist_entity_remove_download_dialog_positive_button), color = SpotifyGreen) }+ },+ dismissButton = {+ androidx.compose.material3.TextButton(onClick = { askRemoveDownloads = false }) {+ Text(stringResource(R.string.add_to_playlist_button_cancel), color = Color.White)+ }+ },+ )+ menuSong?.let { sel ->+ com.music.spotui.ui.components.SongOptionsSheet(+ song = sel,+ navController = navController,+ context = context,+ onDismiss = { menuSong = null },+ )+ }++ LazyColumn(modifier = Modifier.fillMaxSize()) {+ item {+ Column(+ modifier = Modifier+ .fillMaxWidth()+ .background(Brush.verticalGradient(listOf(lerp(tint, Color.Black, 0.25f), PageBackground)))+ .statusBarsPadding()+ ) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier+ .padding(12.dp)+ .size(40.dp)+ .clip(CircleShape)+ .background(Color.Black.copy(alpha = 0.35f))+ .clickable { navController.navigateUp() }+ ) {+ Icon(Icons.AutoMirrored.Filled.ArrowBack, contentDescription = stringResource(R.string.accessibility_navigate_back), tint = Color.White)+ }+ Box(contentAlignment = Alignment.Center, modifier = Modifier.fillMaxWidth()) {+ if (p.type == "liked") LikedCover(Modifier.fillMaxWidth(0.66f).aspectRatio(1f).shadow(16.dp, RoundedCornerShape(4.dp))) else+ GlideImage(+ model = p.coverUri,+ contentDescription = "",+ contentScale = ContentScale.Crop,+ modifier = Modifier+ .fillMaxWidth(0.66f)+ .aspectRatio(1f)+ .shadow(16.dp, RoundedCornerShape(4.dp))+ .clip(RoundedCornerShape(4.dp)),+ )+ }+ Spacer(Modifier.height(20.dp))+ Column(modifier = Modifier.padding(horizontal = 16.dp)) {+ Text(p.name, color = Color.White, fontSize = 26.sp, fontWeight = FontWeight.Bold, lineHeight = 30.sp)+ if (p.description.isNotBlank()) {+ Spacer(Modifier.height(8.dp))+ Text(p.description, color = Color.White.copy(alpha = 0.7f), fontSize = 14.sp, maxLines = 3, overflow = TextOverflow.Ellipsis)+ }+ if (p.ownerName.isNotBlank()) {+ Spacer(Modifier.height(10.dp))+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.pressable(0.96f) {+ if (p.ownerUri.startsWith("spotify:artist:")) {+ navController.navigate(artistRoute(p.ownerName.substringBefore(",").trim(), p.ownerUri.substringAfterLast(":")))+ }+ },+ ) {+ if (p.ownerAvatar.isNotBlank()) {+ GlideImage(+ model = p.ownerAvatar,+ contentDescription = "",+ contentScale = ContentScale.Crop,+ modifier = Modifier.size(24.dp).clip(CircleShape),+ )+ Spacer(Modifier.width(8.dp))+ }+ Text(p.ownerName, color = Color.White, fontSize = 14.sp, fontWeight = FontWeight.Bold, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ }+ if (p.metaLine.isNotBlank() || p.explicit) {+ Spacer(Modifier.height(8.dp))+ Row(verticalAlignment = Alignment.CenterVertically) {+ if (p.explicit && p.type == "album") {+ ExplicitBadge()+ Spacer(Modifier.width(6.dp))+ }+ Text(p.metaLine, color = Color.White.copy(alpha = 0.7f), fontSize = 13.sp)+ }+ }+ }+ // Action row: save, shuffle, big green play.+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .padding(start = 16.dp, end = 16.dp, top = 12.dp, bottom = 8.dp)+ ) {+ if (p.type != "liked") {+ GlideImage(+ model = p.coverUri,+ contentDescription = "",+ contentScale = ContentScale.Crop,+ modifier = Modifier.size(width = 30.dp, height = 40.dp).clip(RoundedCornerShape(4.dp)),+ )+ Spacer(Modifier.width(24.dp))+ LikeButton(liked = SongPlayer.library[p.uri] ?: contextSaved, size = 28.dp) { vm.toggleContextSaved(p) }+ Spacer(Modifier.width(20.dp))+ }+ val ids = p.tracks.map { it.spotifyTrackId }.filter { it.isNotBlank() }.distinct()+ // Songs with no matching recording count as settled: the list can still be removed.+ val downloadedCount = ids.count {+ com.music.spotui.data.offline.OfflineStore.isDownloaded(it) ||+ com.music.spotui.data.offline.OfflineStore.status[it] == com.music.spotui.data.offline.OfflineStatus.Unavailable+ }+ val busy = ids.any {+ val st = com.music.spotui.data.offline.OfflineStore.status[it]+ st == com.music.spotui.data.offline.OfflineStatus.Queued || st is com.music.spotui.data.offline.OfflineStatus.Downloading+ }+ // A list downloaded as a whole stays in step with Spotify (new songs in, gone songs out).+ val listKept = com.music.spotui.data.offline.OfflineCollections.isDownloaded(p.uri)+ LaunchedEffect(listKept, p.complete, p.tracks.size) { if (listKept && p.complete) com.music.spotui.data.offline.OfflineCollections.sync(p) }+ com.music.spotui.ui.components.DownloadListButton(downloadedCount, ids.size, busy, kept = listKept) {+ if (listKept) askRemoveDownloads = true+ else {+ com.music.spotui.di.Haptics.confirm()+ com.music.spotui.data.offline.OfflineCollections.download(p)+ android.widget.Toast.makeText(context, context.getString(R.string.download_notification_downloading), android.widget.Toast.LENGTH_SHORT).show()+ }+ }+ Spacer(Modifier.weight(1f))+ Icon(+ painter = painterResource(id = R.drawable.ic_player_shuffle),+ contentDescription = stringResource(R.string.play_mode_item_shuffle_title),+ tint = if (shuffle) SpotifyGreen else Color.White.copy(alpha = 0.8f),+ modifier = Modifier+ .size(26.dp)+ .drawWithContent {+ drawContent()+ if (shuffle) drawCircle(SpotifyGreen, radius = 2.dp.toPx(),+ center = androidx.compose.ui.geometry.Offset(size.width / 2, size.height + 7.dp.toPx()))+ }+ .clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { playerVm.updateShuffleState(!shuffle) },+ )+ Spacer(Modifier.width(20.dp))+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier+ .size(56.dp)+ .pressable(pressedScale = 0.92f) {+ when {+ isThisContext && playing -> SongPlayer.pause()+ isThisContext -> SongPlayer.play()+ p.tracks.isNotEmpty() -> vm.play(p, if (shuffle) p.tracks.random() else p.tracks.first())+ }+ }+ .clip(CircleShape)+ .background(SpotifyGreen),+ ) {+ Icon(+ painter = painterResource(id = if (isThisContext && playing) R.drawable.ic_playing else R.drawable.play_svgrepo_com),+ contentDescription = if (isThisContext && playing) stringResource(R.string.content_description_pause_button) else stringResource(R.string.content_description_play_button),+ tint = Color.Black,+ modifier = Modifier.size(24.dp),+ )+ }+ }+ }+ }+ // Liked Songs: a track unliked anywhere leaves the list right away.+ val all = if (p.type == "liked") p.tracks.filter { SongPlayer.library["spotify:track:${it.spotifyTrackId}"] != false } else p.tracks+ val findable = p.type == "liked" || p.type == "playlist"+ val found = if (findable) all.filter { com.music.spotui.ui.components.matchesFind(find, it.title, it.singer, it.album) } else all+ val rows = if (findable) sort.apply(found) else found+ if (findable && all.isNotEmpty()) item(key = "find") {+ Row(verticalAlignment = Alignment.CenterVertically, modifier = Modifier.padding(start = 16.dp, end = 8.dp, top = 8.dp, bottom = 8.dp)) {+ com.music.spotui.ui.components.FindInListField(+ find, { find = it },+ stringResource(if (p.type == "liked") R.string.find_in_context_edit_text_liked_songs_hint else R.string.find_in_context_edit_text_playlist_hint),+ Modifier.weight(1f),+ )+ TrackSortButton(sort) { sort = it }+ }+ }+ if (rows.isEmpty() && find.isNotBlank()) item(key = "find-empty") {+ com.music.spotui.ui.components.FindInListEmpty(stringResource(R.string.assisted_curation_search_empty_view_no_result_title, find.trim()))+ }+ itemsIndexed(rows, key = { i, s -> "$i:${s.id}" }) { _, song ->+ com.music.spotui.ui.components.SwipeToQueue(song) { TrackRow(+ song = song,+ showCover = p.type != "album",+ isCurrent = song.id == currentSongId,+ saved = SongPlayer.library["spotify:track:${song.spotifyTrackId}"] ?: ("spotify:track:${song.spotifyTrackId}" in saved),+ offline = com.music.spotui.data.offline.OfflineStore.statusOf(song.spotifyTrackId),+ onClick = { vm.play(p, song) },+ onMore = { menuSong = song },+ ) }+ }+ // Phone files added to this Spotify playlist on this phone (Spotify can't hold them).+ if (p.type == "playlist") {+ val playlistId = p.uri.substringAfterLast(":")+ val additions = com.music.spotui.data.local.LocalPlaylists.additions[playlistId].orEmpty()+ if (additions.isNotEmpty()) {+ item {+ Text(stringResource(R.string.local_added_section), color = Color.White, fontSize = 18.sp, fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(16.dp, 20.dp, 16.dp, 4.dp))+ }+ localItems(additions, p.name) { com.music.spotui.data.local.LocalPlaylists.removeFromSpotify(playlistId, it.key) }+ }+ }+ item { Spacer(Modifier.height(160.dp)) }+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun TrackRow(+ song: SongsModel,+ showCover: Boolean,+ isCurrent: Boolean,+ saved: Boolean,+ offline: com.music.spotui.data.offline.OfflineStatus?,+ onClick: () -> Unit,+ onMore: () -> Unit,+) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ horizontalArrangement = Arrangement.Start,+ modifier = Modifier+ .fillMaxWidth()+ .clickable(onClick = onClick)+ .padding(horizontal = 16.dp, vertical = 8.dp)+ ) {+ if (showCover) {+ GlideImage(+ model = song.coverUri,+ contentDescription = "",+ contentScale = ContentScale.Crop,+ modifier = Modifier.size(48.dp),+ )+ Spacer(Modifier.width(12.dp))+ }+ Column(modifier = Modifier.weight(1f)) {+ Text(+ song.title,+ color = if (isCurrent) SpotifyGreen else Color.White,+ fontSize = 16.sp,+ maxLines = 1,+ overflow = TextOverflow.Ellipsis,+ )+ Row(verticalAlignment = Alignment.CenterVertically, modifier = Modifier.padding(top = 2.dp)) {+ if (offline != null) {+ com.music.spotui.ui.components.DownloadBadge(offline, size = 14.dp)+ Spacer(Modifier.width(6.dp))+ }+ if (song.explicit) {+ ExplicitBadge()+ Spacer(Modifier.width(6.dp))+ }+ Text(song.singer, color = Color.White.copy(alpha = 0.7f), fontSize = 14.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ }+ if (saved) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.size(20.dp).clip(CircleShape).background(SpotifyGreen),+ ) {+ Icon(Icons.Default.Check, contentDescription = stringResource(R.string.liked_song), tint = Color.Black, modifier = Modifier.size(14.dp))+ }+ Spacer(Modifier.width(16.dp))+ }+ Icon(+ Icons.Default.MoreVert,+ contentDescription = stringResource(R.string.content_description_context_menu),+ tint = Color.White.copy(alpha = 0.7f),+ modifier = Modifier.pressable(0.96f) { onMore() }+ .size(24.dp)+ ,+ )+ }+}++/** The Liked Songs artwork: purple-to-blue gradient with a white heart. */+@Composable+private fun LikedCover(modifier: Modifier) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = modifier+ .clip(RoundedCornerShape(4.dp))+ .background(Brush.linearGradient(listOf(Color(0xFF450AF5), Color(0xFF8E8EE5), Color(0xFFC4EFD9)))),+ ) {+ Icon(Icons.Default.Favorite, contentDescription = null, tint = Color.White, modifier = Modifier.fillMaxWidth(0.4f).aspectRatio(1f))+ }+}+++/** "Sort by" for the songs of a playlist or Liked Songs; [CUSTOM] is Spotify's own order. */+enum class TrackSort(val label: Int) {+ CUSTOM(R.string.your_library_sort_order_custom),+ TITLE(R.string.track_sort_title),+ ARTIST(R.string.track_sort_artist),+ ALBUM(R.string.track_sort_album),+ DURATION(R.string.track_sort_duration);++ fun apply(songs: List<SongsModel>): List<SongsModel> {+ val text = java.text.Collator.getInstance().apply { strength = java.text.Collator.PRIMARY }+ return when (this) {+ CUSTOM -> songs+ TITLE -> songs.sortedWith { a, b -> text.compare(a.title, b.title) }+ ARTIST -> songs.sortedWith { a, b -> text.compare(a.singer, b.singer).takeIf { it != 0 } ?: text.compare(a.album, b.album) }+ ALBUM -> songs.sortedWith { a, b -> text.compare(a.album, b.album).takeIf { it != 0 } ?: text.compare(a.title, b.title) }+ DURATION -> songs.sortedBy { it.durationMs }+ }+ }+}++@Composable+private fun TrackSortButton(sort: TrackSort, onSort: (TrackSort) -> Unit) {+ var open by remember { mutableStateOf(false) }+ Box {+ androidx.compose.material3.IconButton(onClick = { open = true }) {+ Icon(androidx.compose.material.icons.Icons.Default.SwapVert,+ contentDescription = stringResource(R.string.filter_and_sort_sort_section_title),+ tint = if (sort == TrackSort.CUSTOM) Color.White else SpotifyGreen)+ }+ androidx.compose.material3.DropdownMenu(expanded = open, onDismissRequest = { open = false }, containerColor = Color(0xFF282828)) {+ Text(stringResource(R.string.filter_and_sort_sort_section_title), color = Color(0xFFB3B3B3), fontSize = 13.sp,+ modifier = Modifier.padding(horizontal = 16.dp, vertical = 6.dp))+ TrackSort.entries.forEach { option ->+ androidx.compose.material3.DropdownMenuItem(+ text = { Text(stringResource(option.label), color = if (option == sort) SpotifyGreen else Color.White) },+ onClick = { open = false; onSort(option) },+ )+ }+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/DiscoverScreens.kt b/base/app/src/main/java/com/music/spotui/ui/screens/DiscoverScreens.ktnew file mode 100644index 00000000..d4b27571--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/DiscoverScreens.kt@@ -0,0 +1,240 @@+package com.music.spotui.ui.screens++import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.PaddingValues+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.aspectRatio+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.lazy.grid.GridCells+import androidx.compose.foundation.lazy.grid.GridItemSpan+import androidx.compose.foundation.lazy.grid.LazyVerticalGrid+import androidx.compose.foundation.lazy.grid.items+import androidx.compose.foundation.lazy.items+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.automirrored.filled.ArrowBack+import androidx.compose.material3.CircularProgressIndicator+import androidx.compose.material3.FilterChip+import androidx.compose.material3.FilterChipDefaults+import androidx.compose.material3.Icon+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.produceState+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.res.stringResource+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.navigation.NavController+import app.myspoti.api.best+import app.myspoti.engine.R+import app.myspoti.host.android.MyspotiRuntime+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.music.spotui.data.local.ListenHistory+import com.music.spotui.di.Graph+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.navigation.albumRoute+import com.music.spotui.ui.theme.AppAccent++private val Background = Color(0xFF0E0E13)+private val Subtle = Color(0xFFB3B3B3)++@Composable+private fun ScreenHeader(title: String, navController: NavController) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().padding(8.dp, 12.dp, 16.dp, 8.dp),+ ) {+ Icon(+ imageVector = Icons.AutoMirrored.Filled.ArrowBack,+ contentDescription = stringResource(R.string.accessibility_navigate_back),+ tint = Color.White,+ modifier = Modifier.size(40.dp).clip(RoundedCornerShape(20.dp)).clickable { navController.popBackStack() }.padding(8.dp),+ )+ Text(title, fontWeight = FontWeight.Bold, color = Color.White, fontSize = 22.sp, maxLines = 1,+ overflow = TextOverflow.Ellipsis, modifier = Modifier.padding(start = 6.dp))+ }+}++@Composable+private fun Loading() = Box(Modifier.fillMaxWidth().padding(40.dp), contentAlignment = Alignment.Center) {+ CircularProgressIndicator(color = AppAccent)+}++@Composable+private fun SectionTitle(text: String) =+ Text(text, color = Color.White, fontSize = 20.sp, fontWeight = FontWeight.Bold, modifier = Modifier.padding(16.dp, 18.dp, 16.dp, 8.dp))++private data class ReleaseTile(val id: String, val name: String, val artists: String, val cover: String, val detail: String)++/** "New releases": what the followed artists just released, then the latest albums Spotify features. */+@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun NewReleasesScreen(navController: NavController) {+ val followed by produceState<List<ReleaseTile>?>(null) {+ value = runCatching {+ MyspotiRuntime.api.home.whatsNew(0, 50).items.map { a ->+ ReleaseTile(a.uri.substringAfterLast(':'), a.name, a.artists.joinToString(", ") { it.name },+ a.images.best(300)?.url.orEmpty(), listOfNotNull(a.type.lowercase().replaceFirstChar { it.uppercase() }, a.releaseDate?.take(10)).joinToString(" • "))+ }+ }.getOrDefault(emptyList())+ }+ val latest by produceState<List<ReleaseTile>?>(null) {+ value = runCatching {+ Graph.api.newReleases().map { ReleaseTile(it.spotifyId, it.name, it.artists, it.coverUri, it.artists) }+ }.getOrDefault(emptyList())+ }+ Column(Modifier.fillMaxSize().background(Background).statusBarsPadding()) {+ ScreenHeader(stringResource(R.string.browse_new_releases), navController)+ LazyVerticalGrid(+ columns = GridCells.Fixed(2),+ contentPadding = PaddingValues(12.dp, 0.dp, 12.dp, 130.dp),+ horizontalArrangement = Arrangement.spacedBy(12.dp),+ verticalArrangement = Arrangement.spacedBy(16.dp),+ modifier = Modifier.fillMaxSize(),+ ) {+ fun section(title: Int, list: List<ReleaseTile>?) {+ item(span = { GridItemSpan(2) }) { SectionTitle(stringResource(title)) }+ when {+ list == null -> item(span = { GridItemSpan(2) }) { Loading() }+ list.isEmpty() -> item(span = { GridItemSpan(2) }) {+ Text(stringResource(R.string.nothing_here), color = Subtle, fontSize = 14.sp, modifier = Modifier.padding(16.dp, 4.dp))+ }+ else -> items(list, key = { "$title:${it.id}" }) { t ->+ Column(Modifier.clickable { navController.navigate(albumRoute(t.name, t.artists, t.id)) }) {+ GlideImage(model = t.cover, contentDescription = null, contentScale = ContentScale.Crop,+ modifier = Modifier.fillMaxWidth().aspectRatio(1f).clip(RoundedCornerShape(6.dp)))+ Text(t.name, color = Color.White, fontSize = 13.sp, fontWeight = FontWeight.Bold, maxLines = 2,+ overflow = TextOverflow.Ellipsis, modifier = Modifier.padding(top = 6.dp))+ Text(t.detail.ifBlank { t.artists }, color = Color.Gray, fontSize = 11.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ }+ }+ }+ section(R.string.new_releases_followed, followed)+ section(R.string.new_releases_latest, latest)+ }+ }+}++/** "Your Episodes": saved podcast episodes, newest first, playable in place. */+@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun EpisodesScreen(navController: NavController) {+ val episodes by produceState<List<com.music.spotui.data.entity.SongsModel>?>(null) { value = Graph.api.getSavedEpisodes() }+ Column(Modifier.fillMaxSize().background(Background).statusBarsPadding()) {+ ScreenHeader(stringResource(R.string.your_episodes_title), navController)+ when (val list = episodes) {+ null -> Loading()+ else -> if (list.isEmpty()) Text(stringResource(R.string.your_episodes_empty), color = Subtle, fontSize = 14.sp, modifier = Modifier.padding(20.dp))+ else LazyColumn(contentPadding = PaddingValues(bottom = 130.dp)) {+ items(list, key = { it.url }) { e ->+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().clickable {+ SongPlayer.registerContext(list.map { it.url }, "spotify:collection:your-episodes")+ SongPlayer.playSong(e.url)+ }.padding(16.dp, 8.dp),+ ) {+ GlideImage(model = e.coverUri, contentDescription = null, contentScale = ContentScale.Crop,+ modifier = Modifier.size(56.dp).clip(RoundedCornerShape(6.dp)))+ Column(Modifier.padding(start = 12.dp).weight(1f)) {+ Text(e.title, color = Color.White, fontSize = 15.sp, maxLines = 2, overflow = TextOverflow.Ellipsis)+ Text(e.singer + " • " + formatMinutes(e.durationMs / 60_000L), color = Subtle, fontSize = 12.sp, maxLines = 1)+ }+ }+ }+ }+ }+ }+}++@Composable+private fun formatMinutes(min: Long) = if (min >= 60) "${min / 60} h ${min % 60} min" else "$min min"++/**+ * The in-app recap: listens on this phone from Spotify, downloads and local files. Spotify's own+ * Wrapped only counts what Spotify streamed; this one counts everything, and stays on the phone.+ */+@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun RecapScreen(navController: NavController) {+ val periods = listOf(R.string.recap_month to 30L, R.string.recap_year to 365L, R.string.recap_all to 36_500L)+ var period by remember { mutableStateOf(1) }+ val recap = remember(period) {+ ListenHistory.recap(System.currentTimeMillis() - periods[period].second * 86_400_000L)+ }+ Column(Modifier.fillMaxSize().background(Background).statusBarsPadding()) {+ ScreenHeader(stringResource(R.string.recap_title), navController)+ LazyColumn(contentPadding = PaddingValues(bottom = 130.dp)) {+ item {+ Row(Modifier.padding(horizontal = 16.dp), horizontalArrangement = Arrangement.spacedBy(8.dp)) {+ periods.forEachIndexed { i, (label, _) ->+ FilterChip(selected = i == period, onClick = { period = i }, label = { Text(stringResource(label)) },+ colors = FilterChipDefaults.filterChipColors(selectedContainerColor = AppAccent, selectedLabelColor = Color.Black,+ labelColor = Color.White, containerColor = Color(0xFF2A2A2A)))+ }+ }+ }+ item {+ Column(Modifier.padding(16.dp, 20.dp)) {+ Text(stringResource(R.string.recap_minutes, recap.minutes), color = Color.White, fontSize = 30.sp, fontWeight = FontWeight.Bold)+ Text(stringResource(R.string.recap_listens, recap.listens), color = Subtle, fontSize = 14.sp)+ Spacer(Modifier.height(10.dp))+ val src = recap.bySource+ Text(stringResource(R.string.recap_sources,+ src[ListenHistory.Source.SPOTIFY] ?: 0, src[ListenHistory.Source.DOWNLOAD] ?: 0, src[ListenHistory.Source.LOCAL] ?: 0),+ color = Subtle, fontSize = 13.sp)+ }+ }+ if (recap.listens == 0) item {+ Text(stringResource(R.string.recap_empty), color = Subtle, fontSize = 14.sp, modifier = Modifier.padding(16.dp))+ }+ fun ranked(title: Int, list: List<ListenHistory.Ranked>) {+ if (list.isEmpty()) return+ item { SectionTitle(stringResource(title)) }+ items(list.size) { i ->+ val r = list[i]+ Row(verticalAlignment = Alignment.CenterVertically, modifier = Modifier.fillMaxWidth().padding(16.dp, 6.dp)) {+ Text("${i + 1}", color = Subtle, fontSize = 16.sp, modifier = Modifier.width(28.dp))+ GlideImage(model = r.cover, contentDescription = null, contentScale = ContentScale.Crop,+ modifier = Modifier.size(48.dp).clip(RoundedCornerShape(4.dp)))+ Column(Modifier.padding(start = 12.dp).weight(1f)) {+ Text(r.name, color = Color.White, fontSize = 15.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ Text(listOf(r.subtitle, stringResource(R.string.recap_plays, r.count)).filter { it.isNotBlank() }.joinToString(" • "),+ color = Subtle, fontSize = 12.sp, maxLines = 1)+ }+ }+ }+ }+ ranked(R.string.recap_top_tracks, recap.topTracks)+ ranked(R.string.recap_top_artists, recap.topArtists)+ ranked(R.string.recap_top_albums, recap.topAlbums)+ item {+ Text(stringResource(R.string.recap_private_note), color = Color(0xFF7A7A7A), fontSize = 12.sp, modifier = Modifier.padding(16.dp, 24.dp))+ }+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/DownloadsScreen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/DownloadsScreen.ktnew file mode 100644index 00000000..a279eded--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/DownloadsScreen.kt@@ -0,0 +1,201 @@+package com.music.spotui.ui.screens++import android.text.format.Formatter+import androidx.compose.foundation.Image+import androidx.compose.foundation.background+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.lazy.items+import androidx.compose.foundation.lazy.itemsIndexed+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.automirrored.filled.ArrowBack+import androidx.compose.material.icons.filled.Close+import androidx.compose.material.icons.filled.MoreVert+import androidx.compose.material3.Icon+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Brush+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.res.pluralStringResource+import androidx.compose.ui.res.stringResource+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextAlign+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.navigation.NavController+import app.myspoti.engine.R+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.bumptech.glide.integration.compose.placeholder+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.data.offline.OfflineDownloader+import com.music.spotui.data.offline.OfflineStatus+import com.music.spotui.data.offline.OfflineStore+import com.music.spotui.di.LocalPlayer+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.components.DownloadBadge+import com.music.spotui.ui.components.pressable+import com.music.spotui.ui.theme.AppBackground++/** "Downloaded": songs kept for offline listening, played from the phone by [LocalPlayer]. */+@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun DownloadsScreen(navController: NavController) {+ val context = LocalContext.current+ val title = stringResource(R.string.collection_downloaded)+ // Snapshot reads: the list follows downloads as they finish.+ val tracks = OfflineStore.tracks.values.sortedByDescending { it.addedAt }+ val waiting = OfflineDownloader.requests.values.filter { !OfflineStore.isDownloaded(it.trackId) }+ val np by SongPlayer.nowPlaying+ val playingHere = LocalPlayer.active.value && LocalPlayer.contextName == title+ var menuSong by remember { mutableStateOf<SongsModel?>(null) }+ menuSong?.let { sel ->+ com.music.spotui.ui.components.SongOptionsSheet(song = sel, navController = navController, context = context, onDismiss = { menuSong = null })+ }+ fun play(index: Int, shuffle: Boolean = false) {+ if (tracks.isEmpty()) return+ LocalPlayer.play(tracks.map(OfflineStore::toLocalTrack), index, shuffle = shuffle, context = title)+ }++ Box(Modifier.fillMaxSize().background(AppBackground)) {+ if (tracks.isEmpty() && waiting.isEmpty()) Column(+ horizontalAlignment = Alignment.CenterHorizontally,+ verticalArrangement = Arrangement.Center,+ modifier = Modifier.fillMaxSize().padding(horizontal = 32.dp),+ ) {+ Image(painterResource(R.drawable.downloads_cover), null, modifier = Modifier.size(120.dp).clip(RoundedCornerShape(6.dp)))+ Text(stringResource(R.string.downloads_empty_title), color = Color.White, fontSize = 22.sp, fontWeight = FontWeight.Bold,+ textAlign = TextAlign.Center, modifier = Modifier.padding(top = 24.dp))+ Text(stringResource(R.string.downloads_empty_subtitle), color = Color(0xFFB3B3B3), fontSize = 14.sp,+ textAlign = TextAlign.Center, modifier = Modifier.padding(top = 8.dp))+ } else LazyColumn(Modifier.fillMaxSize()) {+ item {+ Column(+ Modifier.fillMaxWidth().background(Brush.verticalGradient(listOf(Color(0xFF1D6B45), AppBackground)))+ .statusBarsPadding().padding(horizontal = 16.dp),+ ) {+ Spacer(Modifier.height(56.dp))+ Image(+ painterResource(R.drawable.downloads_cover), null,+ modifier = Modifier.align(Alignment.CenterHorizontally).size(200.dp).clip(RoundedCornerShape(6.dp)),+ )+ Text(title, color = Color.White, fontSize = 26.sp, fontWeight = FontWeight.Bold, modifier = Modifier.padding(top = 20.dp))+ val n = tracks.size+ val size = Formatter.formatShortFileSize(context, OfflineStore.totalBytes())+ Text(pluralStringResource(R.plurals.local_files_count, n, n) + " · " + stringResource(R.string.downloads_size, size),+ color = Color(0xFFB3B3B3), fontSize = 14.sp, modifier = Modifier.padding(top = 4.dp))+ Text(stringResource(R.string.downloads_source), color = Color(0xFFB3B3B3), fontSize = 12.sp, modifier = Modifier.padding(top = 4.dp))+ Row(Modifier.fillMaxWidth().padding(vertical = 12.dp), verticalAlignment = Alignment.CenterVertically) {+ Spacer(Modifier.weight(1f))+ Icon(painterResource(R.drawable.ic_player_shuffle), stringResource(R.string.play_mode_item_shuffle_title), tint = Color.White,+ modifier = Modifier.size(28.dp).pressable { if (tracks.isNotEmpty()) play(tracks.indices.random(), shuffle = true) })+ Spacer(Modifier.width(20.dp))+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.size(56.dp)+ .pressable(0.92f) {+ when {+ playingHere && SongPlayer.isPlaying() -> SongPlayer.pause()+ playingHere -> SongPlayer.play()+ else -> play(0)+ }+ }+ .clip(CircleShape).background(com.music.spotui.ui.theme.AppAccent),+ ) {+ Icon(painterResource(if (playingHere && SongPlayer.isPlaying()) R.drawable.ic_playing else R.drawable.play_svgrepo_com),+ stringResource(R.string.content_description_play_button), tint = Color.Black, modifier = Modifier.size(26.dp))+ }+ }+ }+ }+ // Songs still on their way (or that could not be downloaded).+ items(waiting, key = { "w:" + it.trackId }) { r ->+ val status = OfflineStore.status[r.trackId]+ val problem = status == OfflineStatus.Failed || status == OfflineStatus.Unavailable+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth()+ .pressable(0.97f) { if (status == OfflineStatus.Failed) OfflineDownloader.retry(r.trackId) }+ .padding(horizontal = 16.dp, vertical = 8.dp),+ ) {+ GlideImage(+ model = r.coverUrl, contentDescription = null, contentScale = ContentScale.Crop,+ loading = placeholder(R.drawable.placeholder), failure = placeholder(R.drawable.placeholder),+ modifier = Modifier.size(48.dp).clip(RoundedCornerShape(4.dp)),+ )+ Column(Modifier.padding(start = 12.dp).weight(1f)) {+ Text(r.title, color = Color.White.copy(alpha = 0.6f), fontSize = 15.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ val line = when (status) {+ OfflineStatus.Unavailable -> stringResource(R.string.download_unavailable)+ OfflineStatus.Failed -> stringResource(R.string.download_badge_error_content_description) + " · " + stringResource(R.string.download_retry)+ else -> stringResource(R.string.download_notification_downloading)+ }+ Text(line, color = if (problem) Color(0xFFE22134) else Color(0xFFB3B3B3), fontSize = 13.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ DownloadBadge(status, size = 20.dp)+ Spacer(Modifier.width(16.dp))+ Icon(Icons.Default.Close, stringResource(R.string.download_cancel), tint = Color.White.copy(alpha = 0.7f),+ modifier = Modifier.size(24.dp).pressable(0.96f) { OfflineDownloader.cancel(r.trackId) })+ }+ }+ itemsIndexed(tracks, key = { _, t -> t.trackId }) { i, t ->+ val current = LocalPlayer.active.value && np.uri == "local:${OfflineStore.localIdOf(t.trackId)}"+ com.music.spotui.ui.components.SwipeToRemove(t.trackId, onRemove = {+ val gone = com.music.spotui.data.offline.OfflineCollections.removeSong(t.trackId)+ android.widget.Toast.makeText(context, context.getString(if (gone) R.string.toast_undownload else R.string.download_kept_by_list), android.widget.Toast.LENGTH_SHORT).show()+ }) { Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().pressable(0.97f) { play(i) }.padding(horizontal = 16.dp, vertical = 8.dp),+ ) {+ GlideImage(+ model = OfflineStore.coverFile(t) ?: t.coverUrl, contentDescription = null, contentScale = ContentScale.Crop,+ loading = placeholder(R.drawable.placeholder), failure = placeholder(R.drawable.downloads_cover),+ modifier = Modifier.size(48.dp).clip(RoundedCornerShape(4.dp)),+ )+ Column(Modifier.padding(start = 12.dp).weight(1f)) {+ Text(t.title, color = if (current) com.music.spotui.ui.theme.AppAccent else Color.White, fontSize = 15.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ Row(verticalAlignment = Alignment.CenterVertically) {+ DownloadBadge(OfflineStatus.Done, size = 14.dp)+ Spacer(Modifier.width(6.dp))+ Text(t.artist, color = Color(0xFFB3B3B3), fontSize = 13.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ }+ Icon(Icons.Default.MoreVert, stringResource(R.string.content_description_context_menu), tint = Color.White.copy(alpha = 0.7f),+ modifier = Modifier.size(24.dp).pressable(0.96f) { menuSong = OfflineStore.toSong(t) })+ } }+ }+ item { Spacer(Modifier.height(140.dp)) }+ }+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.statusBarsPadding().padding(12.dp).size(40.dp).clip(CircleShape)+ .background(Color(0x66000000)).pressable { navController.navigateUp() },+ ) {+ Icon(Icons.AutoMirrored.Filled.ArrowBack, stringResource(R.string.accessibility_navigate_back), tint = Color.White)+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/HomeScreen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/HomeScreen.ktnew file mode 100644index 00000000..845a7699--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/HomeScreen.kt@@ -0,0 +1,636 @@+package com.music.spotui.ui.screens++import com.music.spotui.ui.components.SkeletonKind+import com.music.spotui.ui.components.pressable++import androidx.compose.ui.res.stringResource++import androidx.compose.foundation.layout.windowInsetsPadding+import androidx.compose.foundation.layout.navigationBars+import androidx.compose.foundation.horizontalScroll+import androidx.compose.ui.platform.LocalContext+import kotlinx.coroutines.launch+import android.os.Build+import android.util.Log+import androidx.annotation.RequiresApi+import androidx.compose.foundation.Image+import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.PaddingValues+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.lazy.LazyRow+import androidx.compose.foundation.rememberScrollState+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.foundation.verticalScroll+import androidx.compose.material3.Card+import androidx.compose.material3.CardDefaults+import androidx.compose.material3.MaterialTheme+import androidx.compose.material3.Surface+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.lifecycle.compose.collectAsStateWithLifecycle+import androidx.compose.foundation.selection.toggleable+import androidx.compose.ui.semantics.Role+import androidx.compose.foundation.layout.heightIn+import androidx.compose.runtime.collectAsState+import androidx.compose.runtime.getValue+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Brush+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.toArgb+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.res.painterResource+import androidx.compose.material.icons.filled.Check+import androidx.compose.ui.text.TextStyle+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextAlign+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.lifecycle.viewmodel.compose.viewModel+import androidx.navigation.NavController+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.bumptech.glide.integration.compose.placeholder+import app.myspoti.engine.R+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.AlbumsModel+import com.music.spotui.data.entity.ArtistsModel+import com.music.spotui.data.entity.HomeFeedModel+import com.music.spotui.data.entity.HomeItem+import com.music.spotui.data.entity.HomeSection+import com.music.spotui.ui.components.Loader+import com.music.spotui.ui.navigation.Routes+import com.music.spotui.ui.navigation.albumRoute+import com.music.spotui.ui.navigation.artistRoute+import com.music.spotui.ui.navigation.playlistRoute+import com.music.spotui.ui.theme.AppBackground+import com.music.spotui.ui.theme.AppPalette+import com.music.spotui.ui.theme.GridBackground+import com.music.spotui.ui.viewmodel.HomeViewModel+import java.time.LocalTime+++@RequiresApi(Build.VERSION_CODES.O)+@Composable+fun HomeScreen(navController: NavController){++ val homeViewModel : HomeViewModel = viewModel()+ val home by homeViewModel.home.collectAsState()++ Surface(+ modifier = Modifier+ .fillMaxSize()+ .background(Color(AppBackground.toArgb()))+ ) {+ val feed = (home as? Response.Success)?.data++ when {+ // Preferred: the real personalized Spotify home feed.+ feed != null && feed.sections.isNotEmpty() -> {+ HomeFeedContent(navController, feed, homeViewModel.facet.value) { homeViewModel.selectFacet(it) }+ }++ // No feed to show (loading, empty chip, error): keep the chips on screen+ // so the user can always switch back to "Tout".+ else -> androidx.compose.foundation.layout.Column(modifier = Modifier.fillMaxSize().statusBarsPadding()) {+ HomeHeaderRow(navController, homeViewModel.facet.value) { homeViewModel.selectFacet(it) }+ Box(modifier = Modifier.weight(1f).fillMaxWidth(), contentAlignment = Alignment.Center) {+ when {+ home is Response.Loading -> Loader(SkeletonKind.Home)+ else -> Text(+ text = if (home is Response.Error) stringResource(R.string.home_error) else stringResource(R.string.home_empty),+ color = Color.White,+ textAlign = TextAlign.Center,+ )+ }+ }+ }+ }+ }+}++/** Albums and playlists start loading under the finger (see pressHint). */+private fun prefetchHomeItem(item: HomeItem) {+ when (item) {+ is HomeItem.Album -> if (item.id.isNotBlank()) ContextViewModel.prefetch("album", item.id)+ is HomeItem.Playlist -> if (item.id.isNotBlank()) ContextViewModel.prefetch("playlist", item.id)+ else -> {}+ }+}++private fun onHomeItemClick(navController: NavController, item: HomeItem) {+ when (item) {+ is HomeItem.Album -> navController.navigate(albumRoute(item.name, item.artists.ifBlank { item.subtitle }, item.id))+ is HomeItem.Artist -> navController.navigate(artistRoute(item.name, item.id))+ is HomeItem.Show ->+ if (item.isEpisode) com.music.spotui.di.SongPlayer.playSong("episode:${item.id}")+ else navController.navigate(com.music.spotui.ui.navigation.showRoute(item.id, item.name))+ // Load the real playlist content by its Spotify id (daily mixes, etc).+ is HomeItem.Playlist ->+ if (item.id.isNotBlank()) navController.navigate(playlistRoute(item.id, item.name))+ else navController.navigate(albumRoute(item.name))+ }+}++@RequiresApi(Build.VERSION_CODES.O)+@Composable+@OptIn(androidx.compose.foundation.ExperimentalFoundationApi::class)+fun HomeFeedContent(navController: NavController, feed: HomeFeedModel, facet: String = "", onFacet: (String) -> Unit = {}) {+ // Mirror open.spotify.com exactly: sections render in the order the feed+ // returns them. The 2-column "shortcuts" grid is only used for the UNTITLED+ // section the web home starts with — if the feed leads with a titled section+ // ("Jump back in", "Made For …"), it renders as a titled carousel first,+ // not force-squeezed into the grid.+ // Podcasts are off for now: their shows and episodes leave the feed.+ val sections = if (com.music.spotui.data.api.Features.PODCASTS) feed.sections+ else feed.sections.map { s -> s.copy(items = s.items.filterNot { it is HomeItem.Show }) }.filter { it.items.isNotEmpty() }+ val gridSection = sections.firstOrNull()?.takeIf { it.title.isBlank() }+ val carousels = if (gridSection != null) sections.drop(1) else sections++ LazyColumn(+ contentPadding = PaddingValues(bottom = 130.dp),+ modifier = Modifier+ .fillMaxSize()+ .background(Color(AppBackground.toArgb()))+ ) {+ // Sticky filter row: content scrolls underneath it, like the official app.+ stickyHeader {+ // Fade (not a solid band): opaque under the status bar, transparent at the bottom.+ Box(+ modifier = Modifier+ .fillMaxWidth()+ .background(+ Brush.verticalGradient(+ 0f to Color(AppBackground.toArgb()),+ 0.55f to Color(AppBackground.toArgb()).copy(alpha = 0.85f),+ 1f to Color.Transparent,+ )+ )+ .statusBarsPadding()+ .padding(bottom = 10.dp)+ ) {+ HomeHeaderRow(navController, facet, onFacet)+ }+ }+ gridSection?.let { section ->+ item {+ HomeShortcutGrid(navController, section.items.take(8))+ }+ }+ items(carousels.size) { i ->+ HomeFeedSection(navController, carousels[i])+ }+ }+}++/** Spotify-style top row: profile avatar on the left (opens Settings, like the+ * official app's profile drawer), then the filter pills — one single row. */+@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun HomeHeaderRow(navController: NavController, facet: String, onFacet: (String) -> Unit) {+ var showProfile by remember { androidx.compose.runtime.mutableStateOf(false) }+ if (showProfile) ProfileSheet(onOpen = { route -> showProfile = false; navController.navigate(route) }) { showProfile = false }+ val context = androidx.compose.ui.platform.LocalContext.current+ androidx.compose.runtime.LaunchedEffect(Unit) {+ com.music.spotui.data.api.ProfileCache.ensure(context)+ }+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .padding(top = 10.dp, bottom = 10.dp),+ ) {+ val avatarUrl = com.music.spotui.data.api.ProfileCache.imageUrl+ val initial = com.music.spotui.data.api.ProfileCache.name+ ?.trim()?.firstOrNull()?.uppercase() ?: "•"+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier+ .padding(start = 16.dp)+ .size(34.dp)+ .clip(CircleShape)+ .background(Color(0xFFE8622C))+ .clickable { showProfile = true },+ ) {+ if (avatarUrl != null) {+ GlideImage(+ model = avatarUrl,+ contentScale = ContentScale.Crop,+ contentDescription = stringResource(R.string.recently_played_user_profile),+ modifier = Modifier.size(34.dp),+ )+ } else {+ Text(+ text = initial,+ color = Color.Black,+ fontSize = 15.sp,+ fontWeight = FontWeight.Bold,+ )+ }+ }+ // Scrolls sideways if the pills don't fit, like Spotify's.+ Row(+ horizontalArrangement = Arrangement.spacedBy(8.dp),+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .weight(1f)+ .horizontalScroll(androidx.compose.foundation.rememberScrollState())+ .padding(start = 12.dp, end = 8.dp),+ ) {+ // Spotify's home chips; tapping the selected one goes back to "Tout".+ HomePill(stringResource(R.string.filter_chip_all_label), selected = facet.isEmpty()) { onFacet("") }+ HomePill(stringResource(R.string.recents_content_filter_music), selected = facet == "music-chip") { onFacet("music-chip") }+ if (com.music.spotui.data.api.Features.PODCASTS) {+ HomePill(stringResource(R.string.ad_category_title_podcasts), selected = facet == "podcasts-chip") { onFacet("podcasts-chip") }+ HomePill(stringResource(R.string.audiobooks_title), selected = facet == "audiobooks-chip") { onFacet("audiobooks-chip") }+ }+ }+ }+}++@Composable+private fun HomePill(label: String, selected: Boolean = false, onClick: () -> Unit) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier+ .clip(RoundedCornerShape(50))+ .background(if (selected) com.music.spotui.ui.theme.AppAccent else Color(0xFF2A2A2A))+ .clickable(onClick = onClick)+ .padding(horizontal = 16.dp, vertical = 8.dp),+ ) {+ Text(text = label, color = if (selected) Color.Black else Color.White, fontSize = 14.sp, fontWeight = FontWeight.Bold)+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun HomeShortcutGrid(navController: NavController, items: List<HomeItem>) {+ Column(modifier = Modifier.padding(8.dp, 4.dp)) {+ items.chunked(2).forEach { rowItems ->+ Row(+ horizontalArrangement = Arrangement.spacedBy(8.dp),+ modifier = Modifier+ .fillMaxWidth()+ .padding(8.dp, 4.dp),+ ) {+ rowItems.forEach { item ->+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.pressable(0.96f, onPressHint = { prefetchHomeItem(item) }) { onHomeItemClick(navController, item) }+ .weight(1f)+ .height(48.dp)+ .clip(RoundedCornerShape(4.dp))+ .background(Color(GridBackground.toArgb()))+ ,+ ) {+ GlideImage(+ modifier = Modifier.size(48.dp),+ contentScale = ContentScale.Crop,+ model = item.imageUrl,+ loading = placeholder(R.drawable.placeholder),+ failure = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Text(+ text = item.name,+ color = Color.White,+ fontSize = 12.sp,+ fontWeight = FontWeight.Bold,+ maxLines = 2,+ modifier = Modifier.padding(8.dp, 4.dp),+ )+ }+ }+ if (rowItems.size == 1) Spacer(modifier = Modifier.weight(1f))+ }+ }+ }+}++@Composable+private fun HomeFeedSection(navController: NavController, section: HomeSection) {+ Text(+ text = section.title,+ color = Color.White,+ fontSize = 21.sp,+ fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(16.dp, 20.dp, 16.dp, 4.dp),+ )+ LazyRow(contentPadding = androidx.compose.foundation.layout.PaddingValues(10.dp, 0.dp)) {+ items(section.items.size) { i ->+ HomeFeedCard(section.items[i]) { onHomeItemClick(navController, section.items[i]) }+ }+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun HomeFeedCard(item: HomeItem, onClick: () -> Unit) {+ val isArtist = item is HomeItem.Artist+ val subtitle = when (item) {+ is HomeItem.Album -> item.subtitle+ is HomeItem.Playlist -> item.subtitle+ is HomeItem.Artist -> stringResource(R.string.artist_subtitle)+ is HomeItem.Show -> item.subtitle+ }+ Column(+ horizontalAlignment = if (isArtist) Alignment.CenterHorizontally else Alignment.Start,+ modifier = Modifier.pressable(0.96f, onPressHint = { prefetchHomeItem(item) }) { onClick() }+ .width(150.dp)+ .padding(6.dp)+ ,+ ) {+ GlideImage(+ modifier = Modifier+ .size(150.dp)+ .clip(if (isArtist) CircleShape else RoundedCornerShape(8.dp)),+ contentScale = ContentScale.Crop,+ model = item.imageUrl,+ loading = placeholder(R.drawable.placeholder),+ failure = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Spacer(modifier = Modifier.height(6.dp))+ Text(+ text = item.name,+ color = Color.White,+ fontSize = 13.sp,+ fontWeight = FontWeight.SemiBold,+ maxLines = 1,+ textAlign = if (isArtist) TextAlign.Center else TextAlign.Start,+ )+ Text(+ text = subtitle,+ color = Color(0xFFB3B3B3),+ fontSize = 11.sp,+ maxLines = 2,+ textAlign = if (isArtist) TextAlign.Center else TextAlign.Start,+ )+ }+}++/** Profile sheet behind the avatar: account name and sign-out (in the Web Player). */+@OptIn(androidx.compose.material3.ExperimentalMaterial3Api::class, ExperimentalGlideComposeApi::class)+@Composable+private fun ProfileSheet(onOpen: (route: String) -> Unit = {}, onDismiss: () -> Unit) {+ val energy by app.myspoti.power.EnergySettings.state.collectAsStateWithLifecycle()+ val name = com.music.spotui.data.api.ProfileCache.name.orEmpty()+ val avatar = com.music.spotui.data.api.ProfileCache.imageUrl+ // Opened in full: half-open, the sheet and its list both moved under the finger.+ androidx.compose.material3.ModalBottomSheet(onDismissRequest = onDismiss, containerColor = Color(0xFF282828),+ sheetState = androidx.compose.material3.rememberModalBottomSheetState(skipPartiallyExpanded = true)) {+ androidx.compose.foundation.layout.Column(+ modifier = Modifier.fillMaxWidth().then(Modifier.windowInsetsPadding(androidx.compose.foundation.layout.WindowInsets.navigationBars))+ .verticalScroll(androidx.compose.foundation.rememberScrollState()).padding(bottom = 16.dp),+ ) {+ Row(verticalAlignment = Alignment.CenterVertically, modifier = Modifier.padding(horizontal = 20.dp, vertical = 8.dp)) {+ if (avatar != null) GlideImage(+ model = avatar, contentDescription = null, contentScale = ContentScale.Crop,+ modifier = Modifier.size(48.dp).clip(CircleShape),+ )+ Text(name.ifBlank { stringResource(R.string.spotify_account) }, color = Color.White, fontSize = 18.sp, fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(start = 14.dp))+ if (com.music.spotui.data.api.SupportReminder.level != com.music.spotui.data.api.SupportReminder.Level.NONE)+ com.music.spotui.ui.components.SupporterBadge(Modifier.padding(start = 10.dp))+ }+ androidx.compose.material3.HorizontalDivider(color = Color(0xFF3E3E3E), modifier = Modifier.padding(vertical = 8.dp))+ EnergyOptionRow(+ label = stringResource(R.string.energy_saver_title),+ detail = stringResource(R.string.energy_saver_summary),+ checked = energy.manualSaver,+ onChecked = app.myspoti.power.EnergySettings::setSaver,+ )+ EnergyOptionRow(+ label = stringResource(R.string.data_saver_title),+ detail = stringResource(R.string.data_saver_summary),+ checked = com.music.spotui.data.DataSaver.enabled,+ onChecked = com.music.spotui.data.DataSaver::set,+ )+ EnergyOptionRow(+ label = stringResource(R.string.settings_amoled_theme),+ detail = stringResource(R.string.settings_amoled_theme_subtitle),+ checked = energy.blackPreference,+ onChecked = app.myspoti.power.EnergySettings::setBlackBackground,+ )+ EnergyOptionRow(+ label = stringResource(R.string.settings_item_canvas_title),+ detail = stringResource(if (energy.policy.saverEnabled) R.string.energy_saver_summary else R.string.video_settings_canvas_subtitle),+ checked = energy.canvasEnabled && !energy.policy.saverEnabled,+ enabled = !energy.policy.saverEnabled,+ onChecked = app.myspoti.power.EnergySettings::setCanvasEnabled,+ )+ // In-app recap: every listen on this phone, Spotify, downloads and local files.+ androidx.compose.foundation.layout.Column(+ Modifier.fillMaxWidth().clickable { onOpen(com.music.spotui.ui.navigation.Routes.Recap.route) }+ .padding(horizontal = 20.dp, vertical = 10.dp),+ ) {+ Text(stringResource(R.string.recap_title), color = Color.White, fontSize = 16.sp)+ Text(stringResource(R.string.recap_detail), color = Color(0xFFB3B3B3), fontSize = 12.sp)+ }+ // The Spotify account page (plan, privacy, devices), in the app's signed-in browser.+ androidx.compose.foundation.layout.Column(+ Modifier.fillMaxWidth().clickable {+ onDismiss()+ com.music.spotui.ui.screens.AccountBrowser.open(com.music.spotui.di.Graph.app, com.music.spotui.ui.screens.AccountBrowser.ACCOUNT_URL)+ }.padding(horizontal = 20.dp, vertical = 10.dp),+ ) {+ Text(stringResource(R.string.account_page_title), color = Color.White, fontSize = 16.sp)+ Text(stringResource(R.string.account_page_detail), color = Color(0xFFB3B3B3), fontSize = 12.sp)+ }+ LanguageRow()+ // Battery optimization off = music and Connect keep going with the screen off.+ val ctx = androidx.compose.ui.platform.LocalContext.current+ var exempt by remember { androidx.compose.runtime.mutableStateOf(app.myspoti.power.BatteryExemption.isExempt(ctx)) }+ androidx.lifecycle.compose.LifecycleEventEffect(androidx.lifecycle.Lifecycle.Event.ON_RESUME) {+ exempt = app.myspoti.power.BatteryExemption.isExempt(ctx)+ }+ EnergyOptionRow(+ label = stringResource(R.string.background_playback_title),+ detail = stringResource(if (exempt) R.string.background_playback_on else R.string.background_playback_off),+ checked = exempt,+ onChecked = {+ if (exempt) ctx.startActivity(android.content.Intent(android.provider.Settings.ACTION_IGNORE_BATTERY_OPTIMIZATION_SETTINGS))+ else app.myspoti.power.BatteryExemption.request(ctx)+ },+ )+ // The hidden Web Player stuck or crashed: rebuild it without leaving the app.+ androidx.compose.foundation.layout.Column(+ Modifier.fillMaxWidth().clickable {+ onDismiss()+ app.myspoti.host.android.MyspotiRuntime.host.reload()+ }.padding(horizontal = 20.dp, vertical = 10.dp),+ ) {+ Text(stringResource(R.string.restart_player_title), color = Color.White, fontSize = 16.sp)+ Text(stringResource(R.string.restart_player_detail), color = Color(0xFFB3B3B3), fontSize = 12.sp)+ }+ if (com.music.spotui.data.offline.OfflineStore.tracks.isNotEmpty()) RemoveDownloadsRow()+ // Donations (Ko-fi): always here, never in the way.+ androidx.compose.foundation.layout.Column(+ Modifier.fillMaxWidth().clickable { com.music.spotui.data.api.SupportReminder.open(ctx) }+ .padding(horizontal = 20.dp, vertical = 10.dp),+ ) {+ Text(stringResource(R.string.support_title), color = com.music.spotui.ui.theme.AppAccent, fontSize = 16.sp)+ Text(stringResource(R.string.support_row_detail), color = Color(0xFFB3B3B3), fontSize = 12.sp)+ }+ // About: version, Discord, source code and Ko-fi.+ var about by remember { androidx.compose.runtime.mutableStateOf(false) }+ if (about) com.music.spotui.ui.components.AboutSheet(onDismiss = { about = false })+ androidx.compose.foundation.layout.Column(+ Modifier.fillMaxWidth().clickable { about = true }.padding(horizontal = 20.dp, vertical = 10.dp),+ ) {+ Text(stringResource(R.string.creator_biography_section_title), color = Color.White, fontSize = 16.sp)+ Text(stringResource(R.string.about_detail), color = Color(0xFFB3B3B3), fontSize = 12.sp)+ }+ var perks by remember { androidx.compose.runtime.mutableStateOf(false) }+ if (perks) com.music.spotui.ui.components.SupporterSheet(onDismiss = { perks = false })+ if (com.music.spotui.data.api.SupportReminder.PERKS_ENABLED) androidx.compose.foundation.layout.Column(+ Modifier.fillMaxWidth().clickable { perks = true }.padding(horizontal = 20.dp, vertical = 10.dp),+ ) {+ Text(stringResource(R.string.supporter_perks_title), color = Color.White, fontSize = 16.sp)+ Text(stringResource(R.string.supporter_perks_detail), color = Color(0xFFB3B3B3), fontSize = 12.sp)+ }+ Text(+ stringResource(R.string.connect_device_menu_logout),+ color = Color.White, fontSize = 16.sp,+ modifier = Modifier+ .fillMaxWidth()+ .clickable {+ onDismiss()+ val app = com.music.spotui.di.Graph.app+ app.getSharedPreferences("myspoti_prefs", android.content.Context.MODE_PRIVATE)+ .edit().putBoolean("LoggedIn", false).remove("CurrentAccountName").apply()+ com.music.spotui.data.api.Api.HomeCache.clear()+ com.music.spotui.data.api.Api.LikedCache.tracks = null+ com.music.spotui.data.api.ProfileCache.clearSession()+ com.music.spotui.di.SongPlayer.clearSession()+ listOf("PlaybackState", "LibraryCache", "RecentItems", "LikedSongs",+ "LikedSongsFromSpotify", "LikedAlbums", "FollowedArtists").forEach { name ->+ app.getSharedPreferences(name, android.content.Context.MODE_PRIVATE).edit().clear().apply()+ }+ com.music.spotui.di.SessionActions.logout()+ }+ .padding(horizontal = 20.dp, vertical = 14.dp),+ )+ }+ }+}+++/** "App language": Automatic (French or English) or any language with Spotify's labels. */+@OptIn(androidx.compose.material3.ExperimentalMaterial3Api::class)+@Composable+private fun LanguageRow() {+ val ctx = androidx.compose.ui.platform.LocalContext.current+ val current = remember { com.music.spotui.data.AppLanguage.current(ctx) }+ var picking by remember { androidx.compose.runtime.mutableStateOf(false) }+ val auto = stringResource(R.string.language_auto)+ fun label(tag: String) = if (tag == com.music.spotui.data.AppLanguage.SYSTEM) auto else com.music.spotui.data.AppLanguage.nativeName(tag)+ androidx.compose.foundation.layout.Column(+ Modifier.fillMaxWidth().clickable { picking = true }.padding(horizontal = 20.dp, vertical = 10.dp),+ ) {+ Text(stringResource(R.string.settings_item_app_language_title), color = Color.White, fontSize = 16.sp)+ Text(label(current), color = Color(0xFFB3B3B3), fontSize = 12.sp)+ }+ if (picking) androidx.compose.material3.ModalBottomSheet(+ onDismissRequest = { picking = false },+ containerColor = Color(0xFF282828),+ ) {+ androidx.compose.foundation.lazy.LazyColumn(Modifier.fillMaxWidth().padding(bottom = 16.dp)) {+ item {+ Text(stringResource(R.string.settings_item_app_language_title), color = Color.White, fontSize = 18.sp,+ fontWeight = FontWeight.Bold, modifier = Modifier.padding(horizontal = 20.dp, vertical = 8.dp))+ Text(stringResource(R.string.language_partial_note), color = Color(0xFFB3B3B3), fontSize = 12.sp,+ modifier = Modifier.padding(start = 20.dp, end = 20.dp, bottom = 8.dp))+ }+ items(com.music.spotui.data.AppLanguage.AVAILABLE.size) { i ->+ val tag = com.music.spotui.data.AppLanguage.AVAILABLE[i]+ val selected = tag == current+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().heightIn(min = 52.dp).clickable {+ picking = false+ if (!selected) {+ com.music.spotui.data.AppLanguage.apply(ctx, tag)+ // Screens take the new language when the activity is rebuilt.+ generateSequence(ctx) { (it as? android.content.ContextWrapper)?.baseContext }+ .filterIsInstance<android.app.Activity>().firstOrNull()?.recreate()+ }+ }.padding(horizontal = 20.dp, vertical = 8.dp),+ ) {+ androidx.compose.foundation.layout.Column(Modifier.weight(1f)) {+ Text(label(tag), color = if (selected) com.music.spotui.ui.theme.AppAccent else Color.White, fontSize = 16.sp)+ if (tag == com.music.spotui.data.AppLanguage.SYSTEM)+ Text(stringResource(R.string.language_auto_detail), color = Color(0xFFB3B3B3), fontSize = 12.sp)+ }+ if (selected) androidx.compose.material3.Icon(androidx.compose.material.icons.Icons.Default.Check, null, tint = com.music.spotui.ui.theme.AppAccent)+ }+ }+ }+ }+}++/** "Remove all downloads", with the space they take; asks first, like the official app. */+@Composable+private fun RemoveDownloadsRow() {+ val ctx = androidx.compose.ui.platform.LocalContext.current+ var ask by remember { androidx.compose.runtime.mutableStateOf(false) }+ val size = android.text.format.Formatter.formatShortFileSize(ctx, com.music.spotui.data.offline.OfflineStore.totalBytes())+ androidx.compose.foundation.layout.Column(+ Modifier.fillMaxWidth().clickable { ask = true }.padding(horizontal = 20.dp, vertical = 10.dp),+ ) {+ Text(stringResource(R.string.settings_item_remove_downloads_title), color = Color.White, fontSize = 16.sp)+ Text(stringResource(R.string.downloads_size, size), color = Color(0xFFB3B3B3), fontSize = 12.sp)+ }+ if (ask) androidx.compose.material3.AlertDialog(+ onDismissRequest = { ask = false },+ containerColor = Color(0xFF282828),+ title = { Text(stringResource(R.string.settings_storage_remove_downloads_dialog_title), color = Color.White) },+ text = { Text(stringResource(R.string.playlist_entity_remove_download_dialog_description), color = Color(0xFFB3B3B3)) },+ confirmButton = {+ androidx.compose.material3.TextButton(onClick = {+ ask = false+ com.music.spotui.data.offline.OfflineDownloader.removeAll()+ }) { Text(stringResource(R.string.playlist_entity_remove_download_dialog_positive_button), color = com.music.spotui.ui.theme.AppAccent) }+ },+ dismissButton = {+ androidx.compose.material3.TextButton(onClick = { ask = false }) {+ Text(stringResource(R.string.add_to_playlist_button_cancel), color = Color.White)+ }+ },+ )+}++++@Composable+private fun EnergyOptionRow(label: String, detail: String, checked: Boolean,+ enabled: Boolean = true, onChecked: (Boolean) -> Unit) {+ Row(verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().heightIn(min = 64.dp)+ .toggleable(checked, enabled = enabled, role = Role.Switch, onValueChange = onChecked)+ .padding(horizontal = 20.dp, vertical = 10.dp)) {+ androidx.compose.foundation.layout.Column(Modifier.weight(1f)) {+ Text(label, color = Color.White, fontSize = 16.sp)+ Text(detail, color = Color(0xFFB3B3B3), fontSize = 12.sp)+ }+ androidx.compose.material3.Switch(checked = checked, enabled = enabled, onCheckedChange = null)+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/LibraryExtras.kt b/base/app/src/main/java/com/music/spotui/ui/screens/LibraryExtras.ktnew file mode 100644index 00000000..2177fbe0--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/LibraryExtras.kt@@ -0,0 +1,384 @@+package com.music.spotui.ui.screens++import android.widget.Toast+import androidx.compose.foundation.Image+import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.PaddingValues+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.heightIn+import androidx.compose.foundation.layout.navigationBarsPadding+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.lazy.items+import androidx.compose.foundation.lazy.itemsIndexed+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.automirrored.filled.ArrowBack+import androidx.compose.material.icons.automirrored.filled.PlaylistAdd+import androidx.compose.material.icons.filled.MoreVert+import androidx.compose.material.icons.outlined.CreateNewFolder+import androidx.compose.material.icons.outlined.Delete+import androidx.compose.material.icons.outlined.Edit+import androidx.compose.material.icons.outlined.PhoneAndroid+import androidx.compose.material3.AlertDialog+import androidx.compose.material3.ExperimentalMaterial3Api+import androidx.compose.material3.Icon+import androidx.compose.material3.ModalBottomSheet+import androidx.compose.material3.Text+import androidx.compose.material3.TextButton+import androidx.compose.material3.TextField+import androidx.compose.material3.TextFieldDefaults+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.rememberCoroutineScope+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Brush+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.vector.ImageVector+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.res.pluralStringResource+import androidx.compose.ui.res.stringResource+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.navigation.NavController+import app.myspoti.engine.R+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.bumptech.glide.integration.compose.placeholder+import com.music.spotui.data.api.LibraryFolders+import com.music.spotui.data.api.Response+import com.music.spotui.data.api.SpotifySync+import com.music.spotui.data.entity.LibraryEntry+import com.music.spotui.data.local.LocalItem+import com.music.spotui.data.local.LocalPlaylists+import com.music.spotui.data.local.LocalTrack+import com.music.spotui.di.Graph+import com.music.spotui.di.LocalPlayer+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.components.SwipeToRemove+import com.music.spotui.ui.components.Loader+import com.music.spotui.ui.components.SkeletonKind+import com.music.spotui.ui.components.pressable+import com.music.spotui.ui.navigation.localPlaylistRoute+import com.music.spotui.ui.theme.AppBackground+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.launch+import kotlinx.coroutines.withContext++private val Green: Color get() = com.music.spotui.ui.theme.AppAccent+private val SheetColor = Color(0xFF282828)++/** A name prompt (new playlist / folder, rename). */+@Composable+fun NameDialog(title: String, initial: String, confirm: String, onDismiss: () -> Unit, onConfirm: (String) -> Unit) {+ var text by remember { mutableStateOf(initial) }+ AlertDialog(+ onDismissRequest = onDismiss,+ containerColor = SheetColor,+ title = { Text(title, color = Color.White) },+ text = {+ TextField(+ value = text, onValueChange = { text = it }, singleLine = true,+ colors = TextFieldDefaults.colors(+ focusedContainerColor = Color(0xFF3A3A3A), unfocusedContainerColor = Color(0xFF3A3A3A),+ focusedTextColor = Color.White, unfocusedTextColor = Color.White, cursorColor = Green,+ focusedIndicatorColor = Green, unfocusedIndicatorColor = Color.Transparent,+ ),+ )+ },+ confirmButton = {+ TextButton(enabled = text.isNotBlank(), onClick = { onConfirm(text.trim()) }) { Text(confirm, color = Green) }+ },+ dismissButton = {+ TextButton(onClick = onDismiss) { Text(stringResource(R.string.add_to_playlist_button_cancel), color = Color.White) }+ },+ )+}++@Composable+private fun SheetRow(icon: ImageVector, label: String, detail: String? = null, onClick: () -> Unit) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().heightIn(min = 60.dp).clickable(onClick = onClick).padding(horizontal = 20.dp, vertical = 8.dp),+ ) {+ Icon(icon, null, tint = Color(0xFFB3B3B3), modifier = Modifier.size(26.dp))+ Spacer(Modifier.width(16.dp))+ Column {+ Text(label, color = Color.White, fontSize = 16.sp)+ if (detail != null) Text(detail, color = Color(0xFFB3B3B3), fontSize = 12.sp)+ }+ }+}++/** The Library's "+": a Spotify playlist, a Spotify folder, or a playlist on this phone. */+@OptIn(ExperimentalMaterial3Api::class)+@Composable+fun LibraryCreateSheet(navController: NavController, onDismiss: () -> Unit, onLibraryChanged: () -> Unit) {+ val context = LocalContext.current+ val scope = rememberCoroutineScope()+ var asking by remember { mutableStateOf<String?>(null) } // "playlist" | "folder" | "local"+ when (asking) {+ "playlist" -> NameDialog(stringResource(R.string.create_playlist_content_description), context.getString(R.string.my_playlist),+ stringResource(R.string.create_playlist_create_button), onDismiss = onDismiss) { name ->+ SpotifySync.createPlaylistWithTrack(context, name, "") { ok -> if (ok) onLibraryChanged() }+ onDismiss()+ }+ "folder" -> NameDialog(stringResource(R.string.create_menu_item_folder_title), context.getString(R.string.create_folder_name_suggested_folder_name),+ stringResource(R.string.create_playlist_create_button), onDismiss = onDismiss) { name ->+ scope.launch {+ val uri = LibraryFolders.create(name)+ if (uri != null) onLibraryChanged()+ else Toast.makeText(context, context.getString(R.string.folder_create_failed), Toast.LENGTH_SHORT).show()+ onDismiss()+ }+ }+ "local" -> NameDialog(stringResource(R.string.local_playlist_new), context.getString(R.string.my_playlist),+ stringResource(R.string.create_playlist_create_button), onDismiss = onDismiss) { name ->+ val p = LocalPlaylists.create(name)+ onDismiss()+ navController.navigate(localPlaylistRoute(p.id))+ }+ else -> ModalBottomSheet(onDismissRequest = onDismiss, containerColor = SheetColor) {+ Column(Modifier.navigationBarsPadding().padding(bottom = 12.dp)) {+ SheetRow(Icons.AutoMirrored.Filled.PlaylistAdd, stringResource(R.string.assisted_curation_search_playlist)) { asking = "playlist" }+ SheetRow(Icons.Outlined.CreateNewFolder, stringResource(R.string.create_menu_item_folder_title)) { asking = "folder" }+ SheetRow(Icons.Outlined.PhoneAndroid, stringResource(R.string.local_playlist_new), stringResource(R.string.local_add_note)) { asking = "local" }+ }+ }+ }+}++@Composable+private fun PageHeader(title: String, subtitle: String?, navController: NavController, onMenu: (() -> Unit)?) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().statusBarsPadding().padding(8.dp, 8.dp, 8.dp, 4.dp),+ ) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.size(44.dp).clip(CircleShape).pressable { navController.navigateUp() },+ ) { Icon(Icons.AutoMirrored.Filled.ArrowBack, stringResource(R.string.accessibility_navigate_back), tint = Color.White) }+ Column(Modifier.weight(1f).padding(start = 4.dp)) {+ Text(title, color = Color.White, fontSize = 20.sp, fontWeight = FontWeight.Bold, maxLines = 1, overflow = TextOverflow.Ellipsis)+ if (subtitle != null) Text(subtitle, color = Color(0xFFB3B3B3), fontSize = 13.sp)+ }+ if (onMenu != null) Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.size(44.dp).clip(CircleShape).pressable { onMenu() },+ ) { Icon(Icons.Default.MoreVert, stringResource(R.string.content_description_context_menu), tint = Color.White) }+ }+}++/** A Spotify library folder: its folders and playlists, opened level by level. */+@OptIn(ExperimentalMaterial3Api::class)+@Composable+fun FolderScreen(navController: NavController, uri: String, initialName: String) {+ val context = LocalContext.current+ val scope = rememberCoroutineScope()+ var name by remember { mutableStateOf(initialName) }+ var entries by remember { mutableStateOf<List<LibraryEntry>?>(null) }+ var menu by remember { mutableStateOf(false) }+ var renaming by remember { mutableStateOf(false) }+ var generation by remember { mutableStateOf(0) }+ LaunchedEffect(uri, generation) {+ withContext(Dispatchers.IO) {+ Graph.repository.provideLibraryFolder(uri).collect { r -> if (r is Response.Success) entries = r.data else if (r is Response.Error && entries == null) entries = emptyList() }+ }+ }+ if (menu) ModalBottomSheet(onDismissRequest = { menu = false }, containerColor = SheetColor) {+ Column(Modifier.navigationBarsPadding().padding(bottom = 12.dp)) {+ SheetRow(Icons.Outlined.Edit, stringResource(R.string.context_menu_rename_folder)) { menu = false; renaming = true }+ }+ }+ if (renaming) NameDialog(stringResource(R.string.context_menu_rename_folder), name, stringResource(R.string.local_rename),+ onDismiss = { renaming = false }) { newName ->+ renaming = false+ scope.launch { if (LibraryFolders.rename(uri, newName)) name = newName }+ }+ Column(Modifier.fillMaxSize().background(AppBackground)) {+ val n = entries?.size+ PageHeader(name, n?.let { pluralStringResource(R.plurals.add_to_playlist_folder_subtitle_playlists_count, it, it.toString()) }, navController) { menu = true }+ when (val list = entries) {+ null -> Loader(SkeletonKind.Header)+ else -> {+ com.music.spotui.data.local.LibraryOrder.version+ val arranged = com.music.spotui.data.local.LibraryOrder.run { arrange(list, sort, custom(uri), 0) }+ SumUpLibraryScreen(PaddingValues(0.dp), arranged, emptyList(), navController, reorderLevel = uri)+ }+ }+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun LocalItemRow(item: LocalItem, current: Boolean, onClick: () -> Unit) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().pressable(0.97f, onClick = onClick).padding(horizontal = 16.dp, vertical = 8.dp),+ ) {+ GlideImage(+ model = item.artUri, contentDescription = null, contentScale = ContentScale.Crop,+ loading = placeholder(R.drawable.placeholder), failure = placeholder(R.drawable.local_files_cover),+ modifier = Modifier.size(48.dp).clip(RoundedCornerShape(4.dp)),+ )+ Column(Modifier.padding(start = 12.dp).weight(1f)) {+ Text(item.title, color = if (current) Green else Color.White, fontSize = 15.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ if (item.artist.isNotBlank()) Text(item.artist, color = Color(0xFFB3B3B3), fontSize = 13.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ }+}++/** Phone files in a list ([items]), played by the local player; swipe right to left to remove. */+fun androidx.compose.foundation.lazy.LazyListScope.localItems(items: List<LocalItem>, context: String, onRemove: (LocalItem) -> Unit) {+ itemsIndexed(items, key = { _, i -> i.key }) { index, item ->+ val np = SongPlayer.nowPlaying.value+ val track = item.toTrack()+ SwipeToRemove(item.key, onRemove = { onRemove(item) }) {+ LocalItemRow(item, LocalPlayer.active.value && np.uri == "local:${track.id}") {+ LocalPlayer.play(items.map { it.toTrack() }, index, context = context)+ }+ }+ }+}++/** A playlist kept on this phone. */+@OptIn(ExperimentalMaterial3Api::class)+@Composable+fun LocalPlaylistScreen(navController: NavController, id: String) {+ val playlist = LocalPlaylists.playlists[id]+ var menu by remember { mutableStateOf(false) }+ var renaming by remember { mutableStateOf(false) }+ if (playlist == null) {+ LaunchedEffect(Unit) { navController.navigateUp() }+ return+ }+ if (menu) ModalBottomSheet(onDismissRequest = { menu = false }, containerColor = SheetColor) {+ Column(Modifier.navigationBarsPadding().padding(bottom = 12.dp)) {+ SheetRow(Icons.Outlined.Edit, stringResource(R.string.local_rename)) { menu = false; renaming = true }+ SheetRow(Icons.Outlined.Delete, stringResource(R.string.local_delete_playlist)) {+ menu = false+ navController.navigateUp()+ LocalPlaylists.delete(id)+ }+ }+ }+ if (renaming) NameDialog(stringResource(R.string.local_rename), playlist.name, stringResource(R.string.local_rename),+ onDismiss = { renaming = false }) { renaming = false; LocalPlaylists.rename(id, it) }+ Column(Modifier.fillMaxSize().background(AppBackground)) {+ PageHeader(playlist.name, stringResource(R.string.local_playlist_subtitle) + " • " ++ pluralStringResource(R.plurals.add_to_playlist_subtitle_songs_count, playlist.items.size, playlist.items.size.toString()),+ navController) { menu = true }+ if (playlist.items.isEmpty()) Text(stringResource(R.string.local_playlist_empty), color = Color(0xFFB3B3B3), fontSize = 14.sp,+ modifier = Modifier.padding(20.dp))+ else LazyColumn(contentPadding = PaddingValues(bottom = 140.dp), modifier = Modifier.fillMaxSize()) {+ item {+ Row(Modifier.fillMaxWidth().padding(16.dp, 4.dp), verticalAlignment = Alignment.CenterVertically) {+ Spacer(Modifier.weight(1f))+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.size(52.dp).pressable(0.92f) {+ LocalPlayer.play(playlist.items.map { it.toTrack() }, 0, context = playlist.name)+ }.clip(CircleShape).background(Green),+ ) {+ Icon(painterResource(R.drawable.play_svgrepo_com), stringResource(R.string.content_description_play_button), tint = Color.Black, modifier = Modifier.size(24.dp))+ }+ }+ }+ localItems(playlist.items, playlist.name) { LocalPlaylists.remove(id, it.key) }+ }+ }+}++/**+ * "Add to playlist" for a phone file: a playlist on this phone (or a new one), or one of+ * the user's Spotify playlists, where it is shown under "Added on this device" (Spotify+ * cannot hold phone files, so it stays on this phone).+ */+@OptIn(ExperimentalMaterial3Api::class, ExperimentalGlideComposeApi::class)+@Composable+fun AddLocalToPlaylistSheet(track: LocalTrack, onDismiss: () -> Unit) {+ val context = LocalContext.current+ var spotifyLists by remember { mutableStateOf<List<com.music.spotui.data.api.EditablePlaylist>?>(null) }+ var creating by remember { mutableStateOf(false) }+ LaunchedEffect(Unit) {+ spotifyLists = com.music.spotui.data.api.EditablePlaylists.load()+ }+ fun added(name: String) {+ Toast.makeText(context, context.getString(R.string.local_added_to, name), Toast.LENGTH_SHORT).show()+ onDismiss()+ }+ if (creating) {+ NameDialog(stringResource(R.string.local_playlist_new), context.getString(R.string.my_playlist),+ stringResource(R.string.create_playlist_create_button), onDismiss = { creating = false }) { name ->+ val p = LocalPlaylists.create(name)+ LocalPlaylists.add(p.id, track)+ added(p.name)+ }+ return+ }+ ModalBottomSheet(onDismissRequest = onDismiss, containerColor = SheetColor) {+ LazyColumn(Modifier.navigationBarsPadding().heightIn(max = 560.dp)) {+ item {+ Text(stringResource(R.string.context_menu_add_to_playlist), color = Color.White, fontSize = 20.sp, fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(20.dp, 4.dp, 20.dp, 4.dp))+ Text(stringResource(R.string.local_add_note), color = Color(0xFFB3B3B3), fontSize = 12.sp,+ modifier = Modifier.padding(20.dp, 0.dp, 20.dp, 8.dp))+ SheetRow(Icons.AutoMirrored.Filled.PlaylistAdd, stringResource(R.string.add_to_playlist_new_playlist_button_text),+ stringResource(R.string.local_playlist_subtitle)) { creating = true }+ }+ items(LocalPlaylists.list(), key = { "l:" + it.id }) { p ->+ PickRow(name = p.name, detail = stringResource(R.string.local_playlist_subtitle), cover = null) {+ LocalPlaylists.add(p.id, track); added(p.name)+ }+ }+ when (val lists = spotifyLists) {+ null -> item { Text(stringResource(R.string.loading_playlists), color = Color.Gray, fontSize = 14.sp, modifier = Modifier.padding(20.dp, 12.dp)) }+ else -> items(lists, key = { "s:" + it.id }) { p ->+ PickRow(name = p.name, detail = stringResource(R.string.local_added_section), cover = p.imageUrl) {+ LocalPlaylists.addToSpotify(p.id, track); added(p.name)+ }+ }+ }+ item { Spacer(Modifier.height(12.dp)) }+ }+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun PickRow(name: String, detail: String, cover: String?, onClick: () -> Unit) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().clickable(onClick = onClick).padding(horizontal = 20.dp, vertical = 8.dp),+ ) {+ if (cover == null) Image(painterResource(R.drawable.local_files_cover), null, modifier = Modifier.size(48.dp).clip(RoundedCornerShape(4.dp)))+ else GlideImage(model = cover, contentDescription = null, contentScale = ContentScale.Crop,+ loading = placeholder(R.drawable.placeholder), failure = placeholder(R.drawable.placeholder),+ modifier = Modifier.size(48.dp).clip(RoundedCornerShape(4.dp)))+ Column(Modifier.padding(start = 12.dp)) {+ Text(name, color = Color.White, fontSize = 15.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ Text(detail, color = Color(0xFFB3B3B3), fontSize = 12.sp, maxLines = 1)+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/LibraryScreeen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/LibraryScreeen.ktnew file mode 100644index 00000000..f1fd870a--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/LibraryScreeen.kt@@ -0,0 +1,817 @@+package com.music.spotui.ui.screens++import com.music.spotui.ui.components.pressable+import androidx.compose.ui.res.stringResource++import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.PaddingValues+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.navigationBarsPadding+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.layout.aspectRatio+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.lazy.items+import androidx.compose.foundation.lazy.itemsIndexed+import androidx.compose.foundation.lazy.grid.GridCells+import androidx.compose.foundation.lazy.grid.GridItemSpan+import androidx.compose.foundation.lazy.grid.LazyVerticalGrid+import androidx.compose.foundation.lazy.grid.items+import androidx.compose.foundation.lazy.grid.itemsIndexed+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.animation.AnimatedVisibility+import androidx.compose.foundation.text.BasicTextField+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.filled.Check+import androidx.compose.material.icons.filled.Close+import androidx.compose.material.icons.filled.DateRange+import androidx.compose.material.icons.filled.Person+import androidx.compose.material.icons.filled.Search+import androidx.compose.material.icons.filled.SwapVert+import androidx.compose.material3.ExperimentalMaterial3Api+import androidx.compose.material3.HorizontalDivider+import androidx.compose.material3.Icon+import androidx.compose.material3.ModalBottomSheet+import androidx.compose.material3.Scaffold+import androidx.compose.material3.Text+import androidx.compose.material3.TopAppBar+import androidx.compose.material3.TopAppBarDefaults+import androidx.compose.material3.rememberModalBottomSheetState+import androidx.compose.runtime.Composable+import androidx.compose.runtime.collectAsState+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.foundation.gestures.scrollBy+import androidx.compose.foundation.gestures.detectDragGesturesAfterLongPress+import androidx.compose.ui.input.pointer.pointerInput+import androidx.compose.ui.graphics.graphicsLayer+import androidx.compose.ui.zIndex+import androidx.compose.animation.core.VisibilityThreshold+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.toArgb+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.text.TextStyle+import androidx.compose.ui.text.style.TextAlign+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.lifecycle.viewmodel.compose.viewModel+import androidx.navigation.NavController+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.music.spotui.data.api.Api+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.AccountModel+import app.myspoti.engine.R+import com.music.spotui.data.entity.LibraryEntry+import com.music.spotui.data.local.LibraryOrder+import com.music.spotui.data.preferences.isLibraryGridView+import com.music.spotui.data.preferences.setLibraryGridView+import com.music.spotui.ui.components.Loader+import com.music.spotui.ui.components.Snackbar+import com.music.spotui.ui.navigation.Routes+import com.music.spotui.ui.navigation.albumRoute+import com.music.spotui.ui.navigation.artistRoute+import com.music.spotui.ui.navigation.playlistRoute+import com.music.spotui.ui.navigation.folderRoute+import com.music.spotui.ui.navigation.localPlaylistRoute+import com.music.spotui.ui.theme.AppBackground+import com.music.spotui.ui.theme.AppPalette+import com.music.spotui.ui.viewmodel.LibraryViewModel++@OptIn(ExperimentalMaterial3Api::class)+@Composable+fun LibraryScreen(navController: NavController) {++ val libraryViewModel: LibraryViewModel = viewModel()+ val entries by libraryViewModel.entries.collectAsState()+ val account by libraryViewModel.account.collectAsState()+ var showAccount by remember { mutableStateOf(false) }+ val context = LocalContext.current+ // Spotify-style layout toggle: rows or a 3-column grid, persisted across runs.+ var gridView by remember { mutableStateOf(isLibraryGridView(context)) }+ var searchActive by remember { mutableStateOf(false) }+ var searchQuery by remember { mutableStateOf("") }++ if (showAccount) {+ AccountSheet(+ account = (account as? Response.Success)?.data ?: AccountModel(),+ navController = navController,+ onDismiss = { showAccount = false },+ )+ }++ Column(+ modifier = Modifier+ .fillMaxSize()+ .background(Color(AppBackground.toArgb()))+ .statusBarsPadding()+ ) {+ // Header: title + account avatar. Built by hand (rather than a fixed-height+ // TopAppBar) so the title isn't clipped under the status bar.+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .padding(16.dp, 12.dp, 16.dp, 8.dp)+ ) {+ Text(+ text = stringResource(R.string.navigationbar_musicappitems_yourlibrary_title),+ fontWeight = FontWeight.Bold,+ color = Color.White,+ fontSize = 22.sp,+ modifier = Modifier.weight(1f),+ )+ var creating by remember { mutableStateOf(false) }+ if (creating) LibraryCreateSheet(navController, onDismiss = { creating = false }, onLibraryChanged = { libraryViewModel.load() })+ Icon(+ painter = painterResource(R.drawable.ic_add),+ contentDescription = stringResource(R.string.create_playlist_content_description),+ tint = Color.White,+ modifier = Modifier.pressable(0.96f) { creating = true }.padding(end = 14.dp).size(22.dp),+ )+ Icon(+ imageVector = Icons.Default.Search,+ contentDescription = stringResource(R.string.library_search_text_hint),+ tint = if (searchActive) Color(AppPalette.toArgb()) else Color.White,+ modifier = Modifier.pressable(0.96f) {+ searchActive = !searchActive+ if (!searchActive) searchQuery = ""+ }+ .padding(end = 14.dp)+ .size(22.dp)+ ,+ )+ Box(+ modifier = Modifier+ .size(34.dp)+ .clip(CircleShape)+ .background(Color(0xFF3A3A3A))+ .clickable { showAccount = true },+ contentAlignment = Alignment.Center+ ) {+ val avatar = (account as? Response.Success)?.data?.imageUrl.orEmpty()+ if (avatar.isNotBlank()) {+ AccountAvatar(avatar, 34.dp)+ } else {+ Icon(Icons.Default.Person, contentDescription = stringResource(R.string.account_title), tint = Color.White, modifier = Modifier.size(20.dp))+ }+ }+ }++ // Grid/list switch, like the icon at the top-right of Spotify's library.+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .padding(16.dp, 0.dp, 16.dp, 4.dp)+ ) {+ var sorting by remember { mutableStateOf(false) }+ if (sorting) LibrarySortSheet(onDismiss = { sorting = false })+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.pressable(0.96f) { sorting = true }.padding(vertical = 4.dp),+ ) {+ Icon(Icons.Default.SwapVert, contentDescription = null, tint = Color.White, modifier = Modifier.size(18.dp))+ Text(stringResource(sortLabel(LibraryOrder.sort)), color = Color.White, fontSize = 13.sp, fontWeight = FontWeight.SemiBold,+ modifier = Modifier.padding(start = 6.dp))+ }+ Spacer(modifier = Modifier.weight(1f))+ Icon(+ painter = painterResource(if (gridView) R.drawable.ic_view_list else R.drawable.ic_view_grid),+ contentDescription = if (gridView) stringResource(R.string.list_view) else stringResource(R.string.grid_view),+ tint = Color.White,+ modifier = Modifier.pressable(0.96f) {+ gridView = !gridView+ setLibraryGridView(context, gridView)+ }+ .size(18.dp)++ )+ }++ AnimatedVisibility(visible = searchActive) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .padding(16.dp, 0.dp, 16.dp, 6.dp)+ .clip(RoundedCornerShape(8.dp))+ .background(Color(0xFF252525))+ .padding(horizontal = 12.dp),+ ) {+ Icon(Icons.Default.Search, contentDescription = null, tint = Color(0xFF888888), modifier = Modifier.size(18.dp))+ BasicTextField(+ value = searchQuery,+ onValueChange = { searchQuery = it },+ singleLine = true,+ textStyle = TextStyle(color = Color.White, fontSize = 15.sp),+ modifier = Modifier+ .weight(1f)+ .padding(8.dp, 10.dp),+ decorationBox = { inner ->+ Box {+ if (searchQuery.isEmpty()) Text(stringResource(R.string.navigationbar_musicappitems_search_title), color = Color(0xFF888888), fontSize = 15.sp)+ inner()+ }+ },+ )+ if (searchQuery.isNotEmpty()) {+ Icon(+ imageVector = Icons.Default.Close,+ contentDescription = stringResource(R.string.chat_content_picker_clear_recent_searches),+ tint = Color(0xFF888888),+ modifier = Modifier.pressable(0.96f) { searchQuery = "" }+ .size(18.dp)+ ,+ )+ }+ }+ }++ val followedArtists by libraryViewModel.followedArtists.collectAsState()+ when (entries) {+ is Response.Loading -> LibrarySkeleton(PaddingValues(0.dp))+ // Offline / error: the pinned folders (Local Files, Downloaded) stay reachable.+ else -> Box {+ val localName = stringResource(R.string.local_files_title)+ val downloadsName = stringResource(R.string.collection_downloaded)+ val localSubtitle = stringResource(R.string.assisted_curation_search_playlist) + " • " + stringResource(R.string.local_playlist_subtitle)+ val hasDownloads = com.music.spotui.data.offline.OfflineStore.tracks.isNotEmpty() ||+ com.music.spotui.data.offline.OfflineDownloader.requests.isNotEmpty()+ val likedName = stringResource(R.string.collection_liked_songs_title)+ // Liked Songs, Local Files and Downloaded stay on top; the rest follows the chosen sort.+ val rootPinned = ((entries as? Response.Success)?.data ?: emptyList())+ .indexOfFirst { it.spotifyId == Api.HomeCache.LIKED_SONGS_ID } + 2 + (if (hasDownloads) 1 else 0)+ val allEntries = ((entries as? Response.Success)?.data ?: emptyList()).map {+ if (it.spotifyId == Api.HomeCache.LIKED_SONGS_ID) it.copy(name = likedName, subtitle = "") else it+ }.let { list ->+ // "Local Files" pinned right under Liked Songs, as in the official app.+ val local = com.music.spotui.data.entity.LibraryEntry(+ spotifyId = Api.HomeCache.LOCAL_FILES_ID, name = localName, subtitle = "",+ coverUri = "android.resource://${LocalContext.current.packageName}/drawable/local_files_cover", isPlaylist = true,+ )+ // "Downloaded" right after it, once something was downloaded.+ val downloads = com.music.spotui.data.entity.LibraryEntry(+ spotifyId = Api.HomeCache.DOWNLOADS_ID, name = downloadsName, subtitle = "", coverUri = "", isPlaylist = true,+ )+ val at = list.indexOfFirst { it.spotifyId == Api.HomeCache.LIKED_SONGS_ID } + 1+ // Then the phone's own playlists (files of this phone, not on Spotify).+ val localLists = com.music.spotui.data.local.LocalPlaylists.list().map { p ->+ com.music.spotui.data.entity.LibraryEntry(+ spotifyId = LOCAL_PLAYLIST_PREFIX + p.id, name = p.name,+ subtitle = localSubtitle, coverUri = "", isPlaylist = true,+ )+ }+ list.take(at) + local + (if (hasDownloads) listOf(downloads) else emptyList()) + localLists + list.drop(at)+ }.let { list ->+ LibraryOrder.version+ LibraryOrder.arrange(list, LibraryOrder.sort, LibraryOrder.custom(LibraryOrder.ROOT), rootPinned)+ }+ val filteredEntries = if (searchQuery.isBlank()) allEntries+ else allEntries.filter {+ it.name.contains(searchQuery, ignoreCase = true) ||+ it.subtitle.contains(searchQuery, ignoreCase = true)+ }+ val filteredArtists = if (searchQuery.isBlank()) followedArtists+ else followedArtists.filter { it.name.contains(searchQuery, ignoreCase = true) }+ if (gridView) LibraryGridScreen(PaddingValues(0.dp), filteredEntries, filteredArtists, navController,+ reorderLevel = if (searchQuery.isBlank()) LibraryOrder.ROOT else null, pinned = rootPinned)+ else SumUpLibraryScreen(PaddingValues(0.dp), filteredEntries, filteredArtists, navController,+ reorderLevel = if (searchQuery.isBlank()) LibraryOrder.ROOT else null, pinned = rootPinned)+ if (entries !is Response.Success) Box(modifier = Modifier.padding(20.dp, 100.dp)) { Snackbar(showMessage = stringResource(R.string.library_error)) }+ }+ }+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun AccountAvatar(url: String, size: androidx.compose.ui.unit.Dp) {+ GlideImage(+ modifier = Modifier.size(size).clip(CircleShape),+ model = url,+ contentScale = ContentScale.Crop,+ contentDescription = ""+ )+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun SumUpLibraryScreen(+ padding: PaddingValues,+ entries: List<LibraryEntry>,+ followedArtists: List<com.music.spotui.data.entity.ArtistsModel>,+ navController: NavController,+ /** The library level whose order a long press then a drag changes; null: no moving. */+ reorderLevel: String? = null,+ /** Entries at the top that never move (Liked Songs, Local Files, Downloaded). */+ pinned: Int = 0,+) {+ if (entries.isEmpty() && followedArtists.isEmpty()) {+ Box(modifier = Modifier.padding(20.dp, 40.dp)) { Snackbar(showMessage = stringResource(R.string.library_empty)) }+ return+ }+ val listState = androidx.compose.foundation.lazy.rememberLazyListState()+ val haptic = androidx.compose.ui.platform.LocalHapticFeedback.current+ val density = androidx.compose.ui.platform.LocalDensity.current+ // The rows as shown, moved live under the finger; saved when the finger lifts.+ // One state for the screen's life: the drag gestures hold on to it.+ var rows by remember { mutableStateOf(entries.distinctBy { LibraryOrder.key(it) }) }+ var dragKey by remember { mutableStateOf<String?>(null) }+ var dragOffset by remember { mutableStateOf(0f) }+ val level by androidx.compose.runtime.rememberUpdatedState(reorderLevel)+ val fixed by androidx.compose.runtime.rememberUpdatedState(pinned)+ androidx.compose.runtime.LaunchedEffect(entries) {+ if (dragKey == null) rows = entries.distinctBy { LibraryOrder.key(it) }+ }++ // Moves the dragged row to the row its centre is over (pinned rows excluded).+ fun follow() {+ val key = dragKey ?: return+ val info = listState.layoutInfo.visibleItemsInfo+ val dragged = info.firstOrNull { it.key == key } ?: return+ val centre = dragged.offset + dragOffset + dragged.size / 2f+ val target = info.firstOrNull { it.key != key && it.key is String && centre.toInt() in it.offset until it.offset + it.size } ?: return+ val from = rows.indexOfFirst { LibraryOrder.key(it) == key }+ val to = rows.indexOfFirst { LibraryOrder.key(it) == target.key }+ if (from < fixed || to < fixed || from < 0 || to < 0) return+ // Keeps the list still when the first visible row is involved.+ if (listState.firstVisibleItemIndex == from || listState.firstVisibleItemIndex == to)+ listState.requestScrollToItem(listState.firstVisibleItemIndex, listState.firstVisibleItemScrollOffset)+ rows = rows.toMutableList().apply { add(to, removeAt(from)) }+ dragOffset += dragged.offset - target.offset+ }++ fun finish() {+ val at = level+ if (dragKey != null && at != null) LibraryOrder.saveCustom(at, rows.drop(fixed).map { LibraryOrder.key(it) })+ dragKey = null+ dragOffset = 0f+ }++ // Near the top or bottom edge, the list scrolls by itself while a row is dragged.+ androidx.compose.runtime.LaunchedEffect(dragKey) {+ if (dragKey == null) return@LaunchedEffect+ val edge = with(density) { 72.dp.toPx() }+ while (dragKey != null) {+ val info = listState.layoutInfo+ val dragged = info.visibleItemsInfo.firstOrNull { it.key == dragKey }+ if (dragged != null) {+ val top = dragged.offset + dragOffset+ val bottom = top + dragged.size+ val speed = when {+ bottom > info.viewportEndOffset - edge -> 18f+ top < info.viewportStartOffset + edge -> -18f+ else -> 0f+ }+ if (speed != 0f) {+ val moved = listState.scrollBy(speed)+ dragOffset += moved+ follow()+ }+ }+ androidx.compose.runtime.withFrameNanos { }+ }+ }++ LazyColumn(+ state = listState,+ contentPadding = PaddingValues(top = 10.dp, bottom = 130.dp),+ modifier = Modifier+ .fillMaxSize()+ .padding(padding)+ .background(Color(0xFF0E0E13))+ ) {+ itemsIndexed(rows, key = { _, e -> LibraryOrder.key(e) }) { index, entry ->+ val key = LibraryOrder.key(entry)+ val dragged = dragKey == key+ val movable = reorderLevel != null && index >= pinned+ Row(+ horizontalArrangement = Arrangement.Start,+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ // Same modifier chain while dragging: changing its shape would rebuild the+ // gesture detector below and cancel the drag as soon as it starts.+ .animateItem(fadeInSpec = null, fadeOutSpec = null,+ placementSpec = if (dragged) null else androidx.compose.animation.core.spring(+ stiffness = androidx.compose.animation.core.Spring.StiffnessMediumLow,+ visibilityThreshold = androidx.compose.ui.unit.IntOffset.VisibilityThreshold))+ .zIndex(if (dragged) 1f else 0f)+ .graphicsLayer {+ translationY = if (dragged) dragOffset else 0f+ if (dragged) { scaleX = 1.03f; scaleY = 1.03f }+ }+ .background(if (dragged) Color(0xFF2A2A2A) else Color.Transparent, RoundedCornerShape(8.dp))+ .pressable(0.96f, onPressHint = { prefetchLibraryEntry(entry) }) { openLibraryEntry(entry, navController) }+ // Inside the clickable, so a long press that ends without moving opens nothing.+ .then(if (!movable) Modifier else Modifier.pointerInput(key) {+ try { detectDragGesturesAfterLongPress(+ onDragStart = {+ haptic.performHapticFeedback(androidx.compose.ui.hapticfeedback.HapticFeedbackType.LongPress)+ dragKey = key+ dragOffset = 0f+ },+ onDrag = { change, amount -> change.consume(); dragOffset += amount.y; follow() },+ onDragEnd = { finish() },+ onDragCancel = { finish() },+ ) } finally { if (dragKey == key) finish() }+ })+ .fillMaxWidth()+ .padding(20.dp, 6.dp)+ ) {+ LibraryEntryCover(entry, Modifier+ .size(55.dp)+ .clip(RoundedCornerShape(if (entry.isPlaylist) 6.dp else 4.dp)),+ )+ Column(modifier = Modifier.padding(start = 12.dp)) {+ Text(text = entry.name, color = Color.White, fontSize = 15.sp, fontWeight = FontWeight.Bold, maxLines = 1, overflow = TextOverflow.Ellipsis)+ Text(text = entry.subtitle, color = Color.Gray, fontSize = 12.sp, fontWeight = FontWeight.Medium, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ }+ }+ // ── Artists the user follows on Spotify ──+ if (followedArtists.isNotEmpty()) {+ item {+ Text(+ text = stringResource(R.string.song_dna_search_chip_followed_artists),+ color = Color.White,+ fontSize = 17.sp,+ fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(20.dp, 16.dp, 20.dp, 4.dp),+ )+ }+ items(followedArtists) { artist ->+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.pressable(0.96f) { navController.navigate(artistRoute(artist.name, artist.id)) }+ .fillMaxWidth()+ .padding(20.dp, 6.dp)++ ) {+ GlideImage(+ modifier = Modifier+ .size(55.dp)+ .clip(CircleShape),+ model = artist.coverUri,+ contentScale = ContentScale.Crop,+ contentDescription = ""+ )+ Column(modifier = Modifier.padding(start = 12.dp)) {+ Text(text = artist.name, color = Color.White, fontSize = 15.sp, fontWeight = FontWeight.Bold, maxLines = 1, overflow = TextOverflow.Ellipsis)+ Text(text = stringResource(R.string.artist_subtitle), color = Color.Gray, fontSize = 12.sp, fontWeight = FontWeight.Medium)+ }+ }+ }+ }+ }+}++/** An entry's artwork: Spotify's image, or the drawn cover of the app's own folders. */+@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun LibraryEntryCover(entry: LibraryEntry, modifier: Modifier) {+ val drawn = when {+ entry.spotifyId == Api.HomeCache.DOWNLOADS_ID -> R.drawable.downloads_cover+ entry.spotifyId == Api.HomeCache.LOCAL_FILES_ID || entry.spotifyId.startsWith(LOCAL_PLAYLIST_PREFIX) -> R.drawable.local_files_cover+ entry.isFolder -> R.drawable.folder_cover+ else -> 0+ }+ // Vector drawables are drawn directly (Glide left them blank).+ if (drawn != 0) androidx.compose.foundation.Image(painterResource(drawn), contentDescription = null, modifier = modifier)+ else GlideImage(model = entry.coverUri, contentScale = ContentScale.Crop, contentDescription = "", modifier = modifier)+}++/** Library ids of the phone's own playlists (see LocalPlaylists). */+const val LOCAL_PLAYLIST_PREFIX = "local-playlist:"++private fun prefetchLibraryEntry(entry: LibraryEntry) = when {+ entry.isFolder || entry.spotifyId.startsWith(LOCAL_PLAYLIST_PREFIX) -> Unit+ entry.spotifyId == Api.HomeCache.LOCAL_FILES_ID || entry.spotifyId == Api.HomeCache.DOWNLOADS_ID || entry.spotifyId == Api.HomeCache.EPISODES_ID -> Unit+ entry.spotifyId == Api.HomeCache.LIKED_SONGS_ID -> ContextViewModel.prefetch("liked", "")+ entry.isPlaylist -> ContextViewModel.prefetch("playlist", entry.spotifyId)+ else -> ContextViewModel.prefetch("album", entry.spotifyId)+}++private fun openLibraryEntry(entry: LibraryEntry, navController: NavController) {+ if (entry.isFolder) navController.navigate(folderRoute(entry.folderUri, entry.name))+ else if (entry.spotifyId.startsWith(LOCAL_PLAYLIST_PREFIX)) navController.navigate(localPlaylistRoute(entry.spotifyId.removePrefix(LOCAL_PLAYLIST_PREFIX)))+ else if (entry.spotifyId == Api.HomeCache.DOWNLOADS_ID) navController.navigate(Routes.Downloads.route)+ else if (entry.spotifyId == Api.HomeCache.LOCAL_FILES_ID) navController.navigate(Routes.LocalFiles.route)+ else if (entry.spotifyId == Api.HomeCache.LIKED_SONGS_ID) navController.navigate(Routes.Liked.route)+ else if (entry.spotifyId == Api.HomeCache.EPISODES_ID) navController.navigate(Routes.Episodes.route)+ else if (entry.isPlaylist) navController.navigate(playlistRoute(entry.spotifyId, entry.name))+ else navController.navigate(albumRoute(entry.name, entry.artists, entry.spotifyId))+}++/**+ * Grid layout of the same library content: 3 columns of square covers with the+ * title/subtitle underneath, like Spotify's "Grid" library view. Followed+ * artists render as circles under their own full-width header.+ */+@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun LibraryGridScreen(+ padding: PaddingValues,+ entries: List<LibraryEntry>,+ followedArtists: List<com.music.spotui.data.entity.ArtistsModel>,+ navController: NavController,+ /** The library level whose order a long press then a drag changes; null: no moving. */+ reorderLevel: String? = null,+ /** Entries at the top that never move (Liked Songs, Local Files, Downloaded). */+ pinned: Int = 0,+) {+ if (entries.isEmpty() && followedArtists.isEmpty()) {+ Box(modifier = Modifier.padding(20.dp, 40.dp)) { Snackbar(showMessage = stringResource(R.string.library_empty)) }+ return+ }+ val gridState = androidx.compose.foundation.lazy.grid.rememberLazyGridState()+ val haptic = androidx.compose.ui.platform.LocalHapticFeedback.current+ val density = androidx.compose.ui.platform.LocalDensity.current+ // Same as the list view, in two dimensions: the tile follows the finger and takes+ // the place of the tile its centre is over.+ var rows by remember { mutableStateOf(entries.distinctBy { LibraryOrder.key(it) }) }+ var dragKey by remember { mutableStateOf<String?>(null) }+ var dragOffset by remember { mutableStateOf(androidx.compose.ui.geometry.Offset.Zero) }+ val level by androidx.compose.runtime.rememberUpdatedState(reorderLevel)+ val fixed by androidx.compose.runtime.rememberUpdatedState(pinned)+ androidx.compose.runtime.LaunchedEffect(entries) {+ if (dragKey == null) rows = entries.distinctBy { LibraryOrder.key(it) }+ }++ fun follow() {+ val key = dragKey ?: return+ val info = gridState.layoutInfo.visibleItemsInfo+ val dragged = info.firstOrNull { it.key == key } ?: return+ val cx = dragged.offset.x + dragOffset.x + dragged.size.width / 2f+ val cy = dragged.offset.y + dragOffset.y + dragged.size.height / 2f+ val target = info.firstOrNull {+ it.key != key && it.key is String &&+ cx >= it.offset.x && cx < it.offset.x + it.size.width && cy >= it.offset.y && cy < it.offset.y + it.size.height+ } ?: return+ val from = rows.indexOfFirst { LibraryOrder.key(it) == key }+ val to = rows.indexOfFirst { LibraryOrder.key(it) == target.key }+ if (from < fixed || to < fixed || from < 0 || to < 0) return+ if (gridState.firstVisibleItemIndex == from || gridState.firstVisibleItemIndex == to)+ gridState.requestScrollToItem(gridState.firstVisibleItemIndex, gridState.firstVisibleItemScrollOffset)+ rows = rows.toMutableList().apply { add(to, removeAt(from)) }+ dragOffset += androidx.compose.ui.geometry.Offset(+ (dragged.offset.x - target.offset.x).toFloat(), (dragged.offset.y - target.offset.y).toFloat())+ }++ fun finish() {+ val at = level+ if (dragKey != null && at != null) LibraryOrder.saveCustom(at, rows.drop(fixed).map { LibraryOrder.key(it) })+ dragKey = null+ dragOffset = androidx.compose.ui.geometry.Offset.Zero+ }++ androidx.compose.runtime.LaunchedEffect(dragKey) {+ if (dragKey == null) return@LaunchedEffect+ val edge = with(density) { 72.dp.toPx() }+ while (dragKey != null) {+ val info = gridState.layoutInfo+ val dragged = info.visibleItemsInfo.firstOrNull { it.key == dragKey }+ if (dragged != null) {+ val top = dragged.offset.y + dragOffset.y+ val bottom = top + dragged.size.height+ val speed = when {+ bottom > info.viewportEndOffset - edge -> 18f+ top < info.viewportStartOffset + edge -> -18f+ else -> 0f+ }+ if (speed != 0f) {+ val moved = gridState.scrollBy(speed)+ dragOffset += androidx.compose.ui.geometry.Offset(0f, moved)+ follow()+ }+ }+ androidx.compose.runtime.withFrameNanos { }+ }+ }++ LazyVerticalGrid(+ state = gridState,+ columns = GridCells.Fixed(3),+ modifier = Modifier+ .fillMaxSize()+ .padding(padding)+ .background(Color(0xFF0E0E13)),+ contentPadding = PaddingValues(16.dp, 10.dp, 16.dp, 130.dp),+ horizontalArrangement = Arrangement.spacedBy(12.dp),+ verticalArrangement = Arrangement.spacedBy(18.dp),+ ) {+ itemsIndexed(rows, key = { _, e -> LibraryOrder.key(e) }) { index, entry ->+ val key = LibraryOrder.key(entry)+ val dragged = dragKey == key+ val movable = reorderLevel != null && index >= pinned+ Column(+ modifier = Modifier+ // Same modifier chain while dragging (see the list view).+ .animateItem(fadeInSpec = null, fadeOutSpec = null,+ placementSpec = if (dragged) null else androidx.compose.animation.core.spring(+ stiffness = androidx.compose.animation.core.Spring.StiffnessMediumLow,+ visibilityThreshold = androidx.compose.ui.unit.IntOffset.VisibilityThreshold))+ .zIndex(if (dragged) 1f else 0f)+ .graphicsLayer {+ translationX = if (dragged) dragOffset.x else 0f+ translationY = if (dragged) dragOffset.y else 0f+ if (dragged) { scaleX = 1.06f; scaleY = 1.06f }+ }+ .pressable(0.96f, onPressHint = { prefetchLibraryEntry(entry) }) { openLibraryEntry(entry, navController) }+ .then(if (!movable) Modifier else Modifier.pointerInput(key) {+ try { detectDragGesturesAfterLongPress(+ onDragStart = {+ haptic.performHapticFeedback(androidx.compose.ui.hapticfeedback.HapticFeedbackType.LongPress)+ dragKey = key+ dragOffset = androidx.compose.ui.geometry.Offset.Zero+ },+ onDrag = { change, amount -> change.consume(); dragOffset += amount; follow() },+ onDragEnd = { finish() },+ onDragCancel = { finish() },+ ) } finally { if (dragKey == key) finish() }+ })+ ) {+ LibraryEntryCover(entry, Modifier+ .fillMaxWidth()+ .aspectRatio(1f)+ .clip(RoundedCornerShape(if (entry.isPlaylist) 6.dp else 4.dp)),+ )+ Spacer(modifier = Modifier.height(6.dp))+ Text(text = entry.name, color = Color.White, fontSize = 13.sp, fontWeight = FontWeight.Bold, maxLines = 1, overflow = TextOverflow.Ellipsis)+ Text(text = entry.subtitle, color = Color.Gray, fontSize = 11.sp, fontWeight = FontWeight.Medium, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ }+ if (followedArtists.isNotEmpty()) {+ item(span = { GridItemSpan(maxLineSpan) }) {+ Text(+ text = stringResource(R.string.song_dna_search_chip_followed_artists),+ color = Color.White,+ fontSize = 17.sp,+ fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(top = 6.dp),+ )+ }+ items(followedArtists) { artist ->+ Column(+ horizontalAlignment = Alignment.CenterHorizontally,+ modifier = Modifier.pressable(0.96f) { navController.navigate(artistRoute(artist.name, artist.id)) }+ ) {+ GlideImage(+ modifier = Modifier+ .fillMaxWidth()+ .aspectRatio(1f)+ .clip(CircleShape),+ model = artist.coverUri,+ contentScale = ContentScale.Crop,+ contentDescription = ""+ )+ Spacer(modifier = Modifier.height(6.dp))+ Text(text = artist.name, color = Color.White, fontSize = 13.sp, fontWeight = FontWeight.Bold, maxLines = 1, overflow = TextOverflow.Ellipsis, textAlign = TextAlign.Center)+ Text(text = stringResource(R.string.artist_subtitle), color = Color.Gray, fontSize = 11.sp, fontWeight = FontWeight.Medium, textAlign = TextAlign.Center)+ }+ }+ }+ }+}++@Composable+private fun LibrarySkeleton(padding: PaddingValues) {+ Column(+ modifier = Modifier+ .fillMaxSize()+ .padding(padding)+ .background(Color(0xFF0E0E13))+ ) {+ Spacer(modifier = Modifier.height(10.dp))+ repeat(8) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .padding(20.dp, 6.dp)+ ) {+ Box(modifier = Modifier.size(55.dp).clip(RoundedCornerShape(4.dp)).background(Color(0xFF1E1E1E)))+ Column(modifier = Modifier.padding(start = 12.dp)) {+ Box(modifier = Modifier.height(14.dp).width(160.dp).clip(RoundedCornerShape(3.dp)).background(Color(0xFF1E1E1E)))+ Spacer(modifier = Modifier.height(6.dp))+ Box(modifier = Modifier.height(11.dp).width(90.dp).clip(RoundedCornerShape(3.dp)).background(Color(0xFF1E1E1E)))+ }+ }+ }+ }+}++@OptIn(ExperimentalMaterial3Api::class)+@Composable+private fun AccountSheet(+ account: AccountModel,+ navController: NavController,+ onDismiss: () -> Unit,+) {+ val sheetState = rememberModalBottomSheetState(skipPartiallyExpanded = true)+ val context = LocalContext.current+ ModalBottomSheet(+ onDismissRequest = onDismiss,+ sheetState = sheetState,+ containerColor = Color(0xFF1A1A1A),+ ) {+ Column(modifier = Modifier.navigationBarsPadding()) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().padding(16.dp, 4.dp, 16.dp, 16.dp)+ ) {+ Box(+ modifier = Modifier.size(56.dp).clip(CircleShape).background(Color(0xFF3A3A3A)),+ contentAlignment = Alignment.Center+ ) {+ if (account.imageUrl.isNotBlank()) AccountAvatar(account.imageUrl, 56.dp)+ else Icon(Icons.Default.Person, contentDescription = null, tint = Color.White, modifier = Modifier.size(30.dp))+ }+ Spacer(modifier = Modifier.width(14.dp))+ Column {+ Text(account.name.ifBlank { stringResource(R.string.spotify_user) }, color = Color.White, fontSize = 18.sp, fontWeight = FontWeight.Bold, maxLines = 1, overflow = TextOverflow.Ellipsis)+ if (account.email.isNotBlank()) Text(account.email, color = Color.Gray, fontSize = 13.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ if (account.plan.isNotBlank()) Text("Spotify ${account.plan}", color = Color(0xFF1DB954), fontSize = 12.sp, fontWeight = FontWeight.Medium)+ }+ }+ HorizontalDivider(color = Color(0xFF2A2A2A))++ // Spotify's own account pages (plan, privacy, devices), signed in, in the app.+ val context = androidx.compose.ui.platform.LocalContext.current+ AccountRow(stringResource(R.string.account_page_title) + " \u2197") {+ onDismiss()+ AccountBrowser.open(context, AccountBrowser.ACCOUNT_URL)+ }+ HorizontalDivider(color = Color(0xFF2A2A2A))+ Spacer(modifier = Modifier.height(8.dp))+ }+ }+}++@Composable+private fun AccountRow(label: String, tint: Color = Color.White, onClick: () -> Unit) {+ Text(+ text = label,+ color = tint,+ fontSize = 15.sp,+ modifier = Modifier+ .fillMaxWidth()+ .clickable { onClick() }+ .padding(20.dp, 16.dp)+ )+}++private fun sortLabel(sort: LibraryOrder.Sort) = when (sort) {+ LibraryOrder.Sort.CUSTOM -> R.string.your_library_sort_order_custom+ LibraryOrder.Sort.ALPHABETICAL -> R.string.your_library_sort_order_alphabetical+ LibraryOrder.Sort.CREATOR -> R.string.your_library_sort_order_creator+}++/** "Sort by": custom order (moved by hand), alphabetical or by creator. */+@OptIn(ExperimentalMaterial3Api::class)+@Composable+private fun LibrarySortSheet(onDismiss: () -> Unit) {+ ModalBottomSheet(onDismissRequest = onDismiss, containerColor = Color(0xFF282828)) {+ Column(Modifier.navigationBarsPadding().padding(bottom = 16.dp)) {+ Text(stringResource(R.string.filter_and_sort_sort_section_title), color = Color.White, fontSize = 18.sp,+ fontWeight = FontWeight.Bold, modifier = Modifier.padding(horizontal = 20.dp, vertical = 8.dp))+ for (sort in LibraryOrder.Sort.entries) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().clickable { LibraryOrder.choose(sort); onDismiss() }+ .padding(horizontal = 20.dp, vertical = 14.dp),+ ) {+ val selected = LibraryOrder.sort == sort+ Text(stringResource(sortLabel(sort)), color = if (selected) com.music.spotui.ui.theme.AppAccent else Color.White,+ fontSize = 16.sp, modifier = Modifier.weight(1f))+ if (selected) Icon(Icons.Default.Check, contentDescription = null, tint = com.music.spotui.ui.theme.AppAccent, modifier = Modifier.size(20.dp))+ }+ }+ Text(stringResource(R.string.library_reorder_hint), color = Color(0xFFB3B3B3), fontSize = 13.sp,+ modifier = Modifier.padding(horizontal = 20.dp, vertical = 8.dp))+ Text(stringResource(R.string.library_reorder_reset), color = Color.White, fontSize = 15.sp, fontWeight = FontWeight.SemiBold,+ modifier = Modifier.fillMaxWidth().clickable { LibraryOrder.reset(); onDismiss() }.padding(horizontal = 20.dp, vertical = 14.dp))+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/LocalFilesScreen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/LocalFilesScreen.ktnew file mode 100644index 00000000..105b26ac--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/LocalFilesScreen.kt@@ -0,0 +1,200 @@+package com.music.spotui.ui.screens++import android.content.Intent+import android.net.Uri+import android.provider.Settings+import androidx.activity.compose.rememberLauncherForActivityResult+import androidx.activity.result.contract.ActivityResultContracts+import androidx.compose.foundation.Image+import androidx.compose.foundation.background+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.lazy.itemsIndexed+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.automirrored.filled.ArrowBack+import androidx.compose.material3.Icon+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Brush+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.res.pluralStringResource+import androidx.compose.ui.res.stringResource+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextAlign+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.lifecycle.Lifecycle+import androidx.lifecycle.compose.LifecycleEventEffect+import androidx.navigation.NavController+import app.myspoti.engine.R+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.bumptech.glide.integration.compose.placeholder+import com.music.spotui.data.local.LocalMusic+import com.music.spotui.data.local.LocalTrack+import com.music.spotui.di.LocalPlayer+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.components.pressable+import com.music.spotui.ui.theme.AppBackground++/** "Local Files": the device's own audio files, played by [LocalPlayer]. */+@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun LocalFilesScreen(navController: NavController) {+ val context = LocalContext.current+ var granted by remember { mutableStateOf(LocalMusic.hasPermission(context)) }+ var askedOnce by remember { mutableStateOf(false) }+ var tracks by remember { mutableStateOf<List<LocalTrack>?>(null) }+ var find by remember { mutableStateOf("") }+ val launcher = rememberLauncherForActivityResult(ActivityResultContracts.RequestPermission()) { ok ->+ granted = ok; askedOnce = true+ }+ LifecycleEventEffect(Lifecycle.Event.ON_RESUME) { granted = LocalMusic.hasPermission(context) }+ LaunchedEffect(granted) { if (granted) tracks = LocalMusic.tracks(context, refresh = true) }++ val np by SongPlayer.nowPlaying+ val playingLocal = LocalPlayer.active.value+ var adding by remember { mutableStateOf<LocalTrack?>(null) }+ adding?.let { t -> AddLocalToPlaylistSheet(t, onDismiss = { adding = null }) }++ Box(Modifier.fillMaxSize().background(AppBackground)) {+ when {+ !granted -> EmptyState(+ title = stringResource(R.string.local_files_empty_section_title),+ subtitle = stringResource(R.string.local_files_empty_section_subtitle),+ button = stringResource(if (askedOnce) R.string.local_files_empty_section_button_go_to_settings else R.string.local_files_empty_section_dialog_permission_rationale_accept),+ ) {+ if (askedOnce) context.startActivity(Intent(Settings.ACTION_APPLICATION_DETAILS_SETTINGS, Uri.parse("package:${context.packageName}")))+ else launcher.launch(LocalMusic.permission)+ }+ tracks?.isEmpty() == true -> EmptyState(+ title = stringResource(R.string.local_files_empty_section_no_files_title),+ subtitle = stringResource(R.string.local_files_none_subtitle),+ button = null,+ ) {}+ else -> LazyColumn(Modifier.fillMaxSize()) {+ item {+ Column(+ Modifier.fillMaxWidth().background(Brush.verticalGradient(listOf(Color(0xFF2E5C46), AppBackground)))+ .statusBarsPadding().padding(horizontal = 16.dp),+ ) {+ Spacer(Modifier.height(56.dp))+ Image(+ painterResource(R.drawable.local_files_cover), null,+ modifier = Modifier.align(Alignment.CenterHorizontally).size(200.dp).clip(RoundedCornerShape(6.dp)),+ )+ Text(stringResource(R.string.local_files_title), color = Color.White, fontSize = 26.sp, fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(top = 20.dp))+ val n = tracks?.size ?: 0+ Text(pluralStringResource(R.plurals.local_files_count, n, n), color = Color(0xFFB3B3B3), fontSize = 14.sp,+ modifier = Modifier.padding(top = 4.dp))+ Row(Modifier.fillMaxWidth().padding(vertical = 12.dp), verticalAlignment = Alignment.CenterVertically) {+ Spacer(Modifier.weight(1f))+ Icon(painterResource(R.drawable.ic_player_shuffle), stringResource(R.string.play_mode_item_shuffle_title), tint = Color.White,+ modifier = Modifier.size(28.dp).pressable { tracks?.let { if (it.isNotEmpty()) LocalPlayer.play(it, it.indices.random(), shuffle = true) } })+ Spacer(Modifier.width(20.dp))+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.size(56.dp)+ .pressable(0.92f) {+ when {+ playingLocal && SongPlayer.isPlaying() -> SongPlayer.pause()+ playingLocal -> SongPlayer.play()+ else -> tracks?.let { LocalPlayer.play(it, 0) }+ }+ }+ .clip(CircleShape).background(com.music.spotui.ui.theme.AppAccent),+ ) {+ Icon(painterResource(if (playingLocal && SongPlayer.isPlaying()) R.drawable.ic_playing else R.drawable.play_svgrepo_com),+ stringResource(R.string.content_description_play_button), tint = Color.Black, modifier = Modifier.size(26.dp))+ }+ }+ }+ }+ item(key = "find") {+ com.music.spotui.ui.components.FindInListField(find, { find = it }, stringResource(R.string.local_files_find_hint),+ Modifier.padding(horizontal = 16.dp, vertical = 8.dp))+ }+ val shown = tracks.orEmpty().filter { com.music.spotui.ui.components.matchesFind(find, it.title, it.artist, it.album) }+ if (shown.isEmpty() && find.isNotBlank()) item(key = "find-empty") {+ com.music.spotui.ui.components.FindInListEmpty(stringResource(R.string.assisted_curation_search_empty_view_no_result_title, find.trim()))+ }+ itemsIndexed(shown, key = { _, t -> t.id }) { _, t ->+ val current = playingLocal && np.uri == "local:${t.id}"+ Row(+ verticalAlignment = Alignment.CenterVertically,+ // The whole folder plays from this song, even when the list is filtered.+ modifier = Modifier.fillMaxWidth().pressable(0.97f) { tracks?.let { all -> LocalPlayer.play(all, all.indexOf(t).coerceAtLeast(0)) } }+ .padding(horizontal = 16.dp, vertical = 8.dp),+ ) {+ GlideImage(+ model = t.artUri, contentDescription = null, contentScale = ContentScale.Crop,+ loading = placeholder(R.drawable.placeholder), failure = placeholder(R.drawable.local_files_cover),+ modifier = Modifier.size(48.dp).clip(RoundedCornerShape(4.dp)),+ )+ Column(Modifier.padding(start = 12.dp).weight(1f)) {+ Text(t.title, color = if (current) com.music.spotui.ui.theme.AppAccent else Color.White, fontSize = 15.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ if (t.artist.isNotBlank()) Text(t.artist, color = Color(0xFFB3B3B3), fontSize = 13.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ Icon(painterResource(R.drawable.ic_add), stringResource(R.string.context_menu_add_to_playlist), tint = Color.White,+ modifier = Modifier.size(24.dp).pressable(0.92f) { adding = t })+ }+ }+ item { Spacer(Modifier.height(140.dp)) }+ }+ }+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.statusBarsPadding().padding(12.dp).size(40.dp).clip(CircleShape)+ .background(Color(0x66000000)).pressable { navController.navigateUp() },+ ) {+ Icon(Icons.AutoMirrored.Filled.ArrowBack, stringResource(R.string.accessibility_navigate_back), tint = Color.White)+ }+ }+}++@Composable+private fun EmptyState(title: String, subtitle: String, button: String?, onClick: () -> Unit) {+ Column(+ horizontalAlignment = Alignment.CenterHorizontally,+ verticalArrangement = Arrangement.Center,+ modifier = Modifier.fillMaxSize().padding(horizontal = 32.dp),+ ) {+ Image(painterResource(R.drawable.local_files_cover), null, modifier = Modifier.size(120.dp).clip(RoundedCornerShape(6.dp)))+ Text(title, color = Color.White, fontSize = 22.sp, fontWeight = FontWeight.Bold, textAlign = TextAlign.Center,+ modifier = Modifier.padding(top = 24.dp))+ Text(subtitle, color = Color(0xFFB3B3B3), fontSize = 14.sp, textAlign = TextAlign.Center, modifier = Modifier.padding(top = 8.dp))+ if (button != null) Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.padding(top = 24.dp).height(48.dp).pressable(0.96f, onClick = onClick)+ .clip(RoundedCornerShape(50)).background(Color.White).padding(horizontal = 28.dp),+ ) {+ Text(button, color = Color.Black, fontSize = 15.sp, fontWeight = FontWeight.Bold)+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/LyricsScreen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/LyricsScreen.ktnew file mode 100644index 00000000..2caae634--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/LyricsScreen.kt@@ -0,0 +1,625 @@+package com.music.spotui.ui.screens++import androidx.compose.ui.res.stringResource++import android.content.Context+import android.content.Intent+import androidx.compose.animation.AnimatedVisibility+import androidx.compose.animation.animateColorAsState+import androidx.compose.animation.core.tween+import androidx.compose.animation.expandVertically+import androidx.compose.animation.fadeIn+import androidx.compose.animation.fadeOut+import androidx.compose.animation.shrinkVertically+import androidx.compose.foundation.Canvas+import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.gestures.Orientation+import androidx.compose.foundation.gestures.detectTapGestures+import androidx.compose.foundation.gestures.draggable+import androidx.compose.foundation.gestures.rememberDraggableState+import androidx.compose.foundation.interaction.DragInteraction+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.BoxWithConstraints+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.PaddingValues+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.navigationBarsPadding+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.lazy.LazyListState+import androidx.compose.foundation.lazy.itemsIndexed+import androidx.compose.foundation.lazy.rememberLazyListState+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.filled.Check+import androidx.compose.material.icons.filled.KeyboardArrowDown+import androidx.compose.material.icons.filled.MoreVert+import androidx.compose.material.icons.filled.OpenInFull+import androidx.compose.material3.CircularProgressIndicator+import androidx.compose.material3.DropdownMenu+import androidx.compose.material3.DropdownMenuItem+import androidx.compose.material3.Icon+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.collectAsState+import androidx.compose.runtime.derivedStateOf+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableLongStateOf+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.geometry.CornerRadius+import androidx.compose.ui.geometry.Offset+import androidx.compose.ui.geometry.Size+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.lerp+import androidx.compose.ui.graphics.luminance+import androidx.compose.ui.input.pointer.pointerInput+import androidx.compose.ui.layout.onSizeChanged+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.platform.LocalDensity+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.text.SpanStyle+import androidx.compose.ui.text.buildAnnotatedString+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.text.withStyle+import androidx.compose.ui.unit.TextUnit+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.lifecycle.viewmodel.compose.viewModel+import com.music.spotui.data.api.LyricsApi+import com.music.spotui.data.entity.LyricLine+import com.music.spotui.data.entity.Lyrics+import com.music.spotui.data.preferences.getLyricTranslateLang+import com.music.spotui.data.preferences.isLyricsExtraSources+import com.music.spotui.data.preferences.setLyricsExtraSources+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.components.rememberFrameClock+import com.music.spotui.ui.viewmodel.LyricsViewModel+import app.myspoti.engine.R+import kotlinx.coroutines.delay+import java.util.Locale++/**+ * Spotify's lyrics, as the official Android app shows them: the lyrics card in the+ * Now Playing scroll and the full-screen view, both on the track's own colour+ * (color-lyrics `colors`). Sung and current lines are in the highlight colour,+ * upcoming lines in the text colour; tapping a line seeks to it.+ */++/** The three colours of a lyrics view: background, upcoming text, sung / current text. */+private data class LyricsPalette(val background: Color, val text: Color, val highlight: Color)++private fun paletteFor(lyrics: Lyrics?, accent: Color): LyricsPalette {+ lyrics?.colors?.let { return LyricsPalette(Color(it.background), Color(it.text), Color(it.highlight)) }+ // No Spotify colours (fallback source): the artwork colour, like Spotify's own fallback.+ val bg = lerp(accent, Color.Black, 0.15f)+ val text = if (bg.luminance() > 0.35f) Color.Black.copy(alpha = 0.8f) else Color.Black.copy(alpha = 0.55f)+ return LyricsPalette(bg, text, Color.White)+}++/** Playback position, re-read on every frame while playing (smooth word highlight). */+@Composable+private fun rememberPosition(running: Boolean): () -> Long {+ val frame = rememberFrameClock(running, fps = 30)+ return remember(frame) {+ { frame.value; SongPlayer.getCurrentPosition().coerceAtLeast(0L) }+ }+}++private fun activeIndexFor(lyrics: Lyrics, positionMs: Long): Int {+ if (!lyrics.synced) return -1+ // Binary search: last line starting at or before the position.+ var lo = 0+ var hi = lyrics.lines.size - 1+ var found = -1+ while (lo <= hi) {+ val mid = (lo + hi) ushr 1+ if (lyrics.lines[mid].timeMs <= positionMs + 150) { found = mid; lo = mid + 1 } else hi = mid - 1+ }+ return found+}++/** Seek to a tapped synced line and make sure we're playing. */+private fun jumpTo(timeMs: Long) {+ com.music.spotui.di.Haptics.click()+ SongPlayer.seekTo(timeMs)+ if (!SongPlayer.isPlaying()) SongPlayer.play()+}++private fun shareLyrics(context: Context, title: String, artist: String, line: String?) {+ val id = SongPlayer.currentTrackId+ val text = buildString {+ if (!line.isNullOrBlank() && line != "♪") append("« ").append(line).append(" »\n")+ append(title).append(" · ").append(artist)+ if (id.isNotBlank()) append("\nhttps://open.spotify.com/track/").append(id)+ }+ val send = Intent(Intent.ACTION_SEND).setType("text/plain").putExtra(Intent.EXTRA_TEXT, text)+ context.startActivity(Intent.createChooser(send, context.getString(R.string.lyrics_share)).addFlags(Intent.FLAG_ACTIVITY_NEW_TASK))+}++@Composable+private fun rememberLyricsState(vm: LyricsViewModel, title: String, artist: String): LyricsViewModel.State {+ LaunchedEffect(title, artist, SongPlayer.currentTrackId) {+ SongPlayer.currentLyricsTrack()?.let { vm.load(it) }+ }+ return vm.state.collectAsState().value+}++/**+ * Keeps the active line about a third down the view, like Spotify. A manual scroll+ * pauses the follow for 3 s.+ */+@Composable+private fun AutoFollow(listState: LazyListState, activeIndex: Int, offsetPx: Int, enabled: Boolean) {+ var userScrollAt by remember { mutableLongStateOf(0L) }+ LaunchedEffect(listState) {+ listState.interactionSource.interactions.collect {+ if (it is DragInteraction.Start || it is DragInteraction.Stop) userScrollAt = System.currentTimeMillis()+ }+ }+ LaunchedEffect(activeIndex, enabled) {+ if (!enabled || activeIndex < 0) return@LaunchedEffect+ val wait = 3000 - (System.currentTimeMillis() - userScrollAt)+ if (wait > 0) delay(wait)+ listState.animateScrollToItem(activeIndex, -offsetPx)+ }+}++/**+ * One lyric line. Word-synced lines fill word by word; others switch colour as a+ * whole when they become current.+ */+@Composable+private fun LyricLineText(+ line: LyricLine,+ state: Int, // -1 sung, 0 current, 1 upcoming, 2 unsynced+ palette: LyricsPalette,+ fontSize: TextUnit,+ position: () -> Long,+ translation: String?,+ onTap: (() -> Unit)?,+) {+ val target = when (state) {+ 1 -> palette.text+ else -> palette.highlight+ }+ val color by animateColorAsState(target, tween(220), label = "lyricColor")+ val modifier = Modifier+ .fillMaxWidth()+ .then(+ if (onTap != null) Modifier.clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { onTap() } else Modifier+ )+ Column(modifier) {+ val words = line.words+ if (state == 0 && words != null) {+ // Only this line follows the clock: count of words already sung.+ val sung by remember(line) {+ derivedStateOf { val p = position(); words.count { it.startMs <= p } }+ }+ Text(+ text = buildAnnotatedString {+ words.forEachIndexed { i, w ->+ withStyle(SpanStyle(color = if (i < sung) palette.highlight else palette.text)) { append(w.text) }+ }+ },+ fontSize = fontSize,+ lineHeight = fontSize * 1.25f,+ fontWeight = FontWeight.Bold,+ )+ } else {+ Text(+ text = line.text,+ color = color,+ fontSize = fontSize,+ lineHeight = fontSize * 1.25f,+ fontWeight = FontWeight.Bold,+ )+ }+ AnimatedVisibility(+ visible = !translation.isNullOrBlank(),+ enter = expandVertically(tween(260)) + fadeIn(tween(260)),+ exit = shrinkVertically(tween(260)) + fadeOut(tween(260)),+ ) {+ Text(+ text = translation.orEmpty(),+ color = color.copy(alpha = color.alpha * 0.7f),+ fontSize = 15.sp,+ fontWeight = FontWeight.Normal,+ modifier = Modifier.padding(top = 2.dp),+ )+ }+ }+}++private fun lineState(lyrics: Lyrics, index: Int, active: Int): Int = when {+ !lyrics.synced -> 2+ index < active -> -1+ index == active -> 0+ else -> 1+}++/** Full-screen lyrics (Spotify's "Lyrics" view). */+@Composable+fun LyricsScreen(+ title: String,+ artist: String,+ album: String,+ accentColor: Color,+ onClose: () -> Unit,+) {+ val context = LocalContext.current+ val vm: LyricsViewModel = viewModel()+ val state = rememberLyricsState(vm, title, artist)+ val lyrics = (state as? LyricsViewModel.State.Loaded)?.lyrics+ val palette = paletteFor(lyrics, accentColor)+ val bg by animateColorAsState(palette.background, tween(300), label = "lyricsBg")+ val playing = com.music.spotui.di.Graph.currentSongState.playingState.value+ val position = rememberPosition(playing)+ val targetLanguage = getLyricTranslateLang(context).ifBlank { Locale.getDefault().language.ifBlank { "en" } }+ var menu by remember { mutableStateOf(false) }++ Column(+ modifier = Modifier+ .fillMaxSize()+ .background(bg)+ .clickable(interactionSource = remember { MutableInteractionSource() }, indication = null, onClick = {})+ .statusBarsPadding()+ .navigationBarsPadding(),+ ) {+ // ── Header: close, title / artist, more ──+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.fillMaxWidth().height(64.dp).padding(horizontal = 4.dp),+ ) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.size(48.dp).clickable(+ interactionSource = remember { MutableInteractionSource() }, indication = null, onClick = onClose,+ ),+ ) {+ Icon(Icons.Default.KeyboardArrowDown, contentDescription = stringResource(R.string.lyrics_fullscreen_close_button_readout_value), tint = palette.highlight, modifier = Modifier.size(32.dp))+ }+ Column(horizontalAlignment = Alignment.CenterHorizontally, modifier = Modifier.weight(1f)) {+ Text(title, color = palette.highlight, fontSize = 14.sp, fontWeight = FontWeight.Bold, maxLines = 1, overflow = TextOverflow.Ellipsis)+ Text(artist, color = palette.highlight.copy(alpha = 0.75f), fontSize = 13.sp, maxLines = 1, overflow = TextOverflow.Ellipsis)+ }+ Box {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.size(48.dp).clickable(+ interactionSource = remember { MutableInteractionSource() }, indication = null,+ ) { menu = true },+ ) {+ Icon(Icons.Default.MoreVert, contentDescription = stringResource(R.string.content_description_context_menu), tint = palette.highlight)+ }+ LyricsMenu(+ expanded = menu,+ onDismiss = { menu = false },+ canTranslate = state is LyricsViewModel.State.Loaded,+ translating = (state as? LyricsViewModel.State.Loaded)?.showTranslation == true,+ onTranslate = { vm.toggleTranslation(targetLanguage) },+ onReload = { SongPlayer.currentLyricsTrack()?.let { vm.load(it, force = true) } },+ )+ }+ }++ when (state) {+ is LyricsViewModel.State.Loading ->+ Box(Modifier.weight(1f).fillMaxWidth(), contentAlignment = Alignment.Center) {+ CircularProgressIndicator(color = palette.highlight)+ }+ is LyricsViewModel.State.NotFound ->+ Box(Modifier.weight(1f).fillMaxWidth().padding(32.dp), contentAlignment = Alignment.Center) {+ Text(stringResource(R.string.lyrics_fullscreen_no_lyrics_error_version_two), color = palette.highlight, fontSize = 18.sp, fontWeight = FontWeight.Bold)+ }+ is LyricsViewModel.State.Loaded -> {+ val l = state.lyrics+ // Translation is requested by onTranslate; do not upload lyrics on screen entry.+ val active by remember(l) { derivedStateOf { activeIndexFor(l, position()) } }+ val listState = rememberLazyListState()+ BoxWithConstraints(Modifier.weight(1f).fillMaxWidth()) {+ val offsetPx = with(LocalDensity.current) { (maxHeight * 0.28f).roundToPx() }+ AutoFollow(listState, active, offsetPx, enabled = l.synced)+ LazyColumn(+ state = listState,+ modifier = Modifier.fillMaxSize(),+ contentPadding = PaddingValues(24.dp, 8.dp, 24.dp, 48.dp),+ verticalArrangement = Arrangement.spacedBy(14.dp),+ ) {+ if (!l.synced) item {+ Text(+ stringResource(R.string.lyrics_fullscreen_unsynced),+ color = palette.highlight.copy(alpha = 0.8f),+ fontSize = 13.sp,+ modifier = Modifier.padding(bottom = 8.dp),+ )+ }+ itemsIndexed(l.lines, key = { i, _ -> i }) { i, line ->+ LyricLineText(+ line = line,+ state = lineState(l, i, active),+ palette = palette,+ fontSize = 24.sp,+ position = position,+ translation = if (state.showTranslation) state.translations?.getOrNull(i) else null,+ onTap = if (l.synced) ({ jumpTo(line.timeMs) }) else null,+ )+ }+ l.provider?.let { p ->+ item {+ Text(+ stringResource(R.string.lyrics_credential_note, p),+ color = palette.highlight.copy(alpha = 0.8f),+ fontSize = 12.sp,+ modifier = Modifier.padding(top = 24.dp),+ )+ }+ }+ }+ }+ val sameLanguage = state.sourceLanguage?.substringBefore('-')+ ?.equals(targetLanguage.substringBefore('-'), ignoreCase = true) == true+ LyricsControls(+ palette = palette,+ position = position,+ showTranslate = state.translationChecked && !sameLanguage,+ translationActive = state.showTranslation,+ translating = state.translating && state.translationRequested,+ onTranslate = { vm.toggleTranslation(targetLanguage) },+ onShare = { shareLyrics(context, title, artist, l.lines.getOrNull(active)?.text) },+ )+ }+ }+ }+}++@Composable+private fun LyricsMenu(+ expanded: Boolean,+ onDismiss: () -> Unit,+ canTranslate: Boolean,+ translating: Boolean,+ onTranslate: () -> Unit,+ onReload: () -> Unit,+) {+ val context = LocalContext.current+ var extra by remember { mutableStateOf(isLyricsExtraSources(context)) }+ DropdownMenu(expanded = expanded, onDismissRequest = onDismiss) {+ if (canTranslate) DropdownMenuItem(+ text = { Text(stringResource(if (translating) R.string.lyrics_fullscreen_translate_button_enabled_readout_value else R.string.lyrics_fullscreen_context_menu_main_page_translate_lyrics_action)) },+ onClick = { onDismiss(); onTranslate() },+ )+ DropdownMenuItem(+ text = {+ Column {+ Text(stringResource(R.string.lyrics_extra_title))+ Text(stringResource(R.string.lyrics_extra_summary), fontSize = 12.sp, color = Color.Gray)+ }+ },+ trailingIcon = { if (extra) Icon(Icons.Default.Check, contentDescription = null) },+ onClick = {+ extra = !extra+ setLyricsExtraSources(context, extra)+ LyricsApi.extraSources = extra+ onDismiss()+ onReload()+ },+ )+ DropdownMenuItem(text = { Text(stringResource(R.string.lyrics_reload)) }, onClick = { onDismiss(); onReload() })+ }+}++@Composable+private fun LyricsChip(label: String, icon: Int, active: Boolean, loading: Boolean, palette: LyricsPalette, onClick: () -> Unit) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .clip(RoundedCornerShape(50))+ .background(if (active) palette.highlight else Color.Black.copy(alpha = 0.22f))+ .clickable(enabled = !loading, onClick = onClick)+ .padding(horizontal = 12.dp, vertical = 7.dp),+ ) {+ if (loading) CircularProgressIndicator(color = palette.highlight, strokeWidth = 2.dp, modifier = Modifier.size(14.dp))+ else Icon(painterResource(icon), contentDescription = null, tint = if (active) palette.background else palette.highlight, modifier = Modifier.size(16.dp))+ Spacer(Modifier.width(6.dp))+ Text(label, color = if (active) palette.background else palette.highlight, fontSize = 13.sp, fontWeight = FontWeight.Bold)+ }+}++@Composable+private fun LyricsControls(+ palette: LyricsPalette,+ position: () -> Long,+ showTranslate: Boolean,+ translationActive: Boolean,+ translating: Boolean,+ onTranslate: () -> Unit,+ onShare: () -> Unit,+) {+ val durationMs = SongPlayer.getDuration().coerceAtLeast(0L)+ val playing = com.music.spotui.di.Graph.currentSongState.playingState.value+ Column(Modifier.fillMaxWidth().padding(horizontal = 24.dp).padding(bottom = 8.dp)) {+ Row(horizontalArrangement = Arrangement.spacedBy(8.dp), modifier = Modifier.padding(bottom = 10.dp)) {+ LyricsChip(stringResource(R.string.lyrics_fullscreen_chip_label_share), R.drawable.ic_share, false, false, palette, onShare)+ if (showTranslate) LyricsChip(stringResource(R.string.lyrics_fullscreen_chip_label_translate), R.drawable.ic_translate_lyrics, translationActive, translating, palette, onTranslate)+ }+ LyricsSeekBar(+ progress = { if (durationMs > 0) (position().toFloat() / durationMs).coerceIn(0f, 1f) else 0f },+ color = palette.highlight,+ onSeek = { SongPlayer.seekTo((durationMs * it).toLong()) },+ )+ Row(horizontalArrangement = Arrangement.SpaceBetween, modifier = Modifier.fillMaxWidth()) {+ val pos by remember { derivedStateOf { position() / 1000 } }+ Text(formatLyricsTime(pos * 1000), color = palette.highlight.copy(alpha = 0.75f), fontSize = 12.sp)+ Text(formatLyricsTime(durationMs), color = palette.highlight.copy(alpha = 0.75f), fontSize = 12.sp)+ }+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier+ .align(Alignment.CenterHorizontally)+ .padding(top = 4.dp)+ .size(60.dp)+ .clip(CircleShape)+ .background(palette.highlight)+ .clickable { if (SongPlayer.isPlaying()) SongPlayer.pause() else SongPlayer.play() },+ ) {+ Icon(+ painter = painterResource(if (playing) R.drawable.ic_playing else R.drawable.play_svgrepo_com),+ contentDescription = if (playing) stringResource(R.string.content_description_pause_button) else stringResource(R.string.content_description_play_button),+ tint = palette.background,+ modifier = Modifier.size(30.dp),+ )+ }+ }+}++@Composable+private fun LyricsSeekBar(progress: () -> Float, color: Color, onSeek: (Float) -> Unit) {+ var widthPx by remember { mutableStateOf(1f) }+ var dragging by remember { mutableStateOf(false) }+ var dragValue by remember { mutableStateOf(0f) }+ val dragState = rememberDraggableState { delta -> dragValue = (dragValue + delta / widthPx).coerceIn(0f, 1f) }+ Canvas(+ modifier = Modifier+ .fillMaxWidth()+ .height(24.dp)+ .onSizeChanged { widthPx = it.width.toFloat().coerceAtLeast(1f) }+ .pointerInput(widthPx) {+ detectTapGestures { onSeek((it.x / widthPx).coerceIn(0f, 1f)) }+ }+ .draggable(+ state = dragState,+ orientation = Orientation.Horizontal,+ onDragStarted = { dragging = true; dragValue = progress() },+ onDragStopped = { dragging = false; onSeek(dragValue) },+ ),+ ) {+ val value = if (dragging) dragValue else progress()+ val h = 3.dp.toPx()+ val y = size.height / 2f+ drawRoundRect(color.copy(alpha = 0.3f), Offset(0f, y - h / 2), Size(size.width, h), CornerRadius(h / 2))+ drawRoundRect(color, Offset(0f, y - h / 2), Size(size.width * value, h), CornerRadius(h / 2))+ drawCircle(color, radius = 6.dp.toPx(), center = Offset(size.width * value, y))+ }+}++private fun formatLyricsTime(timeMs: Long): String {+ val totalSeconds = timeMs.coerceAtLeast(0L) / 1000L+ return "%d:%02d".format(totalSeconds / 60L, totalSeconds % 60L)+}++/** Height of the lines window in the Now Playing card. */+private val CARD_LINES_HEIGHT = 296.dp++/**+ * The lyrics card in the Now Playing scroll. Hidden while loading and when the+ * track has no lyrics, as in the official app.+ */+@Composable+fun InlineLyrics(+ title: String,+ artist: String,+ album: String,+ accentColor: Color,+ onExpand: () -> Unit,+) {+ val context = LocalContext.current+ val vm: LyricsViewModel = viewModel()+ val state = rememberLyricsState(vm, title, artist)+ val s = state as? LyricsViewModel.State.Loaded ?: return+ val l = s.lyrics+ val palette = paletteFor(l, accentColor)+ val position = rememberPosition(com.music.spotui.di.Graph.currentSongState.playingState.value)+ val active by remember(l) { derivedStateOf { activeIndexFor(l, position()) } }+ val listState = rememberLazyListState()+ LaunchedEffect(active, l) {+ if (l.synced && active >= 0) listState.animateScrollToItem((active - 1).coerceAtLeast(0))+ }+ Column(+ modifier = Modifier+ .fillMaxWidth()+ .padding(16.dp, 8.dp, 16.dp, 40.dp)+ .clip(RoundedCornerShape(12.dp))+ .background(palette.background)+ .clickable(interactionSource = remember { MutableInteractionSource() }, indication = null) { onExpand() }+ .padding(16.dp),+ ) {+ Row(verticalAlignment = Alignment.CenterVertically, modifier = Modifier.fillMaxWidth()) {+ Text(+ stringResource(if (l.uncapped) R.string.lyrics_card_title else R.string.lyrics_card_title_preview),+ color = palette.highlight,+ fontSize = 16.sp,+ fontWeight = FontWeight.Bold,+ modifier = Modifier.weight(1f),+ )+ CardIconButton(palette, stringResource(R.string.lyrics_share), { Icon(painterResource(R.drawable.ic_share), null, tint = palette.highlight, modifier = Modifier.size(16.dp)) }) {+ shareLyrics(context, title, artist, l.lines.getOrNull(active)?.text)+ }+ Spacer(Modifier.width(8.dp))+ CardIconButton(palette, stringResource(R.string.lyrics_fullscreen), { Icon(Icons.Default.OpenInFull, null, tint = palette.highlight, modifier = Modifier.size(16.dp)) }, onExpand)+ }+ Spacer(Modifier.height(12.dp))+ LazyColumn(+ state = listState,+ userScrollEnabled = false,+ verticalArrangement = Arrangement.spacedBy(10.dp),+ modifier = Modifier.fillMaxWidth().height(CARD_LINES_HEIGHT),+ ) {+ itemsIndexed(l.lines, key = { i, _ -> i }) { i, line ->+ LyricLineText(+ line = line,+ state = lineState(l, i, active),+ palette = palette,+ fontSize = 22.sp,+ position = position,+ translation = null,+ onTap = null,+ )+ }+ }+ if (!l.uncapped) {+ Spacer(Modifier.height(16.dp))+ Box(+ modifier = Modifier+ .clip(RoundedCornerShape(50))+ .background(palette.highlight)+ .clickable { onExpand() }+ .padding(16.dp, 8.dp),+ ) {+ Text(stringResource(R.string.lyrics_card_show_lyrics_button), color = palette.background, fontSize = 13.sp, fontWeight = FontWeight.Bold)+ }+ }+ }+}++@Composable+private fun CardIconButton(palette: LyricsPalette, description: String, icon: @Composable () -> Unit, onClick: () -> Unit) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier+ .size(32.dp)+ .clip(CircleShape)+ .background(Color.Black.copy(alpha = 0.25f))+ .clickable(onClick = onClick),+ ) { icon() }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/PlayerScreen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/PlayerScreen.ktnew file mode 100644index 00000000..09cec607--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/PlayerScreen.kt@@ -0,0 +1,1221 @@+package com.music.spotui.ui.screens++import androidx.compose.material.icons.filled.Check+import androidx.compose.ui.draw.drawWithContent+import androidx.compose.ui.layout.onSizeChanged+import androidx.compose.foundation.gestures.detectTapGestures+import androidx.compose.foundation.gestures.detectHorizontalDragGestures+import androidx.compose.ui.input.pointer.pointerInput+import android.content.Context+import android.content.Intent+import android.net.Uri+import android.util.Log+import android.widget.Toast+import androidx.activity.compose.BackHandler+import androidx.activity.compose.rememberLauncherForActivityResult+import androidx.activity.result.contract.ActivityResultContracts+import androidx.compose.animation.AnimatedVisibility+import androidx.compose.animation.core.EaseOut+import androidx.compose.animation.core.tween+import androidx.compose.animation.slideInVertically+import androidx.compose.animation.slideOutVertically+import androidx.compose.foundation.background+import androidx.compose.foundation.basicMarquee+import androidx.compose.foundation.clickable+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.aspectRatio+import androidx.compose.foundation.layout.sizeIn+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.navigationBarsPadding+import androidx.compose.foundation.layout.imePadding+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.layout.requiredSize+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.layout.widthIn+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.filled.Add+import androidx.compose.material.icons.filled.CheckCircle+import androidx.compose.material.icons.filled.Favorite+import androidx.compose.material.icons.filled.FavoriteBorder+import androidx.compose.material.icons.filled.KeyboardArrowDown+import androidx.compose.material.icons.filled.KeyboardArrowRight+import androidx.compose.material.icons.automirrored.filled.List+import androidx.compose.material.icons.filled.MoreVert+import androidx.compose.material.icons.filled.Notifications+import androidx.compose.material.icons.filled.Person+import androidx.compose.material.icons.filled.PlayArrow+import androidx.compose.material.icons.filled.Share+import androidx.compose.material3.ExperimentalMaterial3Api+import androidx.compose.material3.Icon+import androidx.compose.material3.ModalBottomSheet+import androidx.compose.material3.OutlinedTextField+import androidx.compose.material3.TextButton+import androidx.compose.material3.rememberModalBottomSheetState+import androidx.compose.material3.Slider+import androidx.compose.material3.SliderColors+import androidx.compose.material3.SliderDefaults+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.MutableState+import androidx.compose.runtime.collectAsState+import androidx.compose.runtime.derivedStateOf+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import com.music.spotui.ui.components.pressable+import androidx.compose.ui.graphics.graphicsLayer+import androidx.compose.ui.input.nestedscroll.nestedScroll+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.res.vectorResource+import androidx.compose.foundation.shape.CircleShape+import androidx.compose.ui.draw.alpha+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Brush+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.toArgb+import androidx.compose.ui.graphics.vector.ImageVector+import androidx.compose.foundation.pager.HorizontalPager+import androidx.compose.foundation.pager.rememberPagerState+import androidx.compose.runtime.snapshotFlow+import kotlinx.coroutines.flow.distinctUntilChanged+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.res.stringResource+import androidx.compose.ui.semantics.ProgressBarRangeInfo+import androidx.compose.ui.semantics.contentDescription+import androidx.compose.ui.semantics.progressBarRangeInfo+import androidx.compose.ui.semantics.semantics+import androidx.compose.ui.semantics.setProgress+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.unit.DpSize+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.lifecycle.viewmodel.compose.viewModel+import androidx.lifecycle.Lifecycle+import androidx.lifecycle.compose.LocalLifecycleOwner+import androidx.lifecycle.repeatOnLifecycle+import androidx.lifecycle.compose.collectAsStateWithLifecycle+import app.myspoti.power.EnergySettings+import androidx.navigation.NavController+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import app.myspoti.engine.R+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.data.preferences.addLikedSongId+import com.music.spotui.data.preferences.getLikedSongIds+import com.music.spotui.data.preferences.getSongsByIds+import com.music.spotui.data.preferences.isSongLiked+import com.music.spotui.data.preferences.removeLikedSongId+import com.music.spotui.di.Palette+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.components.Snackbar+import com.music.spotui.ui.navigation.Routes+import com.music.spotui.ui.navigation.albumRoute+import com.music.spotui.ui.navigation.artistRoute+import com.music.spotui.ui.theme.AppBackground+import com.music.spotui.ui.theme.AppPalette+import com.music.spotui.ui.viewmodel.PlayerViewModel+import com.music.spotui.ui.viewmodel.confirmedTrackIdForDisplay+import com.music.spotui.ui.viewmodel.confirmedTrackIdFromUri+import kotlinx.coroutines.delay+import kotlin.math.roundToInt++@OptIn(ExperimentalGlideComposeApi::class, androidx.compose.foundation.ExperimentalFoundationApi::class)+@Composable+fun PlayerScreen(navController: NavController) {+ val playerViewModel : PlayerViewModel = viewModel()+ val songTitle = playerViewModel.currentSongTitle.value+ val songSinger = playerViewModel.currentSongSinger.value+ val songCoverUri = playerViewModel.currentSongCoverUri.value+ val songPlayingState = playerViewModel.currentSongPlayingState.value+ val audioBuffering = SongPlayer.isBuffering+ val songId = playerViewModel.currentSongId.value+ val context = LocalContext.current+ val energy by EnergySettings.state.collectAsStateWithLifecycle()+ // Liked state is Spotify's (LibraryAPI), pushed by the engine.+ val isLiked = playerViewModel.likeState+ var showMenu by remember { mutableStateOf(false) }+ var showLyrics by remember { mutableStateOf(false) }+ var showSavedIn by remember { mutableStateOf(false) }+ var showDevices by remember { mutableStateOf(false) }+ var showQueue by remember { mutableStateOf(false) }+ if (showDevices) com.music.spotui.ui.components.DevicesSheet { showDevices = false }+ if (showQueue) com.music.spotui.ui.components.QueueSheet(+ contextName = SongPlayer.nowPlaying.value.contextName.ifBlank { playerViewModel.currentSongAlbum.value },+ onDismiss = { showQueue = false },+ )++ BackHandler(enabled = showLyrics) {+ showLyrics = false+ }++ if (showMenu) {+ PlayerOptionsSheet(+ navController = navController,+ playerViewModel = playerViewModel,+ context = context,+ isLiked = isLiked,+ onDismiss = { showMenu = false },+ onOpenQueue = { showQueue = true },+ )+ }++ if (showSavedIn) {+ playerViewModel.queue.value.firstOrNull { it.id == songId }?.let { track ->+ com.music.spotui.ui.components.SavedInSheet(+ song = track,+ context = context,+ onDismiss = { showSavedIn = false },+ onLikedChanged = { isLiked.value = it },+ )+ } ?: run { showSavedIn = false }+ }+++ // Known cover (warmed by the mini player): the colour is there from the first frame.+ var coverColor by remember {+ mutableStateOf(Palette.cachedSecond(songCoverUri) ?: Color(AppBackground.toArgb()))+ }+ LaunchedEffect(songCoverUri) {+ if (songCoverUri.isNotBlank()) Palette().extractSecondColorFromCoverUrl(context = context, songCoverUri) { color ->+ coverColor = color+ }+ }+ // Track changes cross-fade the background instead of snapping.+ val dominentColor by androidx.compose.animation.animateColorAsState(coverColor, androidx.compose.animation.core.tween(450), label = "cover")++ val shuffle = playerViewModel.shuffleState.value+ val repeat = playerViewModel.repeatState.value+ val queueSongs = playerViewModel.queue.value+ val np by SongPlayer.nowPlaying+ val currentTrack = queueSongs.firstOrNull { it.id == songId }+ val actualTrackId = confirmedTrackIdFromUri(np.uri)+ val displayedTrackId = confirmedTrackIdForDisplay(np.uri, songId)++ // Smooth progress: redrawn every frame from the engine clock (see SpotifySeekBar).+ val frame = com.music.spotui.ui.components.rememberFrameClock(songPlayingState && !audioBuffering, fps = 15)++ // ── Swipe the artwork to change track: [previous, current, next] from Spotify ──+ val artworkPagerState = rememberPagerState(initialPage = 1, pageCount = { 3 })+ LaunchedEffect(songId) {+ if (artworkPagerState.currentPage != 1) artworkPagerState.scrollToPage(1)+ }+ LaunchedEffect(artworkPagerState) {+ snapshotFlow { artworkPagerState.settledPage }+ .distinctUntilChanged()+ .collect { page ->+ when (page) {+ 2 -> SongPlayer.swipeNext()+ 0 -> SongPlayer.previous()+ }+ }+ }++ // The confirmed URI can change after an optimistic songId already changed.+ // Hide a stale result in this composition, before the loading effect runs.+ LaunchedEffect(displayedTrackId, energy.policy.allowCanvas, audioBuffering) {+ playerViewModel.loadCanvas(+ if (energy.policy.allowCanvas && !com.music.spotui.data.DataSaver.active) displayedTrackId else "",+ allowFetch = !audioBuffering,+ )+ }+ val canvas = playerViewModel.canvasState.value+ val canvasUrl = canvas.url.takeIf {+ energy.policy.allowCanvas && !com.music.spotui.data.DataSaver.active && displayedTrackId.isNotBlank() && canvas.trackId == displayedTrackId+ }+ // Music video (YouTube, synced to the Spotify playback): looked up for every track+ // shown here, offered once its time map is known, shown in place of the artwork.+ val mv = com.music.spotui.video.MusicVideoController+ androidx.compose.runtime.DisposableEffect(mv) {+ mv.attachPlayerScreen()+ onDispose { mv.detachPlayerScreen() }+ }+ LaunchedEffect(actualTrackId, songTitle, audioBuffering) {+ if (!audioBuffering) mv.prepare(actualTrackId, songTitle, songSinger, SongPlayer.getDuration())+ }+ val remote = SongPlayer.activeDevice.value != null+ val readyVideo = mv.state.value as? com.music.spotui.video.MusicVideoController.State.Ready+ val videoMatchesTrack = displayedTrackId.isNotBlank() && actualTrackId == displayedTrackId && readyVideo?.trackId == actualTrackId+ val videoReady = videoMatchesTrack && !remote && !audioBuffering && !com.music.spotui.data.DataSaver.active+ // Switching to mobile data with the data saver on stops a clip that is playing.+ LaunchedEffect(com.music.spotui.data.DataSaver.active) {+ if (com.music.spotui.data.DataSaver.active && mv.on.value) mv.setOn(false)+ }+ val videoOn = mv.on.value && videoMatchesTrack && !remote+ // Canvas / clip players are built once the sheet has finished rising (then kept):+ // creating them in the first frame stalled it and the slide jumped.+ val settled by com.music.spotui.ui.navigation.LocalPageSettled.current+ var mediaReady by remember { mutableStateOf(false) }+ LaunchedEffect(settled) { if (settled) mediaReady = true }+ val showVideo = videoOn && !showLyrics && !mv.fullscreen.value && mediaReady+ // Buffer the clip as soon as it is known for the track on screen.+ LaunchedEffect(mv.state.value, remote, audioBuffering, displayedTrackId) { if (videoReady && !audioBuffering) mv.warm() }+ // Pulled down from the top, the player closes, like the back button (issue #4).+ val pullToClose = com.music.spotui.ui.components.rememberPullToDismiss { com.music.spotui.ui.navigation.PlayerSheet.close() }+ pullToClose.enabled = !showLyrics && !mv.fullscreen.value+ Box(+ modifier = Modifier+ .graphicsLayer { translationY = pullToClose.offset }+ .fillMaxSize()+ .background(+ Brush.verticalGradient(+ colors = if (energy.policy.oledBlack) listOf(Color.Black, Color.Black) else listOf(+ androidx.compose.ui.graphics.lerp(dominentColor, Color.Black, 0.35f),+ Color(0xFF121212),+ ),+ startY = 0f+ )+ )+ ) {+ val pillAboveTitle = canvasUrl != null && !videoOn && mediaReady+ if (canvasUrl != null && !videoOn && mediaReady) {+ CanvasVideo(+ url = canvasUrl,+ playing = songPlayingState && !showLyrics && !audioBuffering,+ modifier = Modifier.fillMaxSize(),+ )+ Box(+ modifier = Modifier+ .fillMaxSize()+ .background(+ Brush.verticalGradient(+ colors = listOf(+ Color.Black.copy(alpha = 0.50f),+ Color.Black.copy(alpha = 0.10f),+ Color.Black.copy(alpha = 0.35f),+ Color.Black.copy(alpha = 0.80f),+ )+ )+ )+ )+ }+ androidx.compose.foundation.lazy.LazyColumn(+ modifier = Modifier+ .fillMaxSize()+ .nestedScroll(pullToClose.connection)+ .statusBarsPadding(),+ horizontalAlignment = Alignment.CenterHorizontally+ ) {+ item {+ Column(+ modifier = Modifier+ .fillParentMaxHeight()+ .fillMaxWidth()+ .navigationBarsPadding(),+ horizontalAlignment = Alignment.CenterHorizontally+ ) {+ PlayerTopBar(+ navController,+ onMenuClick = { showMenu = true },+ np = np,+ fallbackName = playerViewModel.currentSongAlbum.value,+ )+ Spacer(modifier = Modifier.height(28.dp))+ // Media area: artwork (swipe to change track) or the music video, with+ // Spotify's "Passer à la vidéo" pill over it (black, like the official app).+ Box(modifier = Modifier.fillMaxWidth().aspectRatio(1f)) {+ if (showVideo) Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.fillMaxSize(),+ ) {+ com.music.spotui.ui.components.VideoSurface(onTap = { mv.fullscreen.value = true })+ } else HorizontalPager(+ state = artworkPagerState,+ modifier = Modifier+ .fillMaxWidth()+ .aspectRatio(1f),+ ) { page ->+ val cover = when (page) {+ 0 -> np.prev?.coverUri+ 2 -> np.next?.coverUri+ else -> null+ } ?: songCoverUri+ Box(contentAlignment = Alignment.Center, modifier = Modifier.fillMaxSize()) {+ GlideImage(+ modifier = Modifier+ .padding(horizontal = 24.dp)+ .aspectRatio(1f)+ .clip(RoundedCornerShape(8.dp))+ .alpha(if (canvasUrl != null && mediaReady) 0f else 1f),+ model = cover,+ contentScale = ContentScale.Crop,+ contentDescription = "")+ }+ }+ // Over the artwork / video; with a Canvas the artwork is hidden, so the+ // pill sits above the title instead of floating mid-screen.+ if ((videoReady || videoOn) && !pillAboveTitle) {+ com.music.spotui.ui.components.VideoSwitchPill(+ on = videoOn,+ modifier = Modifier.align(Alignment.BottomCenter).padding(bottom = 36.dp),+ )+ }+ if (showVideo) {+ com.music.spotui.ui.components.VideoFullscreenButton(+ modifier = Modifier.align(Alignment.BottomEnd).padding(end = 36.dp, bottom = 36.dp),+ )+ }+ }+ Spacer(modifier = Modifier.weight(1f))+ if ((videoReady || videoOn) && pillAboveTitle) {+ com.music.spotui.ui.components.VideoSwitchPill(+ on = videoOn,+ modifier = Modifier.padding(bottom = 20.dp),+ )+ }++ PlayerInfo(+ songTitle = songTitle,+ songSinger = songSinger,+ explicit = np.explicit || currentTrack?.explicit == true,+ liked = isLiked.value,+ onLikeClick = { playerViewModel.updateLikeState(!isLiked.value) },+ likeSong = { nowPlayingSong(playerViewModel) },+ onTitleClick = {+ val albumId = np.albumUri.substringAfterLast(":")+ if (albumId.isNotBlank()) navController.navigate(albumRoute(playerViewModel.currentSongAlbum.value, songSinger, albumId))+ },+ onArtistClick = {+ playerViewModel.goToArtist(SongPlayer.currentTrackId, songSinger) { route ->+ navController.navigate(route)+ }+ },+ )++ // Seek bar: follows the finger while dragging, seeks once on release.+ var isDragging by remember { mutableStateOf(false) }+ var dragValue by remember { mutableStateOf(0f) }+ val duration = mv.duration()+ SpotifySeekBar(+ fraction = {+ frame.value // redraw each frame+ if (isDragging) dragValue else {+ val d = mv.duration()+ if (d > 0) (mv.position().toFloat() / d).coerceIn(0f, 1f) else 0f+ }+ },+ onDrag = { isDragging = true; dragValue = it },+ onRelease = {+ val target = (dragValue * mv.duration()).toLong()+ mv.seekTo(target)+ isDragging = false+ },+ modifier = Modifier+ .fillMaxWidth()+ .padding(horizontal = 24.dp)+ .padding(top = 14.dp),+ )+ Row(+ modifier = Modifier+ .fillMaxWidth()+ .padding(horizontal = 24.dp),+ horizontalArrangement = Arrangement.SpaceBetween+ ) {+ ElapsedLabel(songPlayingState, if (isDragging) (dragValue * duration).toLong() else null) {+ playerViewModel.formatDuration(it)+ }+ Text(+ text = playerViewModel.formatDuration(duration.coerceAtLeast(0)),+ color = Color.White.copy(alpha = 0.7f),+ fontSize = 12.sp,+ )+ }++ PlayerFull(songPlayingState, playerViewModel, context, isLiked, shuffle, repeat, queueSongs)++ PlayerConnectRow(+ context = context,+ onDevices = { showDevices = true },+ onQueue = { showQueue = true },+ )+ Spacer(modifier = Modifier.height(20.dp))+ }+ }+ item {+ if (!audioBuffering) InlineLyrics(+ title = songTitle,+ artist = songSinger,+ album = playerViewModel.currentSongAlbum.value,+ accentColor = dominentColor,+ onExpand = { showLyrics = true },+ )+ }+ }++ AnimatedVisibility(+ visible = showLyrics,+ enter = slideInVertically(+ animationSpec = tween(durationMillis = 250, easing = EaseOut),+ initialOffsetY = { it },+ ),+ exit = slideOutVertically(+ animationSpec = tween(durationMillis = 200, easing = EaseOut),+ targetOffsetY = { it },+ ),+ ) {+ LyricsScreen(+ title = songTitle,+ artist = songSinger,+ album = playerViewModel.currentSongAlbum.value,+ accentColor = dominentColor,+ onClose = { showLyrics = false }+ )+ }+ }+}++++++++++/** "Lecture à partir de <type>" + context name, or the queue (like the official app). */+@Composable+private fun playingFromLabels(np: SongPlayer.NowPlaying, fallbackName: String): Pair<String, String> {+ if (np.provider == "queue") return stringResource(R.string.context_type_description_play_queue) to ""+ val type = np.contextUri.split(":").getOrNull(1).orEmpty()+ val name = np.contextName.ifBlank { fallbackName }+ return when {+ np.contextUri.contains(":collection") -> stringResource(R.string.context_type_description_collection_your_library) to stringResource(R.string.collection_liked_songs_title)+ type == "playlist" -> stringResource(R.string.context_type_description_playlist) to name+ type == "album" -> stringResource(R.string.context_type_description_album) to name+ type == "artist" -> stringResource(R.string.context_type_description_artist) to name+ type == "show" -> stringResource(R.string.context_type_description_show) to name+ type == "search" -> stringResource(R.string.context_type_description_search) to name+ else -> stringResource(R.string.default_notification_channel_name) to name+ }+}++/** Route of the page the music is playing from (playlist, album, artist, liked). */+private fun contextRoute(np: SongPlayer.NowPlaying): String? {+ val parts = np.contextUri.split(":")+ val id = parts.getOrNull(2).orEmpty()+ return when {+ np.contextUri.contains(":collection") -> Routes.Liked.route+ parts.getOrNull(1) == "playlist" && id.isNotBlank() -> com.music.spotui.ui.navigation.playlistRoute(id, np.contextName)+ parts.getOrNull(1) == "album" && id.isNotBlank() -> albumRoute(np.contextName, "", id)+ parts.getOrNull(1) == "artist" && id.isNotBlank() -> com.music.spotui.ui.navigation.artistRoute(np.contextName, id)+ else -> null+ }+}++@Composable+fun PlayerTopBar(+ navController: NavController,+ onMenuClick: () -> Unit,+ np: SongPlayer.NowPlaying,+ fallbackName: String = "",+) {+ val (line1, line2) = playingFromLabels(np, fallbackName)+ val route = contextRoute(np)+ Row(verticalAlignment = Alignment.CenterVertically,+ horizontalArrangement = Arrangement.SpaceBetween, modifier = Modifier+ .fillMaxWidth()+ .padding(horizontal = 20.dp, vertical = 12.dp)+ ) {+ Icon(modifier = Modifier+ .size(26.dp)+ .clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null+ ) {+ com.music.spotui.ui.navigation.PlayerSheet.close()+ },+ painter = painterResource(id = R.drawable.ic_down),+ tint = Color.White,+ contentDescription = "")++ Column(+ horizontalAlignment = Alignment.CenterHorizontally,+ modifier = Modifier+ .weight(1f)+ .padding(horizontal = 12.dp)+ .clickable(+ enabled = route != null,+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { route?.let { navController.navigate(it) } },+ ) {+ Text(+ text = line1,+ color = Color.White,+ fontSize = 12.sp,+ maxLines = 1,+ overflow = androidx.compose.ui.text.style.TextOverflow.Ellipsis,+ )+ if (line2.isNotBlank()) Text(+ text = line2,+ color = Color.White,+ fontSize = 14.sp,+ fontWeight = FontWeight.Bold,+ maxLines = 1,+ overflow = androidx.compose.ui.text.style.TextOverflow.Ellipsis,+ )+ }+ Icon(+ imageVector = Icons.Default.MoreVert,+ tint = Color.White,+ modifier = Modifier+ .size(24.dp)+ .clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null+ ) { onMenuClick() },+ contentDescription = stringResource(R.string.content_description_context_menu))+ }+}++/** Small grey "E" badge for explicit tracks. */+@Composable+fun ExplicitBadge(modifier: Modifier = Modifier) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = modifier+ .size(16.dp)+ .clip(RoundedCornerShape(2.dp))+ .background(Color.White.copy(alpha = 0.65f)),+ ) {+ // No font padding + trimmed line height so the "E" sits dead centre.+ Text(+ "E",+ color = Color.Black,+ fontWeight = FontWeight.Bold,+ style = androidx.compose.ui.text.TextStyle(+ fontSize = 10.sp,+ lineHeight = 10.sp,+ platformStyle = androidx.compose.ui.text.PlatformTextStyle(includeFontPadding = false),+ lineHeightStyle = androidx.compose.ui.text.style.LineHeightStyle(+ alignment = androidx.compose.ui.text.style.LineHeightStyle.Alignment.Center,+ trim = androidx.compose.ui.text.style.LineHeightStyle.Trim.Both,+ ),+ ),+ )+ }+}++/** Liked = green disc with a check; not liked = outlined plus (official app). */+@Composable+fun LikeButton(liked: Boolean, size: androidx.compose.ui.unit.Dp = 28.dp, onClick: () -> Unit) {+ // Pop on change (tap or sync), as the official heart/check: shrink, then spring back.+ // Nothing runs on first display, so long lists do not animate while scrolling.+ val scale = remember { androidx.compose.animation.core.Animatable(1f) }+ val firstShown = remember { booleanArrayOf(true) }+ LaunchedEffect(liked) {+ if (firstShown[0]) { firstShown[0] = false; return@LaunchedEffect }+ scale.snapTo(0.6f)+ scale.animateTo(1f, androidx.compose.animation.core.spring(dampingRatio = 0.4f, stiffness = 600f))+ }+ val mod = Modifier+ .size(size)+ .graphicsLayer { scaleX = scale.value; scaleY = scale.value }+ .clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { onClick() }+ if (liked) {+ Box(contentAlignment = Alignment.Center, modifier = mod.clip(CircleShape).background(com.music.spotui.ui.theme.AppAccent)) {+ Icon(Icons.Default.Check, contentDescription = stringResource(R.string.remove_from_liked), tint = Color.Black, modifier = Modifier.size(size * 0.65f))+ }+ } else {+ Icon(painterResource(id = R.drawable.ic_add), contentDescription = stringResource(R.string.aligned_curation_context_menu_item_add_to_liked_songs), tint = Color.White, modifier = mod)+ }+}++@OptIn(androidx.compose.foundation.ExperimentalFoundationApi::class)+@Composable+fun PlayerInfo(+ songTitle: String,+ songSinger: String,+ explicit: Boolean,+ liked: Boolean,+ onLikeClick: () -> Unit,+ /** The track behind the +: with it, the + opens "Saved in" once the track is saved. */+ likeSong: (() -> SongsModel)? = null,+ onArtistClick: (() -> Unit)? = null,+ onTitleClick: (() -> Unit)? = null,+) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .padding(horizontal = 24.dp)+ ) {+ Column(modifier = Modifier.weight(1f).padding(end = 16.dp)) {+ Text(+ modifier = Modifier+ // A few passes, after the sheet has settled (not an endless 120 Hz animation).+ .basicMarquee(iterations = 3, initialDelayMillis = 1_500, repeatDelayMillis = 2_500)+ .then(if (onTitleClick != null) Modifier.clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { onTitleClick() } else Modifier),+ text = songTitle,+ color = Color.White,+ fontSize = 22.sp,+ fontWeight = FontWeight.Bold,+ maxLines = 1,+ softWrap = false,+ )+ Row(verticalAlignment = Alignment.CenterVertically, modifier = Modifier.padding(top = 2.dp)) {+ if (explicit) {+ ExplicitBadge()+ Spacer(modifier = Modifier.width(6.dp))+ }+ Text(+ text = songSinger,+ color = Color.White.copy(alpha = 0.7f),+ fontSize = 16.sp,+ maxLines = 1,+ overflow = androidx.compose.ui.text.style.TextOverflow.Ellipsis,+ modifier = if (onArtistClick != null) Modifier.clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { onArtistClick() } else Modifier,+ )+ }+ }+ // No like for a local file (not in the Spotify library).+ if (!com.music.spotui.di.LocalPlayer.active.value) {+ if (likeSong != null) AddButton(song = likeSong, liked = liked, onLike = onLikeClick)+ else LikeButton(liked = liked, onClick = onLikeClick)+ }+ }+}++/** Elapsed time text with its own ticker (doesn't recompose the whole player). */+@Composable+private fun ElapsedLabel(playing: Boolean, override: Long?, format: (Long) -> String) {+ val mv = com.music.spotui.video.MusicVideoController+ var now by remember { mutableStateOf(mv.position()) }+ val lifecycle = LocalLifecycleOwner.current.lifecycle+ LaunchedEffect(playing, mv.on.value, lifecycle) {+ lifecycle.repeatOnLifecycle(Lifecycle.State.STARTED) {+ while (true) {+ now = mv.position()+ if (!playing) break+ delay(250L)+ }+ }+ }+ // Seek while paused: pick the new position up as soon as it changes.+ LaunchedEffect(override) { if (override == null) now = mv.position() }+ Text(text = format(override ?: now), color = Color.White.copy(alpha = 0.7f), fontSize = 12.sp)+}++/** Thin Spotify-style seek bar: 3dp track, small white thumb, drag to scrub. */+@Composable+fun SpotifySeekBar(+ fraction: () -> Float,+ onDrag: (Float) -> Unit,+ onRelease: () -> Unit,+ modifier: Modifier = Modifier,+) {+ var widthPx by remember { mutableStateOf(1f) }+ val seekDescription = stringResource(R.string.playback_seek_description)+ // Read only in semantics: playback ticks do not recompose the player.+ // Whole percent updates also avoid publishing a new semantic value every frame.+ val semanticProgress = remember(fraction) {+ derivedStateOf {+ val value = fraction()+ if (value.isFinite()) (value.coerceIn(0f, 1f) * 100f).roundToInt() / 100f else 0f+ }+ }+ androidx.compose.foundation.Canvas(+ modifier = modifier+ .height(24.dp)+ .semantics {+ contentDescription = seekDescription+ progressBarRangeInfo = ProgressBarRangeInfo(semanticProgress.value, 0f..1f)+ setProgress { requested ->+ if (!requested.isFinite()) return@setProgress false+ onDrag(requested.coerceIn(0f, 1f))+ onRelease()+ true+ }+ }+ .onSizeChanged { widthPx = it.width.toFloat().coerceAtLeast(1f) }+ .pointerInput(Unit) {+ detectTapGestures { o -> onDrag((o.x / widthPx).coerceIn(0f, 1f)); onRelease() }+ }+ .pointerInput(Unit) {+ detectHorizontalDragGestures(+ onDragStart = { o -> onDrag((o.x / widthPx).coerceIn(0f, 1f)) },+ onDragEnd = { onRelease() },+ onDragCancel = { onRelease() },+ ) { change, _ ->+ change.consume()+ onDrag((change.position.x / widthPx).coerceIn(0f, 1f))+ }+ }+ ) {+ val y = size.height / 2+ val track = 3.dp.toPx()+ val f = fraction().coerceIn(0f, 1f)+ drawLine(Color.White.copy(alpha = 0.3f), androidx.compose.ui.geometry.Offset(0f, y), androidx.compose.ui.geometry.Offset(size.width, y), track, androidx.compose.ui.graphics.StrokeCap.Round)+ drawLine(Color.White, androidx.compose.ui.geometry.Offset(0f, y), androidx.compose.ui.geometry.Offset(size.width * f, y), track, androidx.compose.ui.graphics.StrokeCap.Round)+ drawCircle(Color.White, radius = 6.dp.toPx(), center = androidx.compose.ui.geometry.Offset(size.width * f, y))+ }+}++@OptIn(ExperimentalMaterial3Api::class)+@Composable+fun CustomSlider(+ modifier: Modifier = Modifier,+ value: Float,+ onValueChange: (Float) -> Unit,+ onValueChangeFinished: (() -> Unit)? = null,+ valueRange: ClosedFloatingPointRange<Float> = 0f..1f,+ steps: Int = 0,+ colors: SliderColors = SliderDefaults.colors(),+) {+ Box(modifier = modifier.height(10.dp)) {+ Slider(+ value = value,+ onValueChange = onValueChange,+ onValueChangeFinished = onValueChangeFinished,+ valueRange = valueRange,+ steps = steps,+ colors = colors,+ )+ }+}++@Composable+fun PlayerEndInfo() {+ Row(verticalAlignment = Alignment.CenterVertically,+ horizontalArrangement = Arrangement.SpaceBetween,+ modifier = Modifier+ .fillMaxWidth()+ .padding(20.dp)){+ Icon(+ modifier = Modifier+ .size(22.dp),+ painter = painterResource(id = R.drawable.ic_devices),+ tint = Color.White,+ contentDescription = "")+ Icon(+ modifier = Modifier+ .size(16.dp),+ painter = painterResource(id = R.drawable.ic_share),+ tint = Color.White,+ contentDescription = "")+ }+}++@Composable+fun PlayerFull(+ songPlayingState: Boolean,+ playerViewModel: PlayerViewModel,+ context: Context,+ isLiked: MutableState<Boolean>,+ shuffle: Boolean,+ repeat: Boolean,+ queueSongs: List<SongsModel>+) {+++++ Row(verticalAlignment = Alignment.CenterVertically,+ horizontalArrangement = Arrangement.SpaceBetween,+ modifier = Modifier+ .fillMaxWidth()+ .padding(20.dp)+ ) {+ Icon(+ modifier = Modifier+ .size(25.dp)+ .drawWithContent {+ drawContent()+ if (shuffle) drawCircle(com.music.spotui.ui.theme.AppAccent, radius = 2.dp.toPx(),+ center = androidx.compose.ui.geometry.Offset(size.width / 2, size.height + 7.dp.toPx()))+ }+ .pressable {+ if (shuffle) {+ playerViewModel.updateShuffleState(false)+ } else {+ playerViewModel.updateShuffleState(true)+ }++ }+ ,+ tint = if (shuffle){+ com.music.spotui.ui.theme.AppAccent+ }+ else{+ Color.White+ },+ painter = painterResource(id = R.drawable.ic_player_shuffle),+ contentDescription = "")++ Icon(+ modifier = Modifier+ .size(35.dp)+ .pressable {+ // The queue itself is already in shuffled order when shuffle+ // is on (reordered once at toggle) — never re-shuffle per tap.+ playerViewModel.playPreviousSong(queueSongs, context)+ }+ ,+ tint = Color.White,+ painter = painterResource(id = R.drawable.ic_player_back),+ contentDescription = "")+ androidx.compose.foundation.layout.Box(+ modifier = Modifier+ // requiredSize forces an exact 64×64 square even if the parent Column+ // constrains height — .size() alone let it get squished into an ellipse.+ .requiredSize(64.dp)+ .pressable(pressedScale = 0.92f) {+ if (songPlayingState) {+ SongPlayer.pause()+ playerViewModel.updateSongState(+ playerViewModel.currentSongCoverUri.value,+ playerViewModel.currentSongTitle.value,+ playerViewModel.currentSongSinger.value,+ false,+ playerViewModel.currentSongId.value,+ playerViewModel.currentSongIndex.value,+ playerViewModel.currentSongAlbum.value+ )+ } else {+ SongPlayer.play()+ playerViewModel.updateSongState(+ playerViewModel.currentSongCoverUri.value,+ playerViewModel.currentSongTitle.value,+ playerViewModel.currentSongSinger.value,+ true,+ playerViewModel.currentSongId.value,+ playerViewModel.currentSongIndex.value,+ playerViewModel.currentSongAlbum.value+ )+ }+ }+ .clip(CircleShape)+ .background(Color.White)+ ,+ contentAlignment = Alignment.Center+ ) {+ Icon(+ modifier = Modifier+ .size(30.dp)++ ,+ tint = Color.Black,+ painter = if (songPlayingState)+ painterResource(id = R.drawable.ic_playing)+ else+ painterResource(id = R.drawable.play_svgrepo_com)+ ,+ contentDescription = "")+ }++ Icon(+ modifier = Modifier+ .size(35.dp)+ .pressable {++ playerViewModel.playNextSongs(queueSongs, context)+ }+ ,+ tint = Color.White,+ painter = painterResource(id = R.drawable.ic_player_skip),+ contentDescription = "")+ Icon(+ modifier = Modifier+ .size(20.dp)+ .pressable {+ SongPlayer.cycleRepeat()+++ }+ ,+ tint = if (repeat){+ com.music.spotui.ui.theme.AppAccent+ }+ else{+ Color.White+ },+ painter = painterResource(id = if (SongPlayer.repeatMode.value == 2) R.drawable.ic_repeat_one else R.drawable.ic_repeat_spotui),+ contentDescription = when (SongPlayer.repeatMode.value) { 1 -> stringResource(R.string.repeat_on); 2 -> stringResource(R.string.repeat_one); else -> stringResource(R.string.repeat_off) })+ }+}++/** The current audio output route name for the Connect indicator (BT name if+ * connected, else Headphones / This device). Uses AudioDeviceInfo.productName+ * which needs no Bluetooth permission. */+private fun currentAudioRoute(context: Context): String {+ return try {+ val am = context.getSystemService(Context.AUDIO_SERVICE) as android.media.AudioManager+ val outs = am.getDevices(android.media.AudioManager.GET_DEVICES_OUTPUTS)+ val bt = outs.firstOrNull {+ it.type == android.media.AudioDeviceInfo.TYPE_BLUETOOTH_A2DP ||+ it.type == android.media.AudioDeviceInfo.TYPE_BLUETOOTH_SCO+ }+ if (bt != null) return bt.productName?.toString()?.takeIf { it.isNotBlank() } ?: context.getString(R.string.label_bluetooth)+ val wired = outs.firstOrNull {+ it.type == android.media.AudioDeviceInfo.TYPE_WIRED_HEADPHONES ||+ it.type == android.media.AudioDeviceInfo.TYPE_WIRED_HEADSET ||+ it.type == android.media.AudioDeviceInfo.TYPE_USB_HEADSET+ }+ if (wired != null) context.getString(R.string.headphones) else context.getString(R.string.connect_phone_is_self)+ } catch (e: Exception) {+ context.getString(R.string.connect_phone_is_self)+ }+}++@Composable+fun PlayerConnectRow(+ context: Context,+ onDevices: () -> Unit,+ onQueue: () -> Unit,+) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ horizontalArrangement = Arrangement.SpaceBetween,+ modifier = Modifier+ .fillMaxWidth()+ .padding(horizontal = 24.dp, vertical = 4.dp),+ ) {+ // Spotify Connect: current device, opens the device picker.+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { onDevices() },+ ) {+ Icon(+ painter = painterResource(id = R.drawable.ic_devices),+ tint = com.music.spotui.ui.theme.AppAccent,+ modifier = Modifier.size(20.dp),+ contentDescription = stringResource(R.string.mr_user_route_category_name),+ )+ Text(+ text = com.music.spotui.ui.components.activeDeviceLabel(),+ color = com.music.spotui.ui.theme.AppAccent,+ fontSize = 13.sp,+ maxLines = 1,+ overflow = androidx.compose.ui.text.style.TextOverflow.Ellipsis,+ modifier = Modifier+ .padding(start = 8.dp)+ .widthIn(max = 200.dp),+ )+ }+ Row(verticalAlignment = Alignment.CenterVertically) {+ Icon(+ painter = painterResource(id = R.drawable.ic_share),+ tint = Color.White,+ modifier = Modifier+ .size(22.dp)+ .clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) {+ val id = SongPlayer.currentTrackId+ if (id.isBlank()) return@clickable+ val send = Intent(Intent.ACTION_SEND).apply {+ type = "text/plain"+ putExtra(Intent.EXTRA_TEXT, "https://open.spotify.com/track/$id")+ }+ context.startActivity(Intent.createChooser(send, context.getString(R.string.action_share_label)))+ },+ contentDescription = stringResource(R.string.action_share_label),+ )+ Spacer(modifier = Modifier.width(24.dp))+ Icon(+ imageVector = Icons.AutoMirrored.Filled.List,+ tint = Color.White,+ modifier = Modifier+ .size(26.dp)+ .clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { onQueue() },+ contentDescription = stringResource(R.string.action_queue_label),+ )+ }+ }+}++@Composable+fun PlayerOptionsSheet(+ navController: NavController,+ playerViewModel: PlayerViewModel,+ context: Context,+ isLiked: MutableState<Boolean>,+ onDismiss: () -> Unit,+ onOpenQueue: (() -> Unit)? = null,+) {+ val song = nowPlayingSong(playerViewModel)+ com.music.spotui.ui.components.SongOptionsSheet(+ song = song,+ navController = navController,+ context = context,+ onDismiss = onDismiss,+ nowPlaying = true,+ onOpenQueue = onOpenQueue,+ )+}+++/** The track that plays, as Spotify reports it (the local queue may not have it). */+fun nowPlayingSong(playerViewModel: PlayerViewModel): SongsModel {+ val np = SongPlayer.nowPlaying.value+ val songId = playerViewModel.currentSongId.value+ val known = playerViewModel.queue.value.firstOrNull { it.id == songId }+ return SongsModel(+ id = songId,+ title = playerViewModel.currentSongTitle.value,+ album = known?.album?.ifBlank { null } ?: playerViewModel.currentSongAlbum.value,+ singer = playerViewModel.currentSongSinger.value,+ coverUri = playerViewModel.currentSongCoverUri.value,+ url = known?.url.orEmpty(),+ spotifyTrackId = SongPlayer.currentTrackId,+ explicit = np.explicit,+ albumId = np.albumUri.substringAfterLast(":", "").ifBlank { known?.albumId.orEmpty() },+ )+}++/**+ * The + of a track, as in the official app: a first tap saves it in Liked Songs; once+ * saved (green check), a tap opens "Saved in" to add it to playlists or remove it.+ */+@Composable+fun AddButton(song: () -> SongsModel, liked: Boolean, size: androidx.compose.ui.unit.Dp = 28.dp, onLike: () -> Unit) {+ val context = androidx.compose.ui.platform.LocalContext.current+ var savedIn by remember { mutableStateOf<SongsModel?>(null) }+ savedIn?.let { s ->+ com.music.spotui.ui.components.SavedInSheet(song = s, context = context, onDismiss = { savedIn = null })+ }+ LikeButton(liked = liked, size = size) {+ if (liked) savedIn = song() else {+ onLike()+ android.widget.Toast.makeText(context, context.getString(R.string.snackbar_added_to_liked_songs), android.widget.Toast.LENGTH_SHORT).show()+ }+ }+}++@Composable+fun PlayerMenuRow(+ icon: ImageVector,+ label: String,+ iconTint: Color = Color.White,+ enabled: Boolean = true,+ trailingArrow: Boolean = false,+ onClick: () -> Unit+) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .clickable(enabled = enabled) { onClick() }+ .padding(horizontal = 20.dp, vertical = 14.dp)+ ) {+ Icon(+ imageVector = icon,+ tint = if (enabled) iconTint else Color.Gray,+ modifier = Modifier.size(22.dp),+ contentDescription = null+ )+ Spacer(modifier = Modifier.width(20.dp))+ Text(+ text = label,+ color = if (enabled) Color.White else Color.Gray,+ fontSize = 15.sp,+ modifier = Modifier.weight(1f)+ )+ if (trailingArrow) {+ Icon(+ imageVector = Icons.Default.KeyboardArrowRight,+ tint = Color.Gray,+ modifier = Modifier.size(20.dp),+ contentDescription = null+ )+ }+ }+}+/**+ * Plays a Spotify Canvas clip: a short, muted, looping video filling the+ * now-playing background. Uses a dedicated ExoPlayer (separate from the audio+ * engine) released when the composable leaves. Falls back to nothing if the URL fails.+ *+ * Loops are served from the media cache: without it every loop re-downloaded the+ * clip, and since ExoPlayer ignores the activity lifecycle it kept doing so in the+ * background (#87, gigabytes per hour). It also pauses while the app is not visible.+ */[email protected](androidx.media3.common.util.UnstableApi::class)+@Composable+private fun CanvasVideo(url: String, playing: Boolean, modifier: Modifier = Modifier) {+ val context = LocalContext.current+ val exo = remember(url) {+ val cached = androidx.media3.datasource.cache.CacheDataSource.Factory()+ .setCache(SongPlayer.mediaCache(context.applicationContext))+ .setUpstreamDataSourceFactory(androidx.media3.datasource.DefaultHttpDataSource.Factory())+ androidx.media3.exoplayer.ExoPlayer.Builder(context)+ .setMediaSourceFactory(androidx.media3.exoplayer.source.DefaultMediaSourceFactory(cached))+ .build().apply {+ setMediaItem(androidx.media3.common.MediaItem.fromUri(url))+ repeatMode = androidx.media3.common.Player.REPEAT_MODE_ALL+ volume = 0f+ playWhenReady = false+ prepare()+ }+ }+ val lifecycle = androidx.compose.ui.platform.LocalLifecycleOwner.current.lifecycle+ val requested by androidx.compose.runtime.rememberUpdatedState(playing)+ LaunchedEffect(exo, playing, lifecycle) {+ exo.playWhenReady = playing && lifecycle.currentState.isAtLeast(androidx.lifecycle.Lifecycle.State.STARTED)+ }+ androidx.compose.runtime.DisposableEffect(exo, lifecycle) {+ val observer = androidx.lifecycle.LifecycleEventObserver { _, _ ->+ exo.playWhenReady = requested && lifecycle.currentState.isAtLeast(androidx.lifecycle.Lifecycle.State.STARTED)+ }+ lifecycle.addObserver(observer)+ onDispose {+ lifecycle.removeObserver(observer)+ exo.release()+ }+ }+ androidx.compose.ui.viewinterop.AndroidView(+ modifier = modifier,+ // factory runs once; a new track's clip gets a new player, so rebind it here.+ update = { it.player = exo },+ factory = { ctx ->+ androidx.media3.ui.PlayerView(ctx).apply {+ player = exo+ // Strip ALL chrome: no controller, no buffering spinner, and no+ // artwork/placeholder icon (that "play icon" overlay) — just video.+ useController = false+ controllerAutoShow = false+ setShowBuffering(androidx.media3.ui.PlayerView.SHOW_BUFFERING_NEVER)+ setArtworkDisplayMode(androidx.media3.ui.PlayerView.ARTWORK_DISPLAY_MODE_OFF)+ setUseArtwork(false)+ setDefaultArtwork(null)+ hideController()+ resizeMode = androidx.media3.ui.AspectRatioFrameLayout.RESIZE_MODE_ZOOM+ setBackgroundColor(android.graphics.Color.TRANSPARENT)+ // Until a clip's first frame, show the screen behind, not a black shutter.+ setShutterBackgroundColor(android.graphics.Color.TRANSPARENT)+ setKeepContentOnPlayerReset(true)+ }+ },+ )+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/QueueScreen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/QueueScreen.ktnew file mode 100644index 00000000..154d7775--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/QueueScreen.kt@@ -0,0 +1,227 @@+package com.music.spotui.ui.screens++import androidx.compose.ui.res.stringResource++import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.gestures.detectDragGestures+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.navigationBarsPadding+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.lazy.itemsIndexed+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.filled.Delete+import androidx.compose.material.icons.filled.KeyboardArrowDown+import androidx.compose.material.icons.filled.Menu+import androidx.compose.material3.Icon+import androidx.compose.material3.SwipeToDismissBox+import androidx.compose.material3.SwipeToDismissBoxValue+import androidx.compose.material3.Text+import androidx.compose.material3.rememberSwipeToDismissBoxState+import androidx.compose.runtime.Composable+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableFloatStateOf+import androidx.compose.runtime.mutableIntStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.graphicsLayer+import androidx.compose.ui.graphics.toArgb+import androidx.compose.ui.input.pointer.pointerInput+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.platform.LocalDensity+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.lifecycle.viewmodel.compose.viewModel+import androidx.navigation.NavController+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.bumptech.glide.integration.compose.placeholder+import app.myspoti.engine.R+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.theme.AppPalette+import com.music.spotui.ui.viewmodel.PlayerViewModel++/**+ * The "play queue" — the track that's playing now plus everything coming up+ * (Spotify's Queue view). Tapping an upcoming track jumps straight to it;+ * dragging the handle reorders it; swiping a row removes it.+ */+@OptIn(ExperimentalGlideComposeApi::class, androidx.compose.material3.ExperimentalMaterial3Api::class)+@Composable+fun QueueScreen(navController: NavController) {+ // Spotify's real queue, read from the engine's PlayerAPI while this screen is open.+ androidx.compose.runtime.DisposableEffect(Unit) {+ SongPlayer.watchQueue(true)+ onDispose { SongPlayer.watchQueue(false) }+ }+ val q by SongPlayer.engineQueue++ Column(+ modifier = Modifier+ .fillMaxSize()+ .background(Color(0xFF121212))+ .statusBarsPadding()+ ) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .padding(16.dp, 8.dp)+ ) {+ Icon(+ imageVector = Icons.Default.KeyboardArrowDown,+ contentDescription = stringResource(R.string.bottom_actions_close),+ tint = Color.White,+ modifier = Modifier+ .size(28.dp)+ .clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { navController.navigateUp() }+ )+ Spacer(modifier = Modifier.width(12.dp))+ Text(stringResource(R.string.action_queue_label), color = Color.White, fontSize = 18.sp, fontWeight = FontWeight.Bold)+ }++ LazyColumn(+ contentPadding = androidx.compose.foundation.layout.PaddingValues(bottom = 32.dp),+ modifier = Modifier+ .fillMaxSize()+ .navigationBarsPadding()+ ) {+ q.current?.let {+ item {+ QueueHeader(stringResource(R.string.default_notification_channel_name))+ QueueRow(song = it, highlight = true, onClick = {})+ }+ }+ if (q.queued.isNotEmpty()) {+ item { QueueHeader(stringResource(R.string.next_in_queue)) }+ itemsIndexed(q.queued, key = { i, it -> "q" + i + it.uid + it.uri }) { _, item ->+ SwipeRemove(item) { QueueRow(song = item.song, highlight = false, onClick = { SongPlayer.skipTo(item) }) }+ }+ }+ if (q.nextUp.isNotEmpty()) {+ item { QueueHeader(stringResource(R.string.next_up)) }+ itemsIndexed(q.nextUp, key = { i, it -> "n" + i + it.uid + it.uri }) { _, item ->+ SwipeRemove(item) { QueueRow(song = item.song, highlight = false, onClick = { SongPlayer.skipTo(item) }) }+ }+ }+ }+ }+}++@Composable+private fun QueueHeader(text: String) {+ Text(+ text,+ color = Color.White,+ fontSize = 16.sp,+ fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(16.dp, 18.dp, 16.dp, 6.dp)+ )+}++@OptIn(androidx.compose.material3.ExperimentalMaterial3Api::class)+@Composable+private fun SwipeRemove(item: SongPlayer.QueueItem, content: @Composable () -> Unit) {+ val dismissState = rememberSwipeToDismissBoxState(+ confirmValueChange = { value ->+ if (value != SwipeToDismissBoxValue.Settled) {+ SongPlayer.removeFromQueue(item)+ true+ } else false+ }+ )+ SwipeToDismissBox(+ state = dismissState,+ backgroundContent = {+ Box(+ contentAlignment = Alignment.CenterEnd,+ modifier = Modifier+ .fillMaxSize()+ .background(Color(0xFF7A1F1F))+ .padding(horizontal = 24.dp),+ ) {+ Icon(Icons.Default.Delete, contentDescription = stringResource(R.string.aligned_curation_first_save_default_row_remove_action_description), tint = Color.White)+ }+ },+ content = { content() }+ )+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun QueueRow(+ song: com.music.spotui.data.entity.SongsModel,+ highlight: Boolean,+ onClick: () -> Unit,+ isDragging: Boolean = false,+ dragOffsetY: Float = 0f,+ onDragStart: () -> Unit = {},+ onDragEnd: () -> Unit = {},+ onDragDelta: (Float) -> Unit = {},+) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ horizontalArrangement = Arrangement.Start,+ modifier = Modifier+ .fillMaxWidth()+ .graphicsLayer { translationY = dragOffsetY }+ .background(Color(if (isDragging) 0xFF1E1E24 else 0xFF121212))+ .clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { onClick() }+ .padding(16.dp, 8.dp)+ ) {+ GlideImage(+ modifier = Modifier+ .size(48.dp)+ .clip(RoundedCornerShape(4.dp)),+ model = song.coverUri,+ contentScale = ContentScale.Crop,+ loading = placeholder(R.drawable.placeholder),+ failure = placeholder(R.drawable.placeholder),+ contentDescription = ""+ )+ Spacer(modifier = Modifier.width(12.dp))+ Column(modifier = Modifier.weight(1f)) {+ Text(+ text = song.title,+ color = if (highlight) Color(AppPalette.toArgb()) else Color.White,+ fontSize = 16.sp,+ fontWeight = FontWeight.Medium,+ maxLines = 1,+ overflow = TextOverflow.Ellipsis,+ )+ Text(+ text = song.singer,+ color = Color.Gray,+ fontSize = 13.sp,+ maxLines = 1,+ overflow = TextOverflow.Ellipsis,+ )+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/SearchScreen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/SearchScreen.ktnew file mode 100644index 00000000..18694a38--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/SearchScreen.kt@@ -0,0 +1,804 @@+package com.music.spotui.ui.screens++import com.music.spotui.ui.components.pressable+import androidx.compose.ui.res.stringResource++import android.os.Build+import android.util.Log+import androidx.annotation.RequiresApi+import androidx.compose.foundation.ExperimentalFoundationApi+import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.combinedClickable+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.offset+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.layout.width+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.filled.Close+import androidx.compose.material3.ExperimentalMaterial3Api+import androidx.compose.material3.Icon+import androidx.compose.material3.Surface+import androidx.compose.material3.Text+import androidx.compose.material3.TextField+import androidx.compose.material3.TextFieldDefaults+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.collectAsState+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import com.music.spotui.ui.components.SongOptionsSheet+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.draw.rotate+import androidx.compose.ui.focus.onFocusChanged+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.toArgb+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.text.TextStyle+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextAlign+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.lifecycle.viewmodel.compose.viewModel+import androidx.navigation.NavController+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.bumptech.glide.integration.compose.GlideImage+import com.bumptech.glide.integration.compose.placeholder+import app.myspoti.engine.R+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.SearchResults+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.data.preferences.addLikedSongId+import com.music.spotui.data.preferences.isSongLiked+import com.music.spotui.data.preferences.removeLikedSongId+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.components.Loader+import com.music.spotui.ui.navigation.Routes+import com.music.spotui.ui.navigation.albumRoute+import com.music.spotui.ui.navigation.artistRoute+import com.music.spotui.ui.navigation.categoryRoute+import com.music.spotui.ui.navigation.playlistRoute+import com.music.spotui.ui.navigation.showRoute+import com.music.spotui.ui.theme.AppBackground+import com.music.spotui.ui.theme.AppPalette+import com.music.spotui.ui.viewmodel.SearchViewModel+++@Composable+fun SearchScreen(navController: NavController) {+ val searchViewModel : SearchViewModel = viewModel()+ val results by searchViewModel.results.collectAsState()++ // Results are live search hits (or empty); never gate the search UI on them.+ val searchResults = (results as? Response.Success)?.data ?: SearchResults()++ Surface(+ modifier = Modifier+ .fillMaxSize()+ .background(Color(AppBackground.toArgb()))+ ) {+ SumUpSearchScreen(navController = navController, searchResults, searchViewModel)+ }+}+++@OptIn(ExperimentalFoundationApi::class, ExperimentalGlideComposeApi::class)+@Composable+fun SumUpSearchScreen(+ navController: NavController,+ results: SearchResults,+ searchViewModel: SearchViewModel,+) {+ val context = LocalContext.current++ var text by remember {+ mutableStateOf("")+ }+ // Recents are the *items opened from results* (songs/artists/albums), not the+ // typed queries, and only appear once the user taps into the search bar.+ var searchFocused by remember { mutableStateOf(false) }+ var recents by remember {+ mutableStateOf(com.music.spotui.data.preferences.getRecentItems(context).filter { com.music.spotui.data.api.Features.PODCASTS || it.type != "show" })+ }+ var menuSong by remember { mutableStateOf<SongsModel?>(null) }+ // Spotify's filter chips: Top (mixed), or one kind of result.+ var filter by remember { mutableStateOf(SearchFilter.Top) }+ menuSong?.let { sel ->+ SongOptionsSheet(+ song = sel,+ navController = navController,+ context = context,+ onDismiss = { menuSong = null },+ )+ }++ val recordRecent: (com.music.spotui.data.preferences.RecentItem) -> Unit = { item ->+ com.music.spotui.data.preferences.addRecentItem(context, item)+ recents = com.music.spotui.data.preferences.getRecentItems(context).filter { com.music.spotui.data.api.Features.PODCASTS || it.type != "show" }+ }+ // Live Spotify search results for the current query.+ val searchedList = results.songs+ // One relevance-mixed list (songs, artists, albums interleaved) instead of+ // separate type sections — matches how most music apps present search.+ val mixed = remember(results, filter) { filterSearchResults(results, filter) }++ LazyColumn(+ contentPadding = androidx.compose.foundation.layout.PaddingValues(bottom = 130.dp),+ modifier = Modifier+ .fillMaxSize()+ .background(Color(AppBackground.toArgb()))+ .statusBarsPadding()++ ){+ item{+ SearchTopBar()+ }+ stickyHeader {+ SearchStickyBar(+ text,+ onFocusChange = { searchFocused = it },+ ) {+ text = it+ searchViewModel.search(it)+ }+ }++ if (text.isBlank()) {+ if (searchFocused && recents.isNotEmpty()) {+ // ── Recent searches: the items the user opened (Spotify-style),+ // shown only once the search bar is focused ──+ item {+ Row(+ modifier = Modifier+ .fillMaxWidth()+ .padding(16.dp, 16.dp, 16.dp, 4.dp),+ verticalAlignment = Alignment.CenterVertically,+ horizontalArrangement = Arrangement.SpaceBetween,+ ) {+ Text(+ stringResource(R.string.assisted_curation_search_search_history_title),+ color = Color.White,+ fontSize = 18.sp,+ fontWeight = FontWeight.Bold,+ )+ Text(+ stringResource(R.string.chat_content_picker_clear_recent_searches),+ color = Color(0xFFB3B3B3),+ fontSize = 13.sp,+ fontWeight = FontWeight.SemiBold,+ modifier = Modifier.pressable(0.96f) {+ com.music.spotui.data.preferences.clearRecentItems(context)+ recents = emptyList()+ },+ )+ }+ }+ items(recents.size) { i ->+ val item = recents[i]+ RecentItemRow(+ item = item,+ onClick = {+ when (item.type) {+ "song" -> {+ val songUrl = item.songUrl.ifBlank {+ SongPlayer.buildSpotifyPlayQuery(item.spotifyTrackId, item.name, item.singer)+ }.let { savedUrl ->+ if (+ item.spotifyTrackId.isNotBlank() &&+ !savedUrl.startsWith("spotify:track:")+ ) {+ SongPlayer.buildSpotifyPlayQuery(item.spotifyTrackId, item.name, item.singer)+ } else {+ savedUrl+ }+ }+ val song = SongsModel(+ item.songId, item.name, item.songAlbum, item.singer,+ item.image, songUrl, item.spotifyTrackId,+ explicit = item.explicit,+ durationMs = item.durationMs,+ )+ searchViewModel.startRadioFromSong(song)+ SongPlayer.playSong(song.url, context)+ searchViewModel.updateSongState(+ song.coverUri, song.title, song.singer, true, song.id, 0, song.album)+ }+ "artist" -> navController.navigate(artistRoute(item.name, item.key.takeIf { it != item.name }.orEmpty()))+ "album" -> navController.navigate(albumRoute(item.name, item.singer, item.key.takeIf { it != item.name }.orEmpty()))+ "show" -> navController.navigate(showRoute(item.key, item.name))+ "playlist" -> navController.navigate(playlistRoute(item.key, item.name))+ }+ },+ onRemove = {+ com.music.spotui.data.preferences.removeRecentItem(context, item)+ recents = com.music.spotui.data.preferences.getRecentItems(context).filter { com.music.spotui.data.api.Features.PODCASTS || it.type != "show" }+ },+ )+ }+ } else {+ // ── Spotify-style "Browse all" category grid ──+ item {+ // Real Spotify opens a genre *catalogue* (a page of curated+ // playlists) rather than running a keyword song search.+ BrowseAllSection { genre, title ->+ if (genre == NEW_RELEASES_GENRE) navController.navigate(com.music.spotui.ui.navigation.Routes.NewReleases.route)+ else navController.navigate(categoryRoute(genre, title))+ }+ }+ }+ } else {+ item { SearchFilterChips(filter) { filter = it } }+ items(mixed.size) { i ->+ when (val row = mixed[i]) {+ is SearchRow.Song -> com.music.spotui.ui.components.SwipeToQueue(row.song) {+ SearchSongRow(row.song, searchedList, searchViewModel, onPlayed = {+ recordRecent(row.song.toRecentItem())+ }, onLongClick = { menuSong = row.song })+ }+ is SearchRow.Artist -> SearchArtistRow(row.artist) {+ recordRecent(com.music.spotui.data.preferences.RecentItem(+ type = "artist",+ key = row.artist.id.ifBlank { row.artist.name },+ name = row.artist.name,+ image = row.artist.coverUri,+ ))+ navController.navigate(artistRoute(row.artist.name, row.artist.id))+ }+ is SearchRow.Album -> SearchAlbumRow(row.album) {+ recordRecent(com.music.spotui.data.preferences.RecentItem(+ type = "album",+ key = row.album.spotifyId.ifBlank { row.album.name },+ name = row.album.name,+ singer = row.album.artists,+ image = row.album.coverUri,+ ))+ navController.navigate(albumRoute(row.album.name, row.album.artists, row.album.spotifyId))+ }+ is SearchRow.Playlist -> SearchPlaylistRow(row.playlist) {+ recordRecent(com.music.spotui.data.preferences.RecentItem(+ type = "playlist",+ key = row.playlist.spotifyId,+ name = row.playlist.name,+ singer = row.playlist.subtitle,+ image = row.playlist.coverUri,+ ))+ navController.navigate(playlistRoute(row.playlist.spotifyId, row.playlist.name))+ }+ }+ }+ // ── Podcasts: shows (→ detail) then individual episodes (→ play) ──+ if (com.music.spotui.data.api.Features.PODCASTS && (filter == SearchFilter.Top || filter == SearchFilter.Podcasts)) {+ if (results.shows.isNotEmpty()) {+ item { SearchSectionHeader(stringResource(R.string.assisted_curation_search_filter_podcasts)) }+ items(results.shows.size) { i ->+ val show = results.shows[i]+ SearchShowRow(show) {+ recordRecent(com.music.spotui.data.preferences.RecentItem(+ type = "show",+ key = show.id,+ name = show.name,+ singer = show.publisher,+ image = show.coverUri,+ ))+ navController.navigate(showRoute(show.id, show.name))+ }+ }+ }+ if (results.episodes.isNotEmpty()) {+ item { SearchSectionHeader(stringResource(R.string.assisted_curation_search_filter_episodes)) }+ items(results.episodes.size) { i ->+ val ep = results.episodes[i]+ SearchSongRow(ep, results.episodes, searchViewModel, onPlayed = {+ recordRecent(ep.toRecentItem())+ }, onLongClick = { menuSong = ep })+ }+ }+ }+ }++ }+}++/** A single row in the search results: a track, an artist, or an album. */+sealed class SearchRow {+ data class Song(val song: SongsModel) : SearchRow()+ data class Artist(val artist: com.music.spotui.data.entity.ArtistsModel) : SearchRow()+ data class Album(val album: com.music.spotui.data.entity.AlbumsModel) : SearchRow()+ data class Playlist(val playlist: com.music.spotui.data.entity.LibraryEntry) : SearchRow()+}++/** The search filter chips (official labels). Podcasts shows shows + episodes. */+enum class SearchFilter(@androidx.annotation.StringRes val label: Int) {+ Top(R.string.assisted_curation_search_filter_top),+ Songs(R.string.assisted_curation_search_filter_songs),+ Artists(R.string.assisted_curation_search_filter_artists),+ Albums(R.string.assisted_curation_search_filter_albums),+ Playlists(R.string.assisted_curation_search_filter_playlists),+ Podcasts(R.string.assisted_curation_search_filter_podcasts),+}++private fun filterSearchResults(results: SearchResults, filter: SearchFilter): List<SearchRow> = when (filter) {+ SearchFilter.Top -> mixSearchResults(results)+ SearchFilter.Songs -> results.songs.map { SearchRow.Song(it) }+ SearchFilter.Artists -> results.artists.map { SearchRow.Artist(it) }+ SearchFilter.Albums -> results.albums.map { SearchRow.Album(it) }+ SearchFilter.Playlists -> results.playlists.map { SearchRow.Playlist(it) }+ SearchFilter.Podcasts -> emptyList()+}++@Composable+private fun SearchFilterChips(selected: SearchFilter, onSelect: (SearchFilter) -> Unit) {+ androidx.compose.foundation.lazy.LazyRow(+ contentPadding = androidx.compose.foundation.layout.PaddingValues(horizontal = 16.dp),+ horizontalArrangement = Arrangement.spacedBy(8.dp),+ modifier = Modifier.fillMaxWidth().padding(vertical = 8.dp),+ ) {+ val filters = SearchFilter.entries.filter { it != SearchFilter.Podcasts || com.music.spotui.data.api.Features.PODCASTS }+ items(filters.size) { i ->+ val f = filters[i]+ val on = f == selected+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier.height(32.dp).clip(RoundedCornerShape(16.dp))+ .background(if (on) com.music.spotui.ui.theme.AppAccent else Color(0xFF2A2A2A))+ .pressable(0.96f) { onSelect(if (on && f != SearchFilter.Top) SearchFilter.Top else f) }+ .padding(horizontal = 14.dp),+ ) {+ Text(stringResource(f.label), color = if (on) Color.Black else Color.White, fontSize = 14.sp, fontWeight = FontWeight.Medium)+ }+ }+ }+}++/**+ * Interleaves the three result types into one list, weighted toward songs+ * (2 songs per artist+album cycle) so the list reads as mixed rather than+ * grouped, while songs — the most common search intent — stay prominent.+ */+private fun mixSearchResults(results: SearchResults): List<SearchRow> {+ val songs = results.songs.iterator()+ val artists = results.artists.iterator()+ val albums = results.albums.iterator()+ // A few playlists in the mix; the Playlists chip lists them all.+ val playlists = results.playlists.take(5).iterator()+ val out = ArrayList<SearchRow>()+ while (songs.hasNext() || artists.hasNext() || albums.hasNext() || playlists.hasNext()) {+ repeat(2) { if (songs.hasNext()) out += SearchRow.Song(songs.next()) }+ if (artists.hasNext()) out += SearchRow.Artist(artists.next())+ if (albums.hasNext()) out += SearchRow.Album(albums.next())+ if (playlists.hasNext()) out += SearchRow.Playlist(playlists.next())+ }+ return out+}++/** Maps a tapped search-result song to a persisted recent item. */+private fun SongsModel.toRecentItem() = com.music.spotui.data.preferences.RecentItem(+ type = "song",+ key = spotifyTrackId.ifBlank { url },+ name = title,+ singer = singer,+ image = coverUri,+ songId = id,+ songAlbum = album,+ songUrl = url,+ spotifyTrackId = spotifyTrackId,+ explicit = explicit,+ durationMs = durationMs,+)++/** A recent item row (song/artist/album/show the user opened), with remove (x). */+@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun RecentItemRow(+ item: com.music.spotui.data.preferences.RecentItem,+ onClick: () -> Unit,+ onRemove: () -> Unit,+) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.pressable(0.96f) { onClick() }+ .fillMaxWidth()++ .padding(16.dp, 8.dp),+ ) {+ GlideImage(+ modifier = Modifier+ .size(48.dp)+ .clip(RoundedCornerShape(if (item.type == "artist") 100.dp else 6.dp)),+ model = item.image,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Column(+ modifier = Modifier+ .weight(1f)+ .padding(start = 10.dp, end = 8.dp),+ ) {+ Text(text = item.name, color = Color.White, fontSize = 14.sp, fontWeight = FontWeight.Medium, maxLines = 1)+ val subtitle = when (item.type) {+ "song" -> stringResource(R.string.assisted_curation_search_song) + " • ${item.singer}"+ "artist" -> stringResource(R.string.artist_subtitle)+ "album" -> stringResource(R.string.album) + " • ${item.singer}"+ "show" -> stringResource(R.string.album_type_podcast) + (if (item.singer.isNotBlank()) " • ${item.singer}" else "")+ "playlist" -> stringResource(R.string.assisted_curation_search_playlist) + (if (item.singer.isNotBlank()) " • ${item.singer}" else "")+ else -> ""+ }+ Text(text = subtitle, color = Color.Gray, fontSize = 12.sp, fontWeight = FontWeight.Medium, maxLines = 1)+ }+ Icon(+ imageVector = Icons.Default.Close,+ tint = Color(0xFFB3B3B3),+ modifier = Modifier.pressable(0.96f) { onRemove() }+ .size(20.dp)+ ,+ contentDescription = stringResource(R.string.aligned_curation_first_save_default_row_remove_action_description),+ )+ }+}++@OptIn(ExperimentalGlideComposeApi::class, ExperimentalFoundationApi::class)+@Composable+fun SearchSongRow(+ song: SongsModel,+ songList: List<SongsModel>,+ searchViewModel: SearchViewModel,+ onPlayed: () -> Unit = {},+ onLongClick: (() -> Unit)? = null,+) {+ val context = LocalContext.current+ val isLiked = com.music.spotui.di.rememberTrackSaved(song.spotifyTrackId)+ val currentPlayingIndicatorColor =+ if (song.id == searchViewModel.currentSongId.value) Color(AppPalette.toArgb()) else Color.White++ Row(+ horizontalArrangement = Arrangement.SpaceBetween,+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .padding(16.dp, 8.dp)+ .combinedClickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ onLongClick = onLongClick,+ onClick = {+ onPlayed()+ // Start a radio from the tapped track (queue = this song + Spotify+ // recommendations) rather than queuing the whole search list.+ searchViewModel.startRadioFromSong(song)+ SongPlayer.playSong(song.url, context)+ searchViewModel.updateSongState(+ song.coverUri,+ song.title,+ song.singer,+ true,+ song.id,+ 0,+ song.album,+ )+ },+ ),+ ) {+ Row(+ horizontalArrangement = Arrangement.Start,+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.weight(1f).padding(end = 8.dp),+ ) {+ GlideImage(+ modifier = Modifier+ .padding(0.dp, 0.dp, 10.dp, 0.dp)+ .size(48.dp)+ .clip(RoundedCornerShape(6.dp)),+ model = song.coverUri,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Column(modifier = Modifier.weight(1f)) {+ Text(text = song.title, color = currentPlayingIndicatorColor, fontSize = 16.sp, maxLines = 1, overflow = androidx.compose.ui.text.style.TextOverflow.Ellipsis)+ androidx.compose.foundation.layout.Row(verticalAlignment = Alignment.CenterVertically) {+ if (song.explicit) { com.music.spotui.ui.screens.ExplicitBadge(); androidx.compose.foundation.layout.Spacer(Modifier.width(6.dp)) }+ Text(text = stringResource(R.string.assisted_curation_search_song) + " • ${song.singer}", color = Color.Gray, fontSize = 13.sp, maxLines = 1, overflow = androidx.compose.ui.text.style.TextOverflow.Ellipsis)+ }+ }+ }++com.music.spotui.ui.screens.AddButton(song = { song }, liked = isLiked, size = 22.dp) {+ // Spotify library, per track (not the now-playing like state).+ com.music.spotui.di.SongPlayer.setTrackSaved(song.spotifyTrackId, true)+ }+ }+}++@Composable+fun SearchSectionHeader(title: String) {+ Text(+ text = title,+ color = Color.White,+ fontSize = 18.sp,+ fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(16.dp, 18.dp, 16.dp, 4.dp),+ )+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun SearchShowRow(show: com.music.spotui.data.entity.PodcastModel, onClick: () -> Unit) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.pressable(0.96f) { onClick() }+ .fillMaxWidth()+ .padding(16.dp, 8.dp)+ ,+ ) {+ GlideImage(+ modifier = Modifier+ .padding(0.dp, 0.dp, 10.dp, 0.dp)+ .size(48.dp)+ .clip(RoundedCornerShape(6.dp)),+ model = show.coverUri,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Column {+ Text(text = show.name, color = Color.White, fontSize = 14.sp, fontWeight = FontWeight.Medium, maxLines = 1)+ Text(+ text = stringResource(R.string.album_type_podcast) + (if (show.publisher.isNotBlank()) " • ${show.publisher}" else ""),+ color = Color.Gray, fontSize = 12.sp, fontWeight = FontWeight.Medium, maxLines = 1,+ )+ }+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun SearchArtistRow(artist: com.music.spotui.data.entity.ArtistsModel, onClick: () -> Unit) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.pressable(0.96f) { onClick() }+ .fillMaxWidth()+ .padding(16.dp, 8.dp)+ ,+ ) {+ GlideImage(+ modifier = Modifier+ .padding(0.dp, 0.dp, 10.dp, 0.dp)+ .size(48.dp)+ .clip(RoundedCornerShape(100.dp)),+ model = artist.coverUri,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Column {+ Text(text = artist.name, color = Color.White, fontSize = 14.sp, fontWeight = FontWeight.Medium)+ Text(text = stringResource(R.string.artist_subtitle), color = Color.Gray, fontSize = 12.sp, fontWeight = FontWeight.Medium)+ }+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun SearchAlbumRow(album: com.music.spotui.data.entity.AlbumsModel, onClick: () -> Unit) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.pressable(0.96f) { onClick() }+ .fillMaxWidth()+ .padding(16.dp, 8.dp)+ ,+ ) {+ GlideImage(+ modifier = Modifier+ .padding(0.dp, 0.dp, 10.dp, 0.dp)+ .size(48.dp)+ .clip(RoundedCornerShape(6.dp)),+ model = album.coverUri,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Column {+ Text(text = album.name, color = Color.White, fontSize = 14.sp, fontWeight = FontWeight.Medium)+ Text(text = stringResource(R.string.album) + " • ${album.artists}", color = Color.Gray, fontSize = 12.sp, fontWeight = FontWeight.Medium, maxLines = 1)+ }+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+fun SearchPlaylistRow(playlist: com.music.spotui.data.entity.LibraryEntry, onClick: () -> Unit) {+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier.pressable(0.96f) { onClick() }.fillMaxWidth().padding(16.dp, 8.dp),+ ) {+ GlideImage(+ modifier = Modifier.padding(0.dp, 0.dp, 10.dp, 0.dp).size(48.dp).clip(RoundedCornerShape(6.dp)),+ model = playlist.coverUri,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ loading = placeholder(R.drawable.placeholder),+ contentDescription = "",+ )+ Column {+ Text(text = playlist.name, color = Color.White, fontSize = 14.sp, fontWeight = FontWeight.Medium, maxLines = 1)+ Text(text = stringResource(R.string.assisted_curation_search_playlist) ++ (if (playlist.subtitle.isNotBlank()) " • ${playlist.subtitle}" else ""),+ color = Color.Gray, fontSize = 12.sp, fontWeight = FontWeight.Medium, maxLines = 1)+ }+ }+}++/** Genre key of the "New releases" tile, opened in its own screen. */+const val NEW_RELEASES_GENRE = "new-releases"++/** One "Browse all" tile: Spotify's own category (title, colour, artwork). */+private data class BrowseTile(val key: String, val title: String, val color: Color, val image: String)++@Composable+fun BrowseAllSection(onCategoryClick: (genre: String, title: String) -> Unit) {+ val newReleases = stringResource(R.string.browse_new_releases)+ // Spotify's real categories (the Web Player's "Browse all"), New releases first.+ val tiles by androidx.compose.runtime.produceState(initialValue = emptyList<BrowseTile>()) {+ val categories = runCatching { app.myspoti.host.android.MyspotiRuntime.api.home.categories() }.getOrDefault(emptyList())+ value = listOf(BrowseTile(NEW_RELEASES_GENRE, newReleases, Color(0xFFE8115B), "")) ++ categories.filter { com.music.spotui.data.api.Features.PODCASTS || !it.title.contains("odcast", ignoreCase = true) }.map { c ->+ val color = runCatching { Color(android.graphics.Color.parseColor(c.color ?: "#333333")) }.getOrDefault(Color(0xFF333333))+ BrowseTile(c.uri, c.title, color, c.images.firstOrNull()?.url.orEmpty())+ }+ }+ Column(modifier = Modifier.fillMaxWidth()) {+ Text(+ text = stringResource(R.string.browse_all),+ color = Color.White,+ fontSize = 22.sp,+ fontWeight = FontWeight.Bold,+ modifier = Modifier.padding(16.dp, 12.dp, 16.dp, 8.dp),+ )+ tiles.chunked(2).forEach { rowItems ->+ Row(+ modifier = Modifier+ .fillMaxWidth()+ .padding(8.dp, 4.dp),+ horizontalArrangement = Arrangement.spacedBy(12.dp),+ ) {+ rowItems.forEach { t ->+ BrowseCategoryTile(t.title, t.color, t.image, Modifier.weight(1f)) { onCategoryClick(t.key, t.title) }+ }+ // Keep a half-width spacer if the last row has a single tile.+ if (rowItems.size == 1) Spacer(Modifier.weight(1f))+ }+ }+ }+}++@OptIn(ExperimentalGlideComposeApi::class)+@Composable+private fun BrowseCategoryTile(+ name: String,+ color: Color,+ cover: String,+ modifier: Modifier = Modifier,+ onClick: () -> Unit,+) {+ Box(+ modifier = modifier+ .height(96.dp)+ .clip(RoundedCornerShape(8.dp))+ .background(color)+ .clickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ ) { onClick() },+ ) {+ if (cover.isNotBlank()) {+ GlideImage(+ model = cover,+ contentScale = ContentScale.Crop,+ contentDescription = null,+ modifier = Modifier+ .align(Alignment.BottomEnd)+ .size(64.dp)+ .offset(x = 16.dp, y = 10.dp)+ .rotate(25f)+ .clip(RoundedCornerShape(4.dp)),+ )+ }+ Text(+ text = name,+ color = Color.White,+ fontSize = 16.sp,+ fontWeight = FontWeight.Bold,+ maxLines = 2,+ modifier = Modifier.padding(12.dp),+ )+ }+}++@Composable+fun SearchTopBar() {+ Row(horizontalArrangement = Arrangement.Start,+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .padding(16.dp)+ ) {+ Text(text = stringResource(R.string.navigationbar_musicappitems_search_title), color = Color.White, fontSize = 22.sp, fontWeight = FontWeight.Bold)+ //Icon(imageVector = Icons.Default.Person, contentDescription = "", tint = Color.White)+ }++}++@OptIn(ExperimentalMaterial3Api::class)+@Composable+fun SearchStickyBar(+ text: String,+ onFocusChange: (Boolean) -> Unit = {},+ onTextChange: (String) -> Unit,+) {++ Row(verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .padding(10.dp)+ .clip(RoundedCornerShape(10.dp))+ .height(55.dp)+ .background(Color.White)+ .padding(10.dp, 0.dp)+ ){+ Icon(+ painterResource(id = R.drawable.ic_search_big),+ tint = Color.Black,+ contentDescription = "")++ TextField(+ enabled = true,+ modifier = Modifier.onFocusChanged { onFocusChange(it.isFocused) },+ value = text,+ textStyle = TextStyle.Default.copy(fontSize = 16.sp, color = Color.Black, fontWeight = FontWeight(500)),+ colors = TextFieldDefaults.colors(+ unfocusedContainerColor = Color.Transparent,+ disabledContainerColor = Color.Transparent,+ focusedContainerColor = Color.Transparent,+ disabledIndicatorColor = Color.Transparent,+ focusedIndicatorColor = Color.Transparent,+ unfocusedIndicatorColor = Color.Transparent,+ cursorColor = Color.Black++ ),+ singleLine = true,+ onValueChange = onTextChange,+ placeholder = {+ Text(+ textAlign = TextAlign.Center,+ fontWeight = FontWeight.Bold,+ text = stringResource(R.string.search_header_field_hint)++ )+ }+ )+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/ShowScreen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/ShowScreen.ktnew file mode 100644index 00000000..d7a17822--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/ShowScreen.kt@@ -0,0 +1,169 @@+package com.music.spotui.ui.screens++import androidx.compose.ui.res.stringResource++import com.music.spotui.ui.components.pressable+import androidx.compose.foundation.ExperimentalFoundationApi+import androidx.compose.foundation.background+import androidx.compose.foundation.clickable+import androidx.compose.foundation.combinedClickable+import androidx.compose.foundation.interaction.MutableInteractionSource+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Row+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.statusBarsPadding+import androidx.compose.foundation.lazy.LazyColumn+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material.icons.Icons+import androidx.compose.material.icons.automirrored.filled.ArrowBack+import androidx.compose.material3.Icon+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.runtime.LaunchedEffect+import androidx.compose.runtime.collectAsState+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.compose.runtime.remember+import androidx.compose.runtime.setValue+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.toArgb+import androidx.compose.ui.layout.ContentScale+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextOverflow+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import androidx.lifecycle.viewmodel.compose.viewModel+import androidx.navigation.NavController+import com.bumptech.glide.integration.compose.ExperimentalGlideComposeApi+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.ui.components.SongOptionsSheet+import com.bumptech.glide.integration.compose.GlideImage+import com.bumptech.glide.integration.compose.placeholder+import app.myspoti.engine.R+import com.music.spotui.data.api.Response+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.components.Loader+import com.music.spotui.ui.theme.AppBackground+import com.music.spotui.ui.viewmodel.ShowViewModel++@OptIn(ExperimentalGlideComposeApi::class, ExperimentalFoundationApi::class)+@Composable+fun ShowScreen(navController: NavController, showId: String, showName: String = "") {+ val vm: ShowViewModel = viewModel()+ val context = LocalContext.current+ LaunchedEffect(showId) { vm.loadShow(showId) }++ val episodesState by vm.episodes.collectAsState()+ val show by vm.show.collectAsState()+ val episodes = (episodesState as? Response.Success)?.data.orEmpty()++ var menuSong by remember { mutableStateOf<SongsModel?>(null) }+ menuSong?.let { sel ->+ SongOptionsSheet(+ song = sel,+ navController = navController,+ context = context,+ onDismiss = { menuSong = null },+ )+ }++ LazyColumn(+ contentPadding = androidx.compose.foundation.layout.PaddingValues(bottom = 130.dp),+ modifier = Modifier+ .fillMaxSize()+ .background(Color(AppBackground.toArgb()))+ .statusBarsPadding(),+ ) {+ item {+ Icon(+ imageVector = Icons.AutoMirrored.Filled.ArrowBack,+ tint = Color.White,+ contentDescription = stringResource(R.string.accessibility_navigate_back),+ modifier = Modifier.pressable(0.96f) { navController.navigateUp() }+ .padding(16.dp)+ .size(26.dp)+ ,+ )+ }+ item {+ Column(+ horizontalAlignment = Alignment.CenterHorizontally,+ modifier = Modifier.fillMaxWidth().padding(16.dp),+ ) {+ GlideImage(+ model = show?.coverUri ?: episodes.firstOrNull()?.coverUri,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ modifier = Modifier.size(180.dp).clip(RoundedCornerShape(8.dp)),+ contentDescription = null,+ )+ Spacer(Modifier.height(12.dp))+ Text(+ text = show?.name ?: showName,+ color = Color.White,+ fontSize = 22.sp,+ fontWeight = FontWeight.Bold,+ maxLines = 2,+ overflow = TextOverflow.Ellipsis,+ )+ show?.publisher?.takeIf { it.isNotBlank() }?.let {+ Text(it, color = Color(0xFFB3B3B3), fontSize = 13.sp)+ }+ }+ }++ if (episodesState is Response.Loading) {+ item { Loader() }+ }++ items(episodes.size) { i ->+ val ep = episodes[i]+ Row(+ verticalAlignment = Alignment.CenterVertically,+ modifier = Modifier+ .fillMaxWidth()+ .combinedClickable(+ interactionSource = remember { MutableInteractionSource() },+ indication = null,+ onLongClick = { menuSong = ep },+ onClick = {+ vm.updateQueue(listOf(ep))+ SongPlayer.playSong(ep.url, context)+ vm.updateSongState(ep.coverUri, ep.title, ep.singer, true, ep.id, 0, ep.album)+ },+ )+ .padding(16.dp, 10.dp),+ ) {+ GlideImage(+ model = ep.coverUri,+ contentScale = ContentScale.Crop,+ failure = placeholder(R.drawable.placeholder),+ modifier = Modifier.size(48.dp).clip(RoundedCornerShape(4.dp)),+ contentDescription = null,+ )+ Column(modifier = Modifier.padding(start = 12.dp).weight(1f)) {+ Text(+ ep.title,+ color = if (ep.id == vm.currentSongId.value) com.music.spotui.ui.theme.AppAccent else Color.White,+ fontSize = 15.sp,+ fontWeight = FontWeight.SemiBold,+ maxLines = 2,+ overflow = TextOverflow.Ellipsis,+ )+ Text(ep.singer, color = Color(0xFFB3B3B3), fontSize = 12.sp, maxLines = 1)+ }+ }+ }+ item { Spacer(Modifier.height(130.dp)) }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/screens/WelcomeScreen.kt b/base/app/src/main/java/com/music/spotui/ui/screens/WelcomeScreen.ktnew file mode 100644index 00000000..36cb134a--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/screens/WelcomeScreen.kt@@ -0,0 +1,96 @@+package com.music.spotui.ui.screens++import androidx.compose.foundation.Image+import androidx.compose.foundation.background+import androidx.compose.foundation.layout.Arrangement+import androidx.compose.foundation.layout.Box+import androidx.compose.foundation.layout.Column+import androidx.compose.foundation.layout.Spacer+import androidx.compose.foundation.layout.fillMaxSize+import androidx.compose.foundation.layout.fillMaxWidth+import androidx.compose.foundation.layout.height+import androidx.compose.foundation.layout.padding+import androidx.compose.foundation.layout.size+import androidx.compose.foundation.layout.systemBarsPadding+import androidx.compose.foundation.shape.RoundedCornerShape+import androidx.compose.material3.Text+import androidx.compose.runtime.Composable+import androidx.compose.ui.Alignment+import androidx.compose.ui.Modifier+import androidx.compose.ui.draw.clip+import androidx.compose.ui.geometry.Offset+import androidx.compose.ui.graphics.Brush+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.res.painterResource+import androidx.compose.ui.res.stringResource+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.text.style.TextAlign+import androidx.compose.ui.unit.dp+import androidx.compose.ui.unit.sp+import app.myspoti.engine.R+import com.music.spotui.ui.components.pressable+import com.music.spotui.ui.theme.AppBackground+import com.music.spotui.ui.theme.AppSans++/**+ * First screen of a signed-out app: what Myspoti is, then Spotify's own login page+ * (shown by the engine once [onLogin] is tapped).+ */+@Composable+fun WelcomeScreen(onLogin: () -> Unit) {+ Box(+ Modifier+ .fillMaxSize()+ .background(AppBackground)+ .background(+ Brush.radialGradient(+ colors = listOf(Color(0x551ED760), Color.Transparent),+ center = Offset(540f, 380f),+ radius = 1100f,+ ),+ )+ .systemBarsPadding()+ .padding(horizontal = 28.dp, vertical = 24.dp),+ ) {+ Column(+ horizontalAlignment = Alignment.CenterHorizontally,+ verticalArrangement = Arrangement.Center,+ modifier = Modifier.fillMaxWidth().align(Alignment.Center).padding(bottom = 120.dp),+ ) {+ Image(+ painter = painterResource(R.drawable.ic_launcher_foreground),+ contentDescription = null,+ modifier = Modifier.size(132.dp).clip(RoundedCornerShape(36.dp)).background(Color(0xFF181818)),+ )+ Spacer(Modifier.height(28.dp))+ Text("Myspoti", color = Color.White, fontFamily = AppSans, fontWeight = FontWeight.ExtraBold, fontSize = 40.sp)+ Text(+ stringResource(R.string.welcome_tagline),+ color = Color.White.copy(alpha = 0.7f), fontFamily = AppSans, fontSize = 17.sp, lineHeight = 24.sp,+ textAlign = TextAlign.Center, modifier = Modifier.padding(top = 12.dp),+ )+ }+ Column(+ horizontalAlignment = Alignment.CenterHorizontally,+ modifier = Modifier.fillMaxWidth().align(Alignment.BottomCenter),+ ) {+ Box(+ contentAlignment = Alignment.Center,+ modifier = Modifier+ .fillMaxWidth()+ .height(54.dp)+ .pressable(0.96f, onClick = onLogin)+ .clip(RoundedCornerShape(50))+ .background(com.music.spotui.ui.theme.AppAccent),+ ) {+ Text(stringResource(R.string.welcome_login), color = Color.Black, fontFamily = AppSans,+ fontWeight = FontWeight.Bold, fontSize = 17.sp)+ }+ Text(+ stringResource(R.string.welcome_privacy),+ color = Color.White.copy(alpha = 0.5f), fontFamily = AppSans, fontSize = 13.sp, lineHeight = 18.sp,+ textAlign = TextAlign.Center, modifier = Modifier.padding(top = 14.dp),+ )+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/theme/Color.kt b/base/app/src/main/java/com/music/spotui/ui/theme/Color.ktnew file mode 100644index 00000000..4e55a795--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/theme/Color.kt@@ -0,0 +1,16 @@+package com.music.spotui.ui.theme++import androidx.compose.ui.graphics.Color++val Purple80 = Color(0xFFD0BCFF)+val PurpleGrey80 = Color(0xFFCCC2DC)+val Pink80 = Color(0xFFEFB8C8)++val Purple40 = Color(0xFF6650a4)+val PurpleGrey40 = Color(0xFF625b71)+val Pink40 = Color(0xFF7D5260)+val AppBackground: Color get() = if (app.myspoti.power.EnergySettings.oledBlack) Color.Black else Color(0xFF121212)+val GridBackground = Color(0xFF2A2A2A)+/** The accent (Spotify green, or the colour a supporter chose). */+val AppPalette: Color get() = com.music.spotui.data.api.SupportReminder.accentColor+val AppAccent: Color get() = com.music.spotui.data.api.SupportReminder.accentColor\ No newline at end of filediff --git a/base/app/src/main/java/com/music/spotui/ui/theme/Theme.kt b/base/app/src/main/java/com/music/spotui/ui/theme/Theme.ktnew file mode 100644index 00000000..0ccc656b--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/theme/Theme.kt@@ -0,0 +1,94 @@+package com.music.spotui.ui.theme++import android.app.Activity+import android.graphics.Color.toArgb+import android.os.Build+import androidx.compose.foundation.isSystemInDarkTheme+import androidx.compose.material3.MaterialTheme+import androidx.compose.material3.darkColorScheme+import androidx.compose.material3.dynamicDarkColorScheme+import androidx.compose.material3.dynamicLightColorScheme+import androidx.compose.material3.lightColorScheme+import androidx.compose.runtime.Composable+import androidx.compose.runtime.getValue+import androidx.lifecycle.compose.collectAsStateWithLifecycle+import androidx.compose.runtime.SideEffect+import androidx.compose.ui.graphics.Color+import androidx.compose.ui.graphics.toArgb+import androidx.compose.ui.platform.LocalContext+import androidx.compose.ui.platform.LocalView+import androidx.compose.ui.unit.sp+import androidx.core.view.WindowCompat++private val DarkColorScheme = darkColorScheme(+ primary = Purple80,+ secondary = PurpleGrey80,+ tertiary = Pink80,+ background = AppBackground,+)++private val LightColorScheme = lightColorScheme(+ primary = Purple40,+ secondary = PurpleGrey40,+ tertiary = Pink40 ,+ background = AppBackground,+ /* Other default colors to override++ surface = Color(0xFFFFFBFE),+ onPrimary = Color.White,+ onSecondary = Color.White,+ onTertiary = Color.White,+ onBackground = Color(0xFF1C1B1F),+ onSurface = Color(0xFF1C1B1F),+ */+)++@Composable+fun SpotuiTheme(+ darkTheme: Boolean = isSystemInDarkTheme(),+ // Dynamic color is available on Android 12++ dynamicColor: Boolean = true,+ content: @Composable () -> Unit+) {+ val energy by app.myspoti.power.EnergySettings.state.collectAsStateWithLifecycle()+ val policy = energy.policy+ androidx.compose.runtime.LaunchedEffect(policy.videoMaxHeight, policy.allowBackgroundLookups) {+ com.music.spotui.video.MusicVideoController.onEnergyPolicyChanged()+ }+ val colorScheme = when {+ dynamicColor && Build.VERSION.SDK_INT >= Build.VERSION_CODES.S -> {+ val context = LocalContext.current+ if (darkTheme) dynamicDarkColorScheme(context) else dynamicLightColorScheme(context)+ }++ darkTheme -> DarkColorScheme+ else -> LightColorScheme+ }+ val visualScheme = colorScheme.copy(background = AppBackground,+ surface = if (policy.oledBlack) Color.Black else colorScheme.surface)+ val view = LocalView.current+ if (!view.isInEditMode) {+ SideEffect {+ val window = (view.context as Activity).window+ window.attributes = window.attributes.apply { preferredRefreshRate = policy.displayRefreshCap }+ window.statusBarColor = Color.Transparent.toArgb()+ WindowCompat.getInsetsController(window, view).isAppearanceLightStatusBars = false // always-dark app: white status bar icons+ }+ }++ MaterialTheme(+ colorScheme = visualScheme,+ typography = Typography,+ ) {+ // Bare Text() uses LocalTextStyle, which MaterialTheme does NOT derive+ // from the typography — so provide Montserrat as the global default so+ // every screen picks it up without touching each Text call.+ androidx.compose.material3.ProvideTextStyle(+ value = androidx.compose.material3.LocalTextStyle.current.copy(+ fontFamily = Montserrat,+ letterSpacing = (-0.2).sp,+ ),+ content = content,+ )+ }+}\ No newline at end of filediff --git a/base/app/src/main/java/com/music/spotui/ui/theme/Type.kt b/base/app/src/main/java/com/music/spotui/ui/theme/Type.ktnew file mode 100644index 00000000..b714d840--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/theme/Type.kt@@ -0,0 +1,44 @@+package com.music.spotui.ui.theme++import androidx.compose.material3.Typography+import androidx.compose.ui.text.TextStyle+import androidx.compose.ui.text.font.Font+import androidx.compose.ui.text.font.FontFamily+import androidx.compose.ui.text.font.FontWeight+import androidx.compose.ui.unit.sp+import app.myspoti.engine.R++/**+ * UI typeface: Figtree (SIL Open Font License 1.1, licenses/Figtree-OFL.txt), a free+ * geometric grotesque close to the official app's look. One variable font file,+ * each weight picked through its "wght" axis.+ */+@OptIn(androidx.compose.ui.text.ExperimentalTextApi::class)+private fun sans(weight: Int) = Font(+ R.font.app_sans,+ weight = FontWeight(weight),+ variationSettings = androidx.compose.ui.text.font.FontVariation.Settings(+ androidx.compose.ui.text.font.FontVariation.weight(weight),+ ),+)++val AppSans = FontFamily(sans(400), sans(500), sans(600), sans(700), sans(800), sans(900))+/** Headings: the same family, heavier cuts. */+val AppSansTitle = AppSans++// Kept as an alias so existing references (Theme.kt etc.) don't break.+val Montserrat = AppSans++private val base = TextStyle(fontFamily = AppSans)+private val title = TextStyle(fontFamily = AppSansTitle, fontWeight = FontWeight.Bold)++val Typography = Typography(+ displayLarge = title, displayMedium = title, displaySmall = title,+ headlineLarge = title, headlineMedium = title, headlineSmall = title,+ titleLarge = base.copy(fontWeight = FontWeight.Bold),+ titleMedium = base.copy(fontWeight = FontWeight.Bold),+ titleSmall = base.copy(fontWeight = FontWeight.Bold),+ bodyLarge = base.copy(fontSize = 16.sp, lineHeight = 24.sp),+ bodyMedium = base, bodySmall = base,+ labelLarge = base, labelMedium = base, labelSmall = base,+)diff --git a/base/app/src/main/java/com/music/spotui/ui/viewmodel/ArtistViewModel.kt b/base/app/src/main/java/com/music/spotui/ui/viewmodel/ArtistViewModel.ktnew file mode 100644index 00000000..72879b45--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/viewmodel/ArtistViewModel.kt@@ -0,0 +1,94 @@+package com.music.spotui.ui.viewmodel++import com.music.spotui.di.Graph+import androidx.compose.runtime.State+import androidx.lifecycle.ViewModel+import androidx.lifecycle.viewModelScope+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.ArtistOverviewModel+import com.music.spotui.data.entity.ArtistsModel+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.di.CurrentSongState+import com.music.spotui.ui.repository.AppRepository+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.StateFlow+import kotlinx.coroutines.launch++class ArtistViewModel constructor(private val repository: AppRepository = Graph.repository, private val currentSongState: CurrentSongState = Graph.currentSongState) : ViewModel() {++ val currentSongPlayingState: State<Boolean> get() = currentSongState.playingState+ val currentSongId: State<Int> get() = currentSongState.songId+++ private val _songs : MutableStateFlow<Response<List<SongsModel>>> = MutableStateFlow(Response.Loading())+ val songs : StateFlow<Response<List<SongsModel>>> = _songs++ private val _artists : MutableStateFlow<Response<List<ArtistsModel>>> = MutableStateFlow(Response.Loading())+ val artists : StateFlow<Response<List<ArtistsModel>>> = _artists++ private val _overview : MutableStateFlow<Response<ArtistOverviewModel>> = MutableStateFlow(Response.Loading())+ val overview : StateFlow<Response<ArtistOverviewModel>> = _overview++ fun updateQueue(songs: List<SongsModel>) = currentSongState.updateQueue(songs)++ fun updateSongState(coverUri: String, title: String, singer: String, playingState: Boolean, songId :Int, songIndex : Int = 0, album : String = "") {+ currentSongState.updateSongState(coverUri, title, singer, playingState, songId, songIndex, album)+ }++ val likeState = currentSongState.likeState++ fun updateLikeState(likeState : Boolean){+ currentSongState.updateLikeState(likeState)+ }++ private var loadedArtist: String? = null++ // Ids of artists the user follows on Spotify, so the Follow button reflects+ // the real account state (not just follows made from this app).+ private val _followedArtistIds: MutableStateFlow<Set<String>> = MutableStateFlow(emptySet())+ val followedArtistIds: StateFlow<Set<String>> = _followedArtistIds++ // No look-ups at creation: the page loads what it shows (follow state comes from+ // the library check in ArtistScreen).+++ // Loads this artist's top tracks (GraphQL, not rate-limited). Called by the+ // screen with the artist name it was opened for.+ fun loadArtistSongs(artistName: String) {+ if (loadedArtist == artistName) return+ loadedArtist = artistName+ viewModelScope.launch(Dispatchers.IO) {+ repository.provideArtistSongs(artistName).collect { songs ->+ _songs.value = songs as Response<List<SongsModel>>+ }+ }+ }++ private var loadedOverview: String? = null++ // Loads the full Spotify-style artist page (header, monthly listeners, bio,+ // popular tracks, discography, related artists) in one GQL round-trip.+ // Passing the exact Spotify artist id avoids the fuzzy name search.+ fun loadArtistOverview(artistName: String, artistId: String = "") {+ val key = artistId.ifBlank { artistName }+ if (loadedOverview == key) return+ loadedOverview = key+ viewModelScope.launch(Dispatchers.IO) {+ repository.provideArtistOverview(artistName, artistId).collect { overview ->+ _overview.value = overview+ // Keep the legacy songs flow in sync (popular tracks) so any+ // other consumer and the play/queue helpers still work.+ if (overview is Response.Success) {+ _songs.value = Response.Success(overview.data.topTracks.map { it.song })+ }+ }+ }+ }++ private fun fetchArtists() = viewModelScope.launch(Dispatchers.IO) {+ repository.provideArtists().collect{ artists ->+ _artists.value = artists as Response<List<ArtistsModel>>+ }+ }+}\ No newline at end of filediff --git a/base/app/src/main/java/com/music/spotui/ui/viewmodel/CategoryViewModel.kt b/base/app/src/main/java/com/music/spotui/ui/viewmodel/CategoryViewModel.ktnew file mode 100644index 00000000..ca0f9c1a--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/viewmodel/CategoryViewModel.kt@@ -0,0 +1,28 @@+package com.music.spotui.ui.viewmodel++import com.music.spotui.di.Graph+import androidx.lifecycle.ViewModel+import androidx.lifecycle.viewModelScope+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.LibraryEntry+import com.music.spotui.ui.repository.AppRepository+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.StateFlow+import kotlinx.coroutines.launch++class CategoryViewModel constructor(private val repository: AppRepository = Graph.repository) : ViewModel() {++ private val _playlists: MutableStateFlow<Response<List<LibraryEntry>>> = MutableStateFlow(Response.Loading())+ val playlists: StateFlow<Response<List<LibraryEntry>>> = _playlists++ private var genreKey: String? = null++ fun load(genre: String) {+ if (genreKey == genre) return+ genreKey = genre+ viewModelScope.launch(Dispatchers.IO) {+ repository.provideCategoryPlaylists(genre).collect { _playlists.value = it }+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/viewmodel/HomeViewModel.kt b/base/app/src/main/java/com/music/spotui/ui/viewmodel/HomeViewModel.ktnew file mode 100644index 00000000..d7dabfb9--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/viewmodel/HomeViewModel.kt@@ -0,0 +1,41 @@+package com.music.spotui.ui.viewmodel++import com.music.spotui.di.Graph+import androidx.lifecycle.ViewModel+import androidx.lifecycle.viewModelScope+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.HomeFeedModel+import com.music.spotui.ui.repository.AppRepository+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.StateFlow+import kotlinx.coroutines.launch++class HomeViewModel constructor(private val repository: AppRepository = Graph.repository) : ViewModel() {++ private val _home : MutableStateFlow<Response<HomeFeedModel>> = MutableStateFlow(Response.Loading())+ val home : StateFlow<Response<HomeFeedModel>> = _home++ /** Selected home chip ("" = All). */+ val facet = androidx.compose.runtime.mutableStateOf("")+ private var homeJob: kotlinx.coroutines.Job? = null++ init {+ fetchHome()+ }++ fun selectFacet(f: String) {+ facet.value = if (facet.value == f) "" else f+ fetchHome()+ }++ private fun fetchHome() {+ homeJob?.cancel()+ val f = facet.value+ homeJob = viewModelScope.launch(Dispatchers.IO) {+ repository.provideHomeFeed(f).collect { feed ->+ _home.value = feed+ }+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/viewmodel/LibraryViewModel.kt b/base/app/src/main/java/com/music/spotui/ui/viewmodel/LibraryViewModel.ktnew file mode 100644index 00000000..c66ba9fd--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/viewmodel/LibraryViewModel.kt@@ -0,0 +1,70 @@+package com.music.spotui.ui.viewmodel++import com.music.spotui.di.Graph+import androidx.lifecycle.ViewModel+import androidx.lifecycle.viewModelScope+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.AccountModel+import com.music.spotui.data.entity.LibraryEntry+import com.music.spotui.data.preferences.cacheFollowedArtists+import com.music.spotui.data.preferences.cacheLibraryEntries+import com.music.spotui.data.preferences.getCachedFollowedArtists+import com.music.spotui.data.preferences.getCachedLibraryEntries+import com.music.spotui.ui.repository.AppRepository+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.StateFlow+import kotlinx.coroutines.launch++class LibraryViewModel constructor(+ private val repository: AppRepository = Graph.repository,+ private val context: android.content.Context = Graph.app,+) : ViewModel() {++ private val _entries: MutableStateFlow<Response<List<LibraryEntry>>> = MutableStateFlow(Response.Loading())+ val entries: StateFlow<Response<List<LibraryEntry>>> = _entries++ private val _account: MutableStateFlow<Response<AccountModel>> = MutableStateFlow(Response.Loading())+ val account: StateFlow<Response<AccountModel>> = _account++ private val _followedArtists: MutableStateFlow<List<com.music.spotui.data.entity.ArtistsModel>> =+ MutableStateFlow(emptyList())+ val followedArtists: StateFlow<List<com.music.spotui.data.entity.ArtistsModel>> = _followedArtists++ init {+ // Seed UI with the last-seen library immediately so it's visible offline.+ val cached = getCachedLibraryEntries(context)+ if (cached.isNotEmpty()) _entries.value = Response.Success(cached)+ val cachedArtists = getCachedFollowedArtists(context)+ if (cachedArtists.isNotEmpty()) _followedArtists.value = cachedArtists++ load()+ loadAccount()+ loadFollowedArtists()+ }++ fun load() = viewModelScope.launch(Dispatchers.IO) {+ repository.provideLibrary().collect { response ->+ // Offline: keep the saved library instead of replacing it with a+ // spinner/error, so downloads stay reachable after a restart (#51).+ if (response !is Response.Success && _entries.value is Response.Success) return@collect+ // Nothing saved yet and no network: offer just the downloads (not cached).+ if (response is Response.Error) {+ _entries.value = Response.Success(emptyList())+ return@collect+ }+ _entries.value = response+ if (response is Response.Success) cacheLibraryEntries(context, response.data)+ }+ }++ private fun loadFollowedArtists() = viewModelScope.launch(Dispatchers.IO) {+ val artists = repository.provideFollowedArtists()+ _followedArtists.value = artists+ if (artists.isNotEmpty()) cacheFollowedArtists(context, artists)+ }++ private fun loadAccount() = viewModelScope.launch(Dispatchers.IO) {+ repository.provideAccount().collect { _account.value = it }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/viewmodel/LyricsViewModel.kt b/base/app/src/main/java/com/music/spotui/ui/viewmodel/LyricsViewModel.ktnew file mode 100644index 00000000..6ec951c2--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/viewmodel/LyricsViewModel.kt@@ -0,0 +1,138 @@+package com.music.spotui.ui.viewmodel++import androidx.lifecycle.ViewModel+import androidx.lifecycle.viewModelScope+import com.music.spotui.data.api.LyricTranslate+import com.music.spotui.data.api.LyricsApi+import com.music.spotui.data.entity.Lyrics+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.StateFlow+import kotlinx.coroutines.launch+import kotlinx.coroutines.withContext++class LyricsViewModel constructor() : ViewModel() {++ sealed class State {+ object Loading : State()+ data class Loaded(+ val lyrics: Lyrics,+ val showTranslation: Boolean = false,+ val translations: List<String>? = null,+ val translationLanguage: String? = null,+ val sourceLanguage: String? = null,+ val translating: Boolean = false,+ val translationChecked: Boolean = false,+ val translationRequested: Boolean = false,+ ) : State()+ object NotFound : State()+ }++ private val _state = MutableStateFlow<State>(State.Loading)+ val state: StateFlow<State> = _state++ private var loadedKey: String? = null++ fun load(track: LyricsApi.Track, force: Boolean = false) {+ val key = track.key+ if (!force && loadedKey == key && _state.value !is State.NotFound) return+ loadedKey = key+ if (force) LyricsApi.forget(track)+ // Already resolved (prefetched while the track started): no loading flash.+ LyricsApi.cached(track)?.let { _state.value = loadedState(it); return }+ _state.value = State.Loading+ viewModelScope.launch(Dispatchers.IO) {+ val lyrics = LyricsApi.fetch(track)+ withContext(Dispatchers.Main) {+ // A skip during the fetch: don't show the previous song's lyrics.+ if (loadedKey != key) return@withContext+ _state.value = if (lyrics == null || lyrics.isEmpty) State.NotFound else loadedState(lyrics)+ }+ }+ }++ private fun loadedState(lyrics: com.music.spotui.data.entity.Lyrics) = State.Loaded(+ lyrics = lyrics,+ sourceLanguage = lyrics.language,+ translationChecked = lyrics.language != null,+ )++ fun toggleTranslation(targetLang: String) {+ val cur = _state.value as? State.Loaded ?: return+ if (cur.showTranslation) {+ _state.value = cur.copy(showTranslation = false)+ return+ }+ if (cur.translationLanguage == targetLang) {+ _state.value = cur.copy(showTranslation = true)+ return+ }+ if (cur.translating) {+ _state.value = cur.copy(translationRequested = true)+ return+ }+ translate(cur, targetLang, showWhenDone = true)+ }++ fun prepareTranslation(targetLang: String) {+ val cur = _state.value as? State.Loaded ?: return+ if (cur.translating || cur.translationLanguage == targetLang) return+ if (sameLanguage(cur.sourceLanguage, targetLang)) return+ translate(cur, targetLang, showWhenDone = false)+ }++ private fun translate(cur: State.Loaded, targetLang: String, showWhenDone: Boolean) {+ _state.value = cur.copy(+ translating = true,+ translationRequested = showWhenDone,+ )+ viewModelScope.launch(Dispatchers.IO) {+ val lines = cur.lyrics.lines.map { it.text }+ val detectedLanguage = cur.sourceLanguage+ ?: LyricTranslate.detectLanguage(lines, targetLang)+ if (detectedLanguage != null) {+ val matchesTarget = sameLanguage(detectedLanguage, targetLang)+ withContext(Dispatchers.Main) {+ val latest = _state.value as? State.Loaded ?: return@withContext+ if (latest.lyrics == cur.lyrics) {+ _state.value = latest.copy(+ translationChecked = true,+ sourceLanguage = detectedLanguage,+ translating = !matchesTarget,+ translationRequested = latest.translationRequested && !matchesTarget,+ )+ }+ }+ if (matchesTarget) return@launch+ }+ val result = LyricTranslate.translateLines(lines, targetLang)+ withContext(Dispatchers.Main) {+ val latest = _state.value as? State.Loaded ?: return@withContext+ if (latest.lyrics != cur.lyrics) return@withContext+ if (result == null) {+ _state.value = latest.copy(+ translating = false,+ translationChecked = true,+ showTranslation = false,+ translationRequested = false,+ )+ return@withContext+ }+ _state.value = latest.copy(+ translating = false,+ translationChecked = true,+ showTranslation = latest.translationRequested &&+ !sameLanguage(result.sourceLanguage, targetLang),+ translationRequested = false,+ translations = result.lines,+ translationLanguage = targetLang,+ sourceLanguage = result.sourceLanguage,+ )+ }+ }+ }++ private fun sameLanguage(source: String?, target: String): Boolean =+ source?.substringBefore('-')+ ?.equals(target.substringBefore('-'), ignoreCase = true) == true+}diff --git a/base/app/src/main/java/com/music/spotui/ui/viewmodel/PlayerViewModel.kt b/base/app/src/main/java/com/music/spotui/ui/viewmodel/PlayerViewModel.ktnew file mode 100644index 00000000..0f867a06--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/viewmodel/PlayerViewModel.kt@@ -0,0 +1,238 @@+package com.music.spotui.ui.viewmodel++import com.music.spotui.di.Graph+import android.content.Context+import androidx.compose.runtime.State+import androidx.compose.runtime.getValue+import androidx.compose.runtime.mutableStateOf+import androidx.lifecycle.ViewModel+import androidx.lifecycle.viewModelScope+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.di.CurrentSongState+import com.music.spotui.di.SongPlayer+import com.music.spotui.ui.navigation.artistRoute+import com.music.spotui.ui.repository.AppRepository+import kotlinx.coroutines.CancellationException+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.Job+import kotlinx.coroutines.delay+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.StateFlow+import kotlinx.coroutines.launch+import kotlinx.coroutines.withContext+import java.util.concurrent.TimeUnit++class PlayerViewModel constructor(private val currentSongState: CurrentSongState = Graph.currentSongState, private val repository: AppRepository = Graph.repository) : ViewModel(){++ val currentSongTitle: State<String> get() = currentSongState.title+ val currentSongSinger: State<String> get() = currentSongState.singer+ val currentSongCoverUri: State<String> get() = currentSongState.coverUri+ val currentSongPlayingState: State<Boolean> get() = currentSongState.playingState+ val currentSongIndex : State<Int> get() = currentSongState.songIndex+ val currentSongAlbum : State<String> get() = currentSongState.album++ val currentSongId : State<Int> get() = currentSongState.songId++ val queue : State<List<SongsModel>> get() = currentSongState.queue++ fun updateQueue(songs: List<SongsModel>) = currentSongState.updateQueue(songs)++ /** "Play next" / "Add to queue": Spotify's own queue. */+ fun playNext(song: SongsModel) = SongPlayer.playNext(song.spotifyTrackId)++ fun addToQueue(song: SongsModel): Boolean {+ if (song.spotifyTrackId.isBlank()) return false+ SongPlayer.addToQueue(song.spotifyTrackId)+ return true+ }+++ val shuffleState = currentSongState.shuffle+ val repeatState = currentSongState.repeat+ val likeState = currentSongState.likeState+++ private val _songs : MutableStateFlow<Response<List<SongsModel>>> = MutableStateFlow(Response.Loading())+ val songs : StateFlow<Response<List<SongsModel>>> = _songs++ val playingArtist by mutableStateOf(currentSongSinger.value)+++++ //val songsResponse = (songs.value as Response.Success).data++ // Resolve where we currently are in the queue. The stored index can be stale+ // (e.g. queue swapped out), so match by song id first and fall back to the index.+ private fun currentPositionIn(queueSongs: List<SongsModel>): Int {+ val byId = queueSongs.indexOfFirst { it.id == currentSongId.value }+ if (byId >= 0) return byId+ return currentSongIndex.value.coerceIn(0, queueSongs.size - 1)+ }++ // Spotify owns the queue (context + autoplay): skip in the engine.+ fun playNextSongs(queueSongs : List<SongsModel>, context: Context) {+ SongPlayer.swipeNext()+ }++ /**+ * Opens the artist page for a track: resolves the EXACT artist (name + id)+ * from the track's Spotify id when available, so a display name like "RAM"+ * can't fuzzy-match to "Rammstein". Falls back to the display name.+ */+ // Associate every Canvas result with the confirmed track that requested it.+ private val canvasRequests = CanvasRequests()+ private val _canvasState = mutableStateOf(CanvasTrackState())+ internal val canvasState: State<CanvasTrackState> get() = _canvasState+ private var canvasJob: Job? = null++ fun loadCanvas(trackId: String, allowFetch: Boolean = true) {+ val request = canvasRequests.select(trackId, allowFetch) ?: return+ canvasJob?.cancel()+ canvasJob = null+ _canvasState.value = canvasRequests.state+ if (!request.fetch) return+ canvasJob = viewModelScope.launch {+ try {+ val url = withContext(Dispatchers.IO) { repository.provideCanvasUrl(request.trackId) }+ if (canvasRequests.complete(request, url)) _canvasState.value = canvasRequests.state+ } catch (cancelled: CancellationException) {+ throw cancelled+ } catch (_: Exception) {+ // A transient network/token failure falls back to the artwork.+ if (canvasRequests.fail(request)) _canvasState.value = canvasRequests.state+ } finally {+ if (canvasRequests.owns(request)) canvasJob = null+ }+ }+ }++ /** "Go to song radio": opens the track's radio, Spotify's station playlist. */+ fun goToSongRadio(trackId: String, title: String, navigate: (route: String) -> Unit, onFailed: () -> Unit) {+ viewModelScope.launch {+ val id = com.music.spotui.di.Graph.api.radioPlaylistId("spotify:track:$trackId")+ if (id.isNullOrBlank()) onFailed()+ else navigate(com.music.spotui.ui.navigation.playlistRoute(id, title))+ }+ }++ fun goToArtist(trackId: String, fallbackName: String, navigate: (route: String) -> Unit) {+ viewModelScope.launch {+ val route = withContext(Dispatchers.IO) {+ val artist = if (trackId.isNotBlank())+ runCatching { app.myspoti.host.android.MyspotiRuntime.api.catalog.track("spotify:track:$trackId") }.getOrNull()?.artists?.firstOrNull()+ else null+ artistRoute(+ artist?.name?.ifBlank { null } ?: fallbackName.substringBefore(",").trim(),+ artist?.uri?.substringAfterLast(':').orEmpty(),+ )+ }+ navigate(route)+ }+ }++ /**+ * Play the track at an absolute [index] in [queueSongs]. Used by the now-playing+ * swipe pager, where the artwork follows the finger and settles on a chosen page.+ * No-op if [index] is already the current track (prevents a feedback replay when+ * the pager is merely snapping to reflect an external track change).+ */+ fun playSongAt(queueSongs: List<SongsModel>, index: Int, context: Context) {+ if (index !in queueSongs.indices) return+ val song = queueSongs[index]+ if (song.id == currentSongId.value) return+ updateSongState(song.coverUri, song.title, song.singer, true, song.id, index, song.album)+ SongPlayer.playSong(song.url, context)+ }++ fun playPreviousSong(queueSongs : List<SongsModel>, context: Context) {+ SongPlayer.previous()+ }++ private fun fetchSongs() = viewModelScope.launch(Dispatchers.IO) {++ repository.provideSongs().collect { songs ->+ _songs.value = songs as Response<List<SongsModel>>++ }+ }+ fun formatDuration(durationMillis: Long): String {+ val minutes = TimeUnit.MILLISECONDS.toMinutes(durationMillis)+ val seconds = TimeUnit.MILLISECONDS.toSeconds(durationMillis) - TimeUnit.MINUTES.toSeconds(minutes)+ return String.format("%01d:%02d", minutes, seconds)+ }+ fun updateSongState(coverUri: String, title: String, singer: String, playingState: Boolean, songId : Int, songIndex : Int = 0, album : String = "") {+ currentSongState.updateSongState(coverUri, title, singer, playingState, songId, songIndex, album)+ }++ // Shuffle / repeat / like are Spotify's: toggle them in the engine and show+ // the new value right away (the engine status confirms it shortly after).+ fun updateShuffleState(shuffleState : Boolean){+ SongPlayer.setShuffle(shuffleState)+ currentSongState.shuffle.value = shuffleState+ }+ fun updateRepeatState(repeatState : Boolean){+ SongPlayer.setRepeat(repeatState)+ currentSongState.updateRepeatState(repeatState)+ }+ fun updateLikeState(likeState : Boolean){+ SongPlayer.setLiked(likeState)+ }+}+++internal fun confirmedTrackIdFromUri(uri: String): String =+ if (uri.startsWith("spotify:track:")) uri.removePrefix("spotify:track:") else ""++/** CurrentSongState uses this canonical id after the engine confirms a track. */+internal fun confirmedTrackIdForDisplay(uri: String, displayedSongId: Int): String {+ val trackId = confirmedTrackIdFromUri(uri)+ val confirmedSongId = ("track:$trackId").hashCode() and 0x7fffffff+ return trackId.takeIf { it.isNotBlank() && confirmedSongId == displayedSongId }.orEmpty()+}++internal data class CanvasTrackState(val trackId: String = "", val url: String? = null)+internal data class CanvasRequest(val generation: Long, val trackId: String, val fetch: Boolean)++/** Main-thread request ownership; generations also distinguish a replay of the same id. */+internal class CanvasRequests {+ var state = CanvasTrackState()+ private set+ private var generation = 0L+ private var loading = false+ private var resolved = false++ fun select(trackId: String, allowFetch: Boolean = true): CanvasRequest? {+ val changed = trackId != state.trackId+ val fetch = trackId.isNotBlank() && allowFetch && (changed || (!loading && !resolved))+ val stopLoading = !allowFetch && loading+ if (!changed && !fetch && !stopLoading) return null+ generation+++ if (changed) {+ state = CanvasTrackState(trackId)+ resolved = false+ }+ loading = fetch+ return CanvasRequest(generation, trackId, fetch)+ }++ fun owns(request: CanvasRequest): Boolean =+ request.generation == generation && request.trackId == state.trackId++ fun complete(request: CanvasRequest, url: String?): Boolean {+ if (!owns(request) || !request.fetch || !loading) return false+ state = CanvasTrackState(request.trackId, url?.takeIf { it.isNotBlank() })+ loading = false+ resolved = true+ return true+ }++ fun fail(request: CanvasRequest): Boolean {+ if (!owns(request) || !request.fetch || !loading) return false+ state = CanvasTrackState(request.trackId)+ loading = false+ resolved = false+ return true+ }+}diff --git a/base/app/src/main/java/com/music/spotui/ui/viewmodel/SearchViewModel.kt b/base/app/src/main/java/com/music/spotui/ui/viewmodel/SearchViewModel.ktnew file mode 100644index 00000000..dd2feace--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/viewmodel/SearchViewModel.kt@@ -0,0 +1,87 @@+package com.music.spotui.ui.viewmodel++import com.music.spotui.di.Graph+import androidx.compose.runtime.State+import androidx.lifecycle.ViewModel+import androidx.lifecycle.viewModelScope+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.SearchResults+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.di.CurrentSongState+import com.music.spotui.ui.repository.AppRepository+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.Job+import kotlinx.coroutines.delay+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.StateFlow+import kotlinx.coroutines.launch++class SearchViewModel constructor(private val repository: AppRepository = Graph.repository, private val currentSongState: CurrentSongState = Graph.currentSongState) : ViewModel() {++ private val _songs : MutableStateFlow<Response<List<SongsModel>>> = MutableStateFlow(Response.Loading())+ val songs : StateFlow<Response<List<SongsModel>>> = _songs++ private val _results : MutableStateFlow<Response<SearchResults>> = MutableStateFlow(Response.Success(SearchResults()))+ val results : StateFlow<Response<SearchResults>> = _results++ val likeState = currentSongState.likeState++ val currentSongId: State<Int> get() = currentSongState.songId+++ fun updateLikeState(likeState : Boolean){+ currentSongState.updateLikeState(likeState)+ }++ private var searchJob: Job? = null++ init {+ // Start empty — results come from live searches, not the rate-limited+ // personalized top-tracks feed (which returned 429 and blanked the screen).+ _songs.value = Response.Success(emptyList())+ }++ fun updateQueue(songs: List<SongsModel>) = currentSongState.updateQueue(songs)++ /**+ * Start playback of a single search result as a *radio*, the way Spotify does:+ * the queue becomes just this track, then Spotify-recommended tracks (seeded from+ * it) are appended as they load — instead of queuing the rest of the search list+ * (which made playback "just go down the search results"). The append is skipped+ * if the user has since started something else.+ */+ fun startRadioFromSong(song: SongsModel) {+ currentSongState.updateQueue(listOf(song))+ val seed = song.spotifyTrackId+ if (seed.isBlank()) return+ viewModelScope.launch(Dispatchers.IO) {+ val recs = repository.provideRecommendations(listOf(seed))+ val current = currentSongState.queue.value+ // Only extend if this radio is still the active queue (user didn't tap away).+ if (current.size == 1 && current.first().id == song.id) {+ val fresh = recs.filter { it.id != song.id }+ if (fresh.isNotEmpty()) currentSongState.updateQueue(current + fresh)+ }+ }+ }++ fun updateSongState(coverUri: String, title: String, singer: String, playingState: Boolean, songId : Int, songIndex : Int = 0, album : String = "") {+ currentSongState.updateSongState(coverUri, title, singer, playingState, songId, songIndex, album)+ }++ fun search(query: String) {+ searchJob?.cancel()+ searchJob = viewModelScope.launch(Dispatchers.IO) {+ delay(150) // short debounce for snappy real-time results+ repository.searchEverything(query).collect { result ->+ _results.value = result+ // Keep the legacy songs flow in sync for any remaining consumers.+ _songs.value = when (result) {+ is Response.Success -> Response.Success(result.data.songs)+ is Response.Error -> Response.Error(result.error)+ is Response.Loading -> Response.Loading()+ }+ }+ }+ }+}\ No newline at end of filediff --git a/base/app/src/main/java/com/music/spotui/ui/viewmodel/ShowViewModel.kt b/base/app/src/main/java/com/music/spotui/ui/viewmodel/ShowViewModel.ktnew file mode 100644index 00000000..6ffddcae--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/ui/viewmodel/ShowViewModel.kt@@ -0,0 +1,51 @@+package com.music.spotui.ui.viewmodel++import com.music.spotui.di.Graph+import androidx.compose.runtime.State+import androidx.lifecycle.ViewModel+import androidx.lifecycle.viewModelScope+import com.music.spotui.data.api.Response+import com.music.spotui.data.entity.PodcastModel+import com.music.spotui.data.entity.SongsModel+import com.music.spotui.di.CurrentSongState+import com.music.spotui.ui.repository.AppRepository+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.StateFlow+import kotlinx.coroutines.launch++class ShowViewModel constructor(+ private val repository: AppRepository = Graph.repository,+ private val currentSongState: CurrentSongState = Graph.currentSongState,+) : ViewModel() {++ val currentSongPlayingState: State<Boolean> get() = currentSongState.playingState+ val currentSongId: State<Int> get() = currentSongState.songId++ private val _episodes: MutableStateFlow<Response<List<SongsModel>>> = MutableStateFlow(Response.Loading())+ val episodes: StateFlow<Response<List<SongsModel>>> = _episodes++ private val _show: MutableStateFlow<PodcastModel?> = MutableStateFlow(null)+ val show: StateFlow<PodcastModel?> = _show++ val queue: State<List<SongsModel>> get() = currentSongState.queue++ fun updateQueue(songs: List<SongsModel>) = currentSongState.updateQueue(songs)++ fun updateSongState(coverUri: String, title: String, singer: String, playingState: Boolean, songId: Int, songIndex: Int = 0, album: String = "") {+ currentSongState.updateSongState(coverUri, title, singer, playingState, songId, songIndex, album)+ }++ private var showKey: String? = null++ fun loadShow(showId: String) {+ if (showKey == showId) return+ showKey = showId+ viewModelScope.launch(Dispatchers.IO) {+ _show.value = repository.provideShow(showId)+ }+ viewModelScope.launch(Dispatchers.IO) {+ repository.provideShowEpisodes(showId).collect { _episodes.value = it }+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/video/AudioAlign.kt b/base/app/src/main/java/com/music/spotui/video/AudioAlign.ktnew file mode 100644index 00000000..7a412e58--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/video/AudioAlign.kt@@ -0,0 +1,429 @@+package com.music.spotui.video++import android.media.MediaCodec+import android.media.MediaExtractor+import android.media.MediaFormat+import kotlinx.coroutines.currentCoroutineContext+import kotlinx.coroutines.ensureActive+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.async+import kotlinx.coroutines.awaitAll+import kotlinx.coroutines.coroutineScope+import java.io.File+import java.nio.ByteOrder+import kotlin.math.PI+import kotlin.math.abs+import kotlin.math.cos+import kotlin.math.ln+import kotlin.math.max+import kotlin.math.min+import kotlin.math.sin+import kotlin.math.sqrt++/**+ * Song time → music video time, found by aligning the two audio tracks (the clip's+ * soundtrack is the song, plus intros, skits or cuts).+ *+ * Features: spectral flux in 32 log-spaced bands (80 Hz–5 kHz), 20 ms hop, z-scored.+ * Song windows of 6 s (every 3 s) are located in the video by normalised+ * cross-correlation; a dynamic-programming pass keeps a continuous path (the video+ * only moves forward, offsets change rarely), which drops the false matches of+ * repeated choruses. Consecutive windows with the same offset form the segments.+ */+object AudioAlign {+ private const val SR = 11025+ private const val HOP = 220 // 19.95 ms+ private const val N = 1024+ private const val BANDS = 32+ private const val FRAME_S = HOP.toDouble() / SR++ data class Segment(val songStartMs: Long, val songEndMs: Long, val offsetMs: Long)++ /** Piecewise-constant map; outside the segments the nearest one applies. */+ data class TimeMap(val segments: List<Segment>, val score: Double) {+ fun toVideo(songMs: Long): Long {+ if (segments.isEmpty()) return songMs+ val s = segments.firstOrNull { songMs >= it.songStartMs && songMs < it.songEndMs }+ ?: segments.minBy { min(abs(songMs - it.songStartMs), abs(songMs - it.songEndMs)) }+ return songMs + s.offsetMs+ }++ /** Video time → song time (inverse map; in a video-only part, its nearest song time). */+ fun toSong(videoMs: Long): Long {+ if (segments.isEmpty()) return videoMs+ val s = segments.firstOrNull { videoMs - it.offsetMs >= it.songStartMs && videoMs - it.offsetMs < it.songEndMs }+ ?: segments.minBy { seg ->+ val t = videoMs - seg.offsetMs+ if (t < seg.songStartMs) seg.songStartMs - t else if (t >= seg.songEndMs) t - seg.songEndMs else 0L+ }+ return (videoMs - s.offsetMs).coerceIn(s.songStartMs, if (s.songEndMs == Long.MAX_VALUE) Long.MAX_VALUE else s.songEndMs - 1)+ .coerceAtLeast(0)+ }+ }++ // ── Decoding ──++ /**+ * Decodes [file] to mono float PCM at 11025 Hz, resampling on the fly (box+ * low-pass + nearest sample) so a long clip never sits in memory at 48 kHz.+ */+ fun decode(file: File, maxSeconds: Int = 0): FloatArray {+ val ex = MediaExtractor()+ var decoderToRelease: MediaCodec? = null+ var threadToStop: android.os.HandlerThread? = null+ try {+ ex.setDataSource(file.absolutePath)+ val track = (0 until ex.trackCount).first { ex.getTrackFormat(it).getString(MediaFormat.KEY_MIME)!!.startsWith("audio/") }+ ex.selectTrack(track)+ val fmt = ex.getTrackFormat(track)+ val durUs = if (fmt.containsKey(MediaFormat.KEY_DURATION)) fmt.getLong(MediaFormat.KEY_DURATION) else 0L+ val out = Resampler(fmt.getInteger(MediaFormat.KEY_SAMPLE_RATE), decodeCapacity(durUs, maxSeconds))+ val codec = MediaCodec.createDecoderByType(fmt.getString(MediaFormat.KEY_MIME)!!).also { decoderToRelease = it }+ val codecName = codec.name+ // Asynchronous mode: the codec pipelines its buffers instead of answering one+ // frame per round trip (20 ms Opus frames made the synchronous loop crawl).+ val thread = android.os.HandlerThread("mv-decode").also { threadToStop = it; it.start() }+ val done = java.util.concurrent.CountDownLatch(1)+ var failure: Throwable? = null+ var channels = fmt.getInteger(MediaFormat.KEY_CHANNEL_COUNT)+ var isFloat = false+ var pcm = ShortArray(16384)+ var floatPcm = FloatArray(0)+ var inputDone = false+ val t0 = System.nanoTime()+ codec.setCallback(object : MediaCodec.Callback() {+ override fun onInputBufferAvailable(c: MediaCodec, index: Int) {+ if (inputDone) return+ if (maxSeconds > 0 && out.size() >= maxSeconds * SR) {+ // Enough audio for a first alignment: stop here.+ inputDone = true+ done.countDown()+ return+ }+ try {+ val n = ex.readSampleData(c.getInputBuffer(index)!!, 0)+ if (n < 0) {+ c.queueInputBuffer(index, 0, 0, 0, MediaCodec.BUFFER_FLAG_END_OF_STREAM)+ inputDone = true+ } else {+ c.queueInputBuffer(index, 0, n, ex.sampleTime, 0)+ ex.advance()+ }+ } catch (t: Throwable) { failure = t; done.countDown() }+ }++ override fun onOutputBufferAvailable(c: MediaCodec, index: Int, info: MediaCodec.BufferInfo) {+ try {+ val bb = c.getOutputBuffer(index)!!.order(ByteOrder.nativeOrder())+ if (isFloat) {+ val count = info.size / 4+ if (floatPcm.size < count) floatPcm = FloatArray(count)+ bb.asFloatBuffer().get(floatPcm, 0, count)+ out.pushInterleavedFloat(floatPcm, count, channels)+ } else {+ val count = info.size / 2+ if (pcm.size < count) pcm = ShortArray(count)+ bb.asShortBuffer().get(pcm, 0, count)+ out.pushInterleaved(pcm, count, channels)+ }+ c.releaseOutputBuffer(index, false)+ if (info.flags and MediaCodec.BUFFER_FLAG_END_OF_STREAM != 0) done.countDown()+ } catch (t: Throwable) { failure = t; done.countDown() }+ }++ override fun onOutputFormatChanged(c: MediaCodec, f: MediaFormat) {+ out.setRate(f.getInteger(MediaFormat.KEY_SAMPLE_RATE))+ channels = f.getInteger(MediaFormat.KEY_CHANNEL_COUNT)+ isFloat = f.containsKey(MediaFormat.KEY_PCM_ENCODING) &&+ f.getInteger(MediaFormat.KEY_PCM_ENCODING) == android.media.AudioFormat.ENCODING_PCM_FLOAT+ }++ override fun onError(c: MediaCodec, e: MediaCodec.CodecException) { failure = e; done.countDown() }+ }, android.os.Handler(thread.looper))+ codec.configure(fmt, null, null, 0)+ codec.start()+ if (!done.await(60, java.util.concurrent.TimeUnit.SECONDS)) error("decode timeout")+ failure?.let { throw it }+ android.util.Log.i("MusicVideo", "decode $codecName: ${(System.nanoTime() - t0) / 1_000_000} ms")+ return out.result()+ } finally {+ decoderToRelease?.let { decoder ->+ runCatching { decoder.stop() }+ runCatching { decoder.release() }+ }+ runCatching { ex.release() }+ threadToStop?.quitSafely()+ }+ }++ /** Initial PCM reservation only; output still grows if the container understates its duration. */+ internal fun decodeCapacity(durationUs: Long, maxSeconds: Int): Int {+ val ceiling = Int.MAX_VALUE - SR+ val durationSamples = if (durationUs > 0)+ (durationUs / 1_000_000.0 * SR).coerceAtMost(ceiling.toDouble()).toInt()+ else ceiling+ if (maxSeconds <= 0 && durationUs <= 0) return 1 shl 22+ val limitSamples = if (maxSeconds > 0)+ (maxSeconds.toLong() * SR).coerceAtMost(ceiling.toLong()).toInt()+ else ceiling+ return min(durationSamples, limitSamples) + SR+ }++ private class Resampler(rate: Int, capacity: Int) {+ private var a = FloatArray(capacity)+ private var n = 0+ private var step = 1.0+ private var k = 1+ private var ring = FloatArray(8)+ private var ringPos = 0+ private var sum = 0f+ private var inIndex = 0L+ private var nextOut = 0.0+ init { setRate(rate) }+ fun setRate(rate: Int) {+ step = rate.toDouble() / SR+ k = max(1, step.toInt())+ ring = FloatArray(k); ringPos = 0; sum = 0f+ }+ /** Interleaved 16-bit frames → mono → box low-pass → resampled, in one tight loop. */+ fun pushInterleaved(s: ShortArray, count: Int, channels: Int) {+ val scale = 1f / (channels * 32768f)+ var i = 0+ var rp = ringPos; var sm = sum; var idx = inIndex; var nx = nextOut+ val r = ring; val kk = k+ while (i + channels <= count) {+ var acc = 0+ for (c in 0 until channels) acc += s[i + c]+ val v = acc * scale+ sm += v - r[rp]; r[rp] = v+ rp++; if (rp == kk) rp = 0+ if (idx >= nx) {+ if (n == a.size) a = a.copyOf(a.size + a.size / 2)+ a[n++] = sm / kk+ nx += step+ }+ idx+++ i += channels+ }+ ringPos = rp; sum = sm; inIndex = idx; nextOut = nx+ }++ fun pushInterleavedFloat(s: FloatArray, count: Int, channels: Int) {+ val scale = 1f / channels+ var i = 0+ while (i + channels <= count) {+ var acc = 0f+ for (c in 0 until channels) acc += s[i + c]+ push(acc * scale)+ i += channels+ }+ }++ fun push(v: Float) {+ sum += v - ring[ringPos]+ ring[ringPos] = v+ ringPos++; if (ringPos == k) ringPos = 0+ if (inIndex >= nextOut) {+ if (n == a.size) a = a.copyOf(a.size + a.size / 2)+ a[n++] = sum / k+ nextOut += step+ }+ inIndex+++ }+ fun result() = a.copyOf(n)+ fun size() = n+ }++ // ── FFT (in place, radix 2) ──++ private fun fft(re: DoubleArray, im: DoubleArray, inverse: Boolean) {+ val n = re.size+ var j = 0+ for (i in 1 until n) {+ var bit = n shr 1+ while (j and bit != 0) { j = j xor bit; bit = bit shr 1 }+ j = j xor bit+ if (i < j) {+ var t = re[i]; re[i] = re[j]; re[j] = t+ t = im[i]; im[i] = im[j]; im[j] = t+ }+ }+ var len = 2+ while (len <= n) {+ val ang = 2 * PI / len * (if (inverse) 1 else -1)+ val wr = cos(ang); val wi = sin(ang)+ var i = 0+ while (i < n) {+ var cr = 1.0; var ci = 0.0+ for (k in 0 until len / 2) {+ val a = i + k; val b = a + len / 2+ val xr = re[b] * cr - im[b] * ci+ val xi = re[b] * ci + im[b] * cr+ re[b] = re[a] - xr; im[b] = im[a] - xi+ re[a] += xr; im[a] += xi+ val nr = cr * wr - ci * wi+ ci = cr * wi + ci * wr; cr = nr+ }+ i += len+ }+ len = len shl 1+ }+ if (inverse) for (i in 0 until n) { re[i] /= n; im[i] /= n }+ }++ // ── Features ──++ /** [frames][BANDS] spectral flux, z-scored per band. */+ fun features(x: FloatArray): Array<DoubleArray> {+ val nf = if (x.size < N) 0 else 1 + (x.size - N) / HOP+ val win = DoubleArray(N) { 0.5 - 0.5 * cos(2 * PI * it / (N - 1)) }+ val edges = DoubleArray(BANDS + 1) { 80.0 * Math.pow(5000.0 / 80.0, it.toDouble() / BANDS) }+ val binOf = IntArray(N / 2 + 1) { b ->+ val f = b.toDouble() * SR / N+ var band = -1+ for (i in 0 until BANDS) if (f >= edges[i] && f < edges[i + 1]) { band = i; break }+ band+ }+ val out = Array(nf) { DoubleArray(BANDS) }+ val re = DoubleArray(N); val im = DoubleArray(N)+ val prev = DoubleArray(BANDS)+ for (fr in 0 until nf) {+ if (Thread.currentThread().isInterrupted) throw InterruptedException("Audio feature extraction interrupted")+ val off = fr * HOP+ for (i in 0 until N) { re[i] = x[off + i] * win[i]; im[i] = 0.0 }+ fft(re, im, false)+ val e = DoubleArray(BANDS)+ for (b in 0..N / 2) { val band = binOf[b]; if (band >= 0) e[band] += re[b] * re[b] + im[b] * im[b] }+ for (k in 0 until BANDS) {+ val v = ln(1 + e[k] * 1e3)+ out[fr][k] = if (fr == 0) 0.0 else v - prev[k]+ prev[k] = v+ }+ }+ for (k in 0 until BANDS) {+ var m = 0.0; for (f in out) m += f[k]; m /= max(1, nf)+ var s = 0.0; for (f in out) s += (f[k] - m) * (f[k] - m); s = sqrt(s / max(1, nf)) + 1e-6+ for (f in out) f[k] = (f[k] - m) / s+ }+ return out+ }++ private data class Cand(val videoFrame: Int, val score: Double)++ /** Aligns the song's audio with the video's audio. */+ suspend fun align(song: Array<DoubleArray>, video: Array<DoubleArray>): TimeMap = coroutineScope {+ currentCoroutineContext().ensureActive()+ val w = (6.0 / FRAME_S).toInt()+ val step = (3.0 / FRAME_S).toInt()+ val m = video.size+ if (song.size < w || m < w) return@coroutineScope TimeMap(emptyList(), 0.0)+ var nfft = 1; while (nfft < m + w) nfft = nfft shl 1+ // Spectra of each video band, once.+ val refRe = Array(BANDS) { DoubleArray(nfft) }+ val refIm = Array(BANDS) { DoubleArray(nfft) }+ (0 until BANDS).map { b ->+ async(Dispatchers.Default) {+ currentCoroutineContext().ensureActive()+ for (i in 0 until m) refRe[b][i] = video[i][b]+ fft(refRe[b], refIm[b], false)+ }+ }.awaitAll()+ // Energy of every video window, for the normalisation.+ val cum = DoubleArray(m + 1)+ for (i in 0 until m) { var e = 0.0; for (b in 0 until BANDS) e += video[i][b] * video[i][b]; cum[i + 1] = cum[i] + e }+ val starts = (0..(song.size - w) step step).toList()+ val cands = starts.map { st ->+ async(Dispatchers.Default) {+ currentCoroutineContext().ensureActive()+ // Window, z-scored as a whole.+ var mean = 0.0+ for (i in 0 until w) for (b in 0 until BANDS) mean += song[st + i][b]+ mean /= (w * BANDS)+ var ss = 0.0+ val wz = Array(w) { i -> DoubleArray(BANDS) { b -> (song[st + i][b] - mean).also { ss += it * it } } }+ val wn = sqrt(ss) + 1e-6+ val accRe = DoubleArray(nfft); val accIm = DoubleArray(nfft)+ val re = DoubleArray(nfft); val im = DoubleArray(nfft)+ for (b in 0 until BANDS) {+ currentCoroutineContext().ensureActive()+ java.util.Arrays.fill(re, 0.0); java.util.Arrays.fill(im, 0.0)+ for (i in 0 until w) re[i] = wz[i][b]+ fft(re, im, false)+ val rr = refRe[b]; val ri = refIm[b]+ for (k in 0 until nfft) {+ // ref * conj(win)+ accRe[k] += rr[k] * re[k] + ri[k] * im[k]+ accIm[k] += ri[k] * re[k] - rr[k] * im[k]+ }+ }+ fft(accRe, accIm, true)+ val n = m - w + 1+ val score = DoubleArray(n) { i -> accRe[i] / ((sqrt(max(0.0, cum[i + w] - cum[i])) + 1e-6) * wn) }+ // Top 5 peaks, at least 1 s apart.+ val picked = ArrayList<Cand>()+ val order = (0 until n).sortedByDescending { score[it] }+ for (i in order) {+ if (picked.size == 5) break+ if (picked.all { abs(it.videoFrame - i) > (1.0 / FRAME_S) }) picked.add(Cand(i, score[i]))+ }+ picked+ }+ }.awaitAll()+ // Dynamic programming over the candidates: maximise the matched score, the+ // video only moves forward, offset changes cost 0.6, and up to 3 ambiguous+ // windows (repeated choruses…) may be skipped at 0.35 each.+ val tol = (0.08 / FRAME_S).toInt()+ val skip = 4+ val n = cands.size+ val best = Array(n) { DoubleArray(cands[it].size) }+ val fromI = Array(n) { IntArray(cands[it].size) { -1 } }+ val fromK = Array(n) { IntArray(cands[it].size) { -1 } }+ for (i in 0 until n) {+ for ((k, c) in cands[i].withIndex()) {+ val off = c.videoFrame - starts[i]+ var bv = c.score - (if (i == 0) 0.0 else 3.0)+ var bi = -1; var bk = -1+ for (j in max(0, i - skip) until i) {+ for ((pk, p) in cands[j].withIndex()) {+ if (c.videoFrame <= p.videoFrame) continue+ val poff = p.videoFrame - starts[j]+ val v = best[j][pk] + c.score - (if (abs(off - poff) <= tol) 0.0 else 0.6) - 0.35 * (i - j - 1)+ if (v > bv) { bv = v; bi = j; bk = pk }+ }+ }+ best[i][k] = bv; fromI[i][k] = bi; fromK[i][k] = bk+ }+ }+ var ei = -1; var ek = -1; var ev = Double.NEGATIVE_INFINITY+ for (i in max(0, n - skip) until n) for (k in cands[i].indices) {+ val v = best[i][k] - 0.35 * (n - 1 - i)+ if (v > ev) { ev = v; ei = i; ek = k }+ }+ val chosenIdx = ArrayList<Int>(); val chosen = ArrayList<Cand>()+ while (ei >= 0) {+ chosenIdx.add(ei); chosen.add(cands[ei][ek])+ val pi = fromI[ei][ek]; val pk = fromK[ei][ek]+ ei = pi; ek = pk+ }+ chosenIdx.reverse(); chosen.reverse()+ val avg = if (chosen.isEmpty()) 0.0 else chosen.map { it.score }.average() * chosen.size / n+ // Segments of equal offset.+ val segs = ArrayList<Segment>()+ fun offsetOf(t: Int) = chosen[t].videoFrame - starts[chosenIdx[t]]+ var segStart = 0+ for (t in 1..chosen.size) {+ if (chosen.isEmpty()) break+ if (t == chosen.size || abs(offsetOf(t) - offsetOf(segStart)) > tol) {+ val offs = (segStart until t).map { offsetOf(it) }.sorted()+ val off = offs[offs.size / 2]+ val startMs = if (segStart == 0) 0L+ else (((starts[chosenIdx[segStart - 1]] + w + starts[chosenIdx[segStart]]) / 2.0) * FRAME_S * 1000).toLong()+ val endMs = if (t == chosen.size) Long.MAX_VALUE+ else (((starts[chosenIdx[t - 1]] + w + starts[chosenIdx[t]]) / 2.0) * FRAME_S * 1000).toLong()+ segs.add(Segment(startMs, endMs, (off * FRAME_S * 1000).toLong()))+ segStart = t+ }+ }+ TimeMap(segs, avg)+ }+}diff --git a/base/app/src/main/java/com/music/spotui/video/InterruptibleHttp.kt b/base/app/src/main/java/com/music/spotui/video/InterruptibleHttp.ktnew file mode 100644index 00000000..90fe6606--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/video/InterruptibleHttp.kt@@ -0,0 +1,47 @@+package com.music.spotui.video++import okhttp3.Call+import okhttp3.Callback+import okhttp3.Response+import java.io.IOException+import java.io.InterruptedIOException+import java.util.concurrent.CountDownLatch+import java.util.concurrent.atomic.AtomicReference++/** Blocks the extractor caller, not an uncancellable Call.execute or a polling thread. */+internal object InterruptibleHttp {+ fun <T> read(call: Call, decode: (Response) -> T): T {+ checkInterrupted()+ val done = CountDownLatch(1)+ val result = AtomicReference<Result<T>?>(null)+ call.enqueue(object : Callback {+ override fun onFailure(call: Call, e: IOException) {+ result.set(Result.failure(e))+ done.countDown()+ }++ override fun onResponse(call: Call, response: Response) {+ try {+ result.set(runCatching {+ response.use {+ if (call.isCanceled()) throw InterruptedIOException("Metadata HTTP call cancelled")+ decode(it)+ }+ })+ } finally {+ done.countDown()+ }+ }+ })+ try {+ done.await()+ checkInterrupted()+ } catch (t: InterruptedException) {+ call.cancel()+ // Extractor optional-field catches must not start another request after this interruption.+ Thread.currentThread().interrupt()+ throw t+ }+ return (result.get() ?: error("Metadata HTTP callback completed without a result")).getOrThrow()+ }+}diff --git a/base/app/src/main/java/com/music/spotui/video/MusicVideoController.kt b/base/app/src/main/java/com/music/spotui/video/MusicVideoController.ktnew file mode 100644index 00000000..62b62390--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/video/MusicVideoController.kt@@ -0,0 +1,797 @@+package com.music.spotui.video++import android.content.Context+import android.net.Uri+import android.os.SystemClock+import android.util.Log+import android.util.AtomicFile+import app.myspoti.power.EnergySettings+import androidx.compose.runtime.mutableFloatStateOf+import androidx.compose.runtime.mutableStateOf+import androidx.media3.common.MediaItem+import androidx.media3.common.PlaybackParameters+import androidx.media3.common.Player+import androidx.media3.common.VideoSize+import androidx.media3.datasource.DefaultHttpDataSource+import androidx.media3.exoplayer.ExoPlayer+import androidx.media3.exoplayer.dash.DashMediaSource+import androidx.media3.exoplayer.dash.manifest.DashManifestParser+import androidx.media3.exoplayer.source.ProgressiveMediaSource+import com.music.spotui.di.Graph+import com.music.spotui.di.SongPlayer+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.Job+import kotlinx.coroutines.Deferred+import kotlinx.coroutines.NonCancellable+import kotlinx.coroutines.currentCoroutineContext+import kotlinx.coroutines.ensureActive+import kotlinx.coroutines.runInterruptible+import kotlinx.coroutines.SupervisorJob+import kotlinx.coroutines.async+import kotlinx.coroutines.coroutineScope+import kotlinx.coroutines.sync.withLock+import kotlinx.coroutines.delay+import kotlinx.coroutines.isActive+import kotlinx.coroutines.launch+import kotlinx.coroutines.withContext+import org.json.JSONArray+import org.json.JSONObject+import org.schabi.newpipe.extractor.MediaFormat+import org.schabi.newpipe.extractor.services.youtube.YoutubeParsingHelper+import org.schabi.newpipe.extractor.services.youtube.dashmanifestcreators.YoutubeProgressiveDashManifestCreator+import java.io.File+import kotlin.math.abs++/**+ * Music videos from YouTube, synced to the Spotify playback.+ *+ * Spotify keeps playing the audio (so plays count, as always); the official video+ * plays muted on top, at the same relative time. The song→video time map is found+ * once per track by aligning the YouTube Music song audio (same master as Spotify)+ * with the video's soundtrack ([AudioAlign]) and cached on disk.+ */+object MusicVideoController {+ private const val TAG = "MusicVideo"+ private const val MIN_SCORE = 0.4++ sealed interface State {+ data object Idle : State+ data object Searching : State+ data class Ready(+ val trackId: String, val videoUrl: String, val map: AudioAlign.TimeMap,+ val mapComplete: Boolean = false, internal val refinementToken: String? = null,+ ) : State+ data object Unavailable : State+ }++ /** Video state for the track on screen. */+ val state = mutableStateOf<State>(State.Idle)+ /** The user switched to the video for this track. */+ val on = mutableStateOf(false)+ val fullscreen = mutableStateOf(false)+ /** width / height of the playing video. */+ val aspect = mutableFloatStateOf(16f / 9f)++ // Observable: a surface composed before the player exists attaches when it appears.+ private val playerState = mutableStateOf<ExoPlayer?>(null)+ val player: ExoPlayer? get() = playerState.value++ private val scope = CoroutineScope(SupervisorJob() + Dispatchers.Main)+ private var prepareJob: Job? = null+ private var syncJob: Job? = null+ private var refineJob: Job? = null+ private var surfaceIdleJob: Job? = null+ private val generation = java.util.concurrent.atomic.AtomicLong()+ private val prefetchSequence = java.util.concurrent.atomic.AtomicLong()+ private val refineLock = kotlinx.coroutines.sync.Mutex()+ private var currentTitle = ""+ private var currentArtist = ""+ private var currentDuration = 0L+ private data class Retained(val request: Long, val files: RefinementFiles)+ private val retained = java.util.concurrent.ConcurrentHashMap<String, Retained>()+ private var currentTrackId = ""+ private var errorRetryUsedFor: String? = null+ private var nextPrepareAt = 0L+ private val app: Context get() = Graph.app+ private val cacheLock = Any()++ // ── Track → video + time map (cached) ──++ // Bumped when the matching rules change, so earlier answers are looked up again.+ private const val CACHE_DIR = "music_videos18"+ private val cacheDir: File by lazy {+ // Answers of the earlier rules are dropped once.+ app.filesDir.listFiles { f -> f.isDirectory && f.name.startsWith("music_videos") && f.name != CACHE_DIR }+ ?.forEach { it.deleteRecursively() }+ File(app.filesDir, CACHE_DIR)+ }+ private fun cacheFile(trackId: String) = File(cacheDir, "$trackId.json").also { it.parentFile?.mkdirs() }++ private fun readCache(trackId: String): State? = synchronized(cacheLock) {+ runCatching {+ val f = cacheFile(trackId)+ if (!f.exists()) return@runCatching null+ val o = JSONObject(f.readText())+ if (o.optBoolean("none")) {+ return@runCatching if (System.currentTimeMillis() - o.optLong("at") < 7 * 86_400_000L)+ State.Unavailable else null+ }+ val score = o.getDouble("score")+ require(score.isFinite() && score >= MIN_SCORE)+ val jsonSegments = o.getJSONArray("segments")+ val segments = (0 until jsonSegments.length()).map { i ->+ val s = jsonSegments.getJSONObject(i)+ AudioAlign.Segment(s.getLong("from"), s.getLong("to"), s.getLong("offset"))+ }+ require(segments.isNotEmpty())+ require(segments.all { it.songStartMs >= 0 && it.songEndMs > it.songStartMs })+ require(segments.zipWithNext().all { (a, b) -> a.songEndMs <= b.songStartMs })+ State.Ready(trackId, o.getString("video"), AudioAlign.TimeMap(segments, score), mapComplete = o.optBoolean("complete"))+ }.getOrElse {+ Log.w(TAG, "Ignoring invalid music video cache: ${it.javaClass.simpleName}")+ null+ }+ }++ private fun writeCache(trackId: String, s: State) {+ synchronized(cacheLock) {+ val o = JSONObject()+ when (s) {+ is State.Ready -> {+ o.put("video", s.videoUrl).put("score", s.map.score).put("complete", s.mapComplete)+ o.put("segments", JSONArray().apply {+ s.map.segments.forEach { put(JSONObject().put("from", it.songStartMs).put("to", it.songEndMs).put("offset", it.offsetMs)) }+ })+ }+ else -> o.put("none", true).put("at", System.currentTimeMillis())+ }+ runCatching {+ val file = AtomicFile(cacheFile(trackId))+ val stream = file.startWrite()+ try {+ stream.write(o.toString().toByteArray(Charsets.UTF_8))+ file.finishWrite(stream)+ } catch (t: Throwable) {+ file.failWrite(stream)+ throw t+ }+ }+ }+ }++ // Background look-ups for tracks not on screen yet (the next one), one at a time.+ private val prefetching = java.util.Collections.synchronizedSet(HashSet<String>())+ private val prefetchJobs = java.util.concurrent.ConcurrentHashMap<String, Job>()+++ /** Resolve and cache a track's video in the background, without touching the UI state. */+ fun prefetch(trackId: String, title: String, artist: String, durationMs: Long) {+ if (com.music.spotui.data.DataSaver.active || !appVisible || !EnergySettings.state.value.policy.allowBackgroundLookups || trackId.isBlank() || trackId == currentTrackId || !prefetching.add(trackId)) return+ val request = -prefetchSequence.incrementAndGet()+ val published = java.util.concurrent.atomic.AtomicBoolean(false)+ val job = scope.launch(start = kotlinx.coroutines.CoroutineStart.LAZY) {+ if (!appVisible || !EnergySettings.state.value.policy.allowBackgroundLookups) return@launch+ try {+ val result = withContext(Dispatchers.IO) {+ readCache(trackId) ?: resolve(trackId, title, artist, durationMs, request).also { if (it != null) writeCache(trackId, it) }+ }+ if (trackId == currentTrackId && state.value is State.Searching) {+ if (result == null) nextPrepareAt = SystemClock.elapsedRealtime() + 30_000+ state.value = result ?: State.Idle+ published.set(result != null)+ if (result is State.Ready) { preloadStream(result.videoUrl); resumeWanted() }+ }+ } catch (t: kotlinx.coroutines.CancellationException) {+ throw t+ } catch (t: Throwable) {+ if (trackId == currentTrackId && state.value is State.Searching) {+ nextPrepareAt = SystemClock.elapsedRealtime() + 30_000+ state.value = State.Idle+ }+ Log.w(TAG, "Video prefetch failed: ${t.javaClass.simpleName}")+ }+ }+ prefetchJobs[trackId] = job+ job.invokeOnCompletion {+ if (prefetchJobs.remove(trackId, job)) prefetching.remove(trackId)+ if (!published.get()) {+ discardRetained(request = request)+ scope.launch {+ if (currentTrackId == trackId && state.value is State.Searching && prepareJob?.isActive != true && trackId !in prefetching) {+ nextPrepareAt = 0L+ state.value = State.Idle+ }+ }+ }+ }+ job.start()+ }++ /** Find (or load) the video of the track now playing. Disk access stays on IO. */+ fun prepare(trackId: String, title: String, artist: String, durationMs: Long) {+ // Data saver on mobile data: no look-up (it downloads audio) and no video stream.+ if (trackId.isBlank() || !appVisible || com.music.spotui.data.DataSaver.active) return+ currentTitle = title; currentArtist = artist; currentDuration = durationMs+ if (trackId == currentTrackId && (state.value !is State.Idle || SystemClock.elapsedRealtime() < nextPrepareAt)) return+ if (currentTrackId != trackId) { errorRetryUsedFor = null; nextPrepareAt = 0L }+ val request = generation.incrementAndGet()+ currentTrackId = trackId+ prepareJob?.cancel()+ refineJob?.cancel()+ discardRetained()+ wantVideo = wantVideo || on.value+ if (on.value) { on.value = false; fullscreen.value = false; syncJob?.cancel() }+ warmedFor = null+ player?.let { it.stop(); it.clearMediaItems() }+ state.value = State.Searching+ if (trackId in prefetching) return+ prepareJob = scope.launch {+ var published = false+ try {+ val result = withContext(Dispatchers.IO) {+ val cached = readCache(trackId)+ if (cached != null) cached else {+ val resolved = resolve(trackId, title, artist, durationMs, request)+ currentCoroutineContext().ensureActive()+ if (resolved != null) writeCache(trackId, resolved)+ resolved+ }+ }+ if (generation.get() != request || currentTrackId != trackId) return@launch+ if (result == null) {+ nextPrepareAt = SystemClock.elapsedRealtime() + 30_000+ state.value = State.Idle+ return@launch+ }+ state.value = result+ published = true+ if (result is State.Ready) { preloadStream(result.videoUrl); resumeWanted() }+ } catch (t: kotlinx.coroutines.CancellationException) {+ throw t+ } catch (t: Throwable) {+ if (generation.get() == request) {+ nextPrepareAt = SystemClock.elapsedRealtime() + 30_000+ state.value = State.Idle+ }+ Log.w(TAG, "Video preparation failed: ${t.javaClass.simpleName}")+ } finally {+ if (!published) discardRetained(request = request)+ }+ }+ }++ // One look-up at a time (CPU / network).+ private val resolveLock = kotlinx.coroutines.sync.Mutex()++ /**+ * The track's official clip, or none:+ * - only videos YouTube files as official music videos (MUSIC_VIDEO_TYPE_OMV,+ * published by the artist or the label), never fan uploads;+ * - not a still image (some "official" uploads are the cover over the song);+ * - its soundtrack really is this song: the start of the song (45 s) is found in+ * the start of the clip (100 s), which also gives the time offset.+ * null = could not decide (network / decoding error): not cached, retried later.+ */+ private suspend fun resolve(trackId: String, title: String, artist: String, durationMs: Long, request: Long): State? = resolveLock.withLock {+ val t0 = SystemClock.elapsedRealtime()+ val token = java.util.UUID.randomUUID().toString()+ val refFile = File(app.cacheDir, "mv_ref_${trackId}_$token")+ val candidateFiles = mutableListOf<File>()+ try {+ coroutineScope {+ val song = async(Dispatchers.IO) {+ runInterruptible { YouTubeSource.findSong(title, artist, durationMs) ?: YouTubeSource.findAudio(title, artist, durationMs) }+ }+ val candidates = withContext(Dispatchers.IO) {+ YouTubeSource.videoCandidates(title, artist, durationMs)+ }.take(6)+ // No audio download until an official, moving clip needs verification.+ val referenceFeatures = async(Dispatchers.Default, start = kotlinx.coroutines.CoroutineStart.LAZY) {+ val reference = song.await() ?: error("No reference audio")+ downloadAudioFile(reference.url, refFile)+ runInterruptible { AudioAlign.features(AudioAlign.decode(refFile, 45)) }+ }+ val result = firstVerifiedClip(candidates,+ classify = { c -> withContext(Dispatchers.IO) { runInterruptible { YouTubeSource.musicVideoType(c.url) } } },+ verify = { c ->+ val candFile = File(app.cacheDir, "mv_cand_${trackId}_${candidateFiles.size}_$token")+ candidateFiles.add(candFile)+ try {+ val info = withContext(Dispatchers.IO) { runInterruptible { YouTubeSource.info(c.url) } }+ val trusted = YouTubeSource.isTrustedClip(info, artist)+ if (!trusted) Log.i(TAG, "candidate ${info.name} (${info.uploaderName}, verified=${info.isUploaderVerified}): not the artist's clip")+ val still = if (trusted) withContext(Dispatchers.IO) { runInterruptible { YouTubeSource.isStatic(info) } } else false+ when {+ !trusted -> ClipVerification<State>()+ still == null -> ClipVerification<State>(failed = true)+ still -> ClipVerification<State>()+ song.await() == null -> ClipVerification(State.Unavailable)+ song.await()?.url == c.url -> ClipVerification<State>()+ else -> {+ referenceFeatures.start()+ downloadAudioFile(c.url, candFile)+ val candidate = withContext(Dispatchers.Default) {+ runInterruptible { AudioAlign.features(AudioAlign.decode(candFile, 100)) }+ }+ val reference = referenceFeatures.await()+ val map = withContext(Dispatchers.Default) {+ AudioAlign.align(reference, candidate)+ }+ Log.i(TAG, "candidate ${c.name} (${c.uploader}): score ${"%.2f".format(map.score)}")+ if (map.score >= MIN_SCORE && map.segments.isNotEmpty()) {+ val files = RefinementFiles.retain(refFile, candFile, app.cacheDir)+ val id = files?.reference?.name+ if (files != null && id != null) retained[id] = Retained(request, files)+ ClipVerification(State.Ready(trackId, c.url, map, refinementToken = id))+ } else ClipVerification<State>()+ }+ }+ } catch (t: kotlinx.coroutines.CancellationException) {+ throw t+ } catch (t: Throwable) {+ currentCoroutineContext().ensureActive()+ Log.w(TAG, "candidate failed: ${t.javaClass.simpleName}")+ ClipVerification<State>(failed = true)+ } finally { candFile.delete() }+ })+ // A LAZY reference job must not keep the scope alive when no clip was tested.+ referenceFeatures.cancel()+ song.cancel()+ Log.i(TAG, "$title: clip lookup ${SystemClock.elapsedRealtime() - t0} ms, found=${result.value is State.Ready}")+ result.value ?: if (result.failed) null else State.Unavailable+ }+ } catch (t: kotlinx.coroutines.CancellationException) {+ throw t+ } catch (t: Throwable) {+ Log.w(TAG, "Video resolution failed: ${t.javaClass.simpleName}")+ null+ } finally {+ refFile.delete()+ candidateFiles.forEach { it.delete() }+ }+ }++ /** Delete only files not yet transferred to a running refinement. */+ private fun discardRetained(token: String? = null, request: Long? = null) {+ val keys = if (token != null) listOf(token) else retained.entries+ .filter { request == null || it.value.request == request }.map { it.key }+ val files = keys.mapNotNull { retained.remove(it)?.files }+ if (files.isNotEmpty()) scope.launch(Dispatchers.IO) { files.forEach { it.close() } }+ }++ /** Full FFT work starts only after the prefix has been cached and video is requested. */+ private fun ensureRefinement(s: State.Ready) {+ val current = state.value as? State.Ready ?: return+ if (current.trackId != s.trackId || current.videoUrl != s.videoUrl || current.mapComplete) return+ if (s.mapComplete || !on.value || !SongPlayer.isPlaying() || SongPlayer.isBuffering || !appVisible || surfaces <= 0 || SongPlayer.activeDevice.value != null || refineJob?.isActive == true) return+ val request = generation.get()+ val title = currentTitle+ val artist = currentArtist+ val duration = currentDuration+ refineJob = scope.launch {+ var files = s.refinementToken?.let { retained.remove(it)?.files }+ try {+ if (files == null) {+ val target = RefinementFiles.empty(app.cacheDir)+ files = target+ withContext(Dispatchers.IO) {+ val song = runInterruptible {+ YouTubeSource.findSong(title, artist, duration) ?: YouTubeSource.findAudio(title, artist, duration)+ } ?: error("No reference audio for refinement")+ coroutineScope {+ val reference = async { downloadAudioFile(song.url, target.reference) }+ val candidate = async { downloadAudioFile(s.videoUrl, target.candidate) }+ reference.await(); candidate.await()+ }+ }+ }+ val target = files ?: return@launch+ val full = refineLock.withLock { coroutineScope {+ val reference = async(Dispatchers.Default) {+ runInterruptible { AudioAlign.features(AudioAlign.decode(target.reference)) }+ }+ val candidate = async(Dispatchers.Default) {+ runInterruptible { AudioAlign.features(AudioAlign.decode(target.candidate)) }+ }+ AudioAlign.align(reference.await(), candidate.await())+ } }+ currentCoroutineContext().ensureActive()+ if (full.score < MIN_SCORE || full.segments.isEmpty() || generation.get() != request) return@launch+ val result = s.copy(map = full, mapComplete = true, refinementToken = null)+ withContext(Dispatchers.IO) { writeCache(s.trackId, result) }+ val current = state.value as? State.Ready+ if (generation.get() == request && current?.trackId == s.trackId && current.videoUrl == s.videoUrl) state.value = result+ Log.i(TAG, "Full map ready: ${full.segments.size} segments, score ${full.score}")+ } catch (t: kotlinx.coroutines.CancellationException) {+ throw t+ } catch (t: Throwable) {+ Log.w(TAG, "Full alignment failed: ${t.javaClass.simpleName}")+ } finally {+ withContext(NonCancellable + Dispatchers.IO) { files?.close() }+ }+ }+ }++ /**+ * Downloads a YouTube item's audio into [out]: AAC first (same decoder on both+ * sides cancels its delay), lowest bitrate first; a stream YouTube no longer+ * serves (empty / truncated) falls back to the next; a refusal (403) gets fresh URLs once.+ */+ private suspend fun downloadAudioFile(url: String, out: File): File =+ try { downloadAudioFileOnce(url, out, runInterruptible(Dispatchers.IO) { YouTubeSource.info(url) }) } catch (t: Throwable) {+ currentCoroutineContext().ensureActive()+ if (t.message?.contains("403") != true) throw t+ downloadAudioFileOnce(url, out, runInterruptible(Dispatchers.IO) { YouTubeSource.info(url, fresh = true) })+ }++ private suspend fun downloadAudioFileOnce(url: String, out: File, info: org.schabi.newpipe.extractor.stream.StreamInfo): File {+ val streams = info.audioStreams+ .filter { it.format == MediaFormat.WEBMA_OPUS || it.format == MediaFormat.M4A }+ .sortedWith(compareBy({ if (it.format == MediaFormat.M4A) 0 else 1 }, { if (it.averageBitrate > 0) it.averageBitrate else Int.MAX_VALUE }))+ if (streams.isEmpty()) error("no audio stream")+ var last: Throwable? = null+ for (a in streams.take(3)) {+ try {+ fetchRanged(a.content, out)+ val expected = if (a.averageBitrate > 0 && info.duration > 0) a.averageBitrate * 1000L / 8 * info.duration else 0L+ if (out.length() < 50_000 || (expected > 0 && out.length() < expected * 0.6))+ error("${out.length() / 1024} KB, expected ~${expected / 1024} KB")+ return out+ } catch (t: Throwable) { currentCoroutineContext().ensureActive(); last = t }+ }+ throw last ?: IllegalStateException("no usable audio")+ }++ /** googlevideo: `range=` requests of the exact announced length (`clen`). */+ private suspend fun fetchRanged(url: String, out: File) {+ RangeAudioDownload.fetch(YouTubeSource.http, url, out, streamHeaders(url))+ }++ // ── Playback ──+ //+ // Speed: the stream is resolved as soon as the track's video is known (cached ~5 h),+ // and buffered as soon as the Now Playing screen shows (paused, at the mapped time),+ // so "Passer à la vidéo" only attaches the surface and plays.++ private data class VideoSource(val url: String, val source: androidx.media3.exoplayer.source.MediaSource, val durationMs: Long, val at: Long, val maxHeight: Int)+ private val sources = java.util.concurrent.ConcurrentHashMap<String, VideoSource>()+ private val resolving = java.util.Collections.synchronizedSet(HashSet<String>())+ @Volatile private var warmedFor: String? = null+ @Volatile var videoDurationMs = 0L+ private set++ private fun freshSource(url: String): VideoSource? =+ sources[url]?.takeIf {+ SystemClock.elapsedRealtime() - it.at < 4 * 3_600_000L && it.maxHeight == EnergySettings.state.value.policy.videoMaxHeight+ }++ /** Resolve the playable stream of [url] in the background (no-op when cached). */+ // Callbacks waiting for a stream being resolved: a second request for the same+ // URL (warm-up, then "play it" on a track change) must not be dropped.+ private val waiting = HashMap<String, MutableList<() -> Unit>>()++ private fun preloadStream(url: String, fresh: Boolean = false, then: (() -> Unit)? = null) {+ if (!fresh && freshSource(url) != null) { then?.invoke(); return }+ then?.let { waiting.getOrPut(url) { mutableListOf() }.add(it) }+ if (!resolving.add(url)) return+ scope.launch {+ val t0 = SystemClock.elapsedRealtime()+ val vs = withContext(Dispatchers.IO) {+ runCatching { buildSource(url, fresh) }.onFailure { Log.w(TAG, "video stream failed: ${it.message}") }.getOrNull()+ }+ resolving.remove(url)+ val cbs = waiting.remove(url).orEmpty()+ if (vs != null) {+ sources[url] = vs+ Log.i(TAG, "stream ready in ${SystemClock.elapsedRealtime() - t0} ms")+ cbs.forEach { it() }+ }+ }+ }++ /**+ * The Now Playing screen shows a track with a known video: resolve and buffer it+ * now (paused, muted, at the mapped time) so switching is immediate.+ */+ fun warm() {+ val s = state.value as? State.Ready ?: return+ if (SongPlayer.activeDevice.value != null || !EnergySettings.state.value.policy.allowBackgroundLookups) return+ preloadStream(s.videoUrl) {+ if (!appVisible || !EnergySettings.state.value.policy.allowBackgroundLookups || SongPlayer.activeDevice.value != null || warmedFor == s.videoUrl || on.value || s.trackId != currentTrackId) return@preloadStream+ val vs = freshSource(s.videoUrl) ?: return@preloadStream+ val p = ensurePlayer()+ p.setMediaSource(vs.source)+ p.prepare()+ p.seekTo(s.map.toVideo(SongPlayer.getCurrentPosition() + 400))+ p.playWhenReady = false+ warmedFor = s.videoUrl+ videoDurationMs = vs.durationMs+ }+ }++ /** The user is in video mode (kept across tracks and app switches). */+ @Volatile var wantVideo = false+ private set+ /** Surfaces showing the video right now (player screen, full screen). */+ @Volatile var surfaces = 0+ set(value) {+ field = value.coerceAtLeast(0)+ surfaceIdleJob?.cancel()+ surfaceIdleJob = null+ if (field > 0) {+ (state.value as? State.Ready)?.let(::ensureRefinement)+ } else {+ // A fullscreen handoff briefly detaches the old surface before the new one attaches.+ surfaceIdleJob = scope.launch {+ delay(500)+ if (surfaces == 0) refineJob?.cancel()+ }+ }+ }+ @Volatile private var appVisible = true+ /** The app is on screen (look-ups at track start then, not in the background). */+ val inForeground: Boolean get() = appVisible++ private var playerScreens = 0++ /** A composed player screen still requests clip lookup after an app switch. */+ @androidx.annotation.MainThread+ fun attachPlayerScreen() { playerScreens++ }++ @androidx.annotation.MainThread+ fun detachPlayerScreen() { playerScreens = (playerScreens - 1).coerceAtLeast(0) }++ private fun resumeWanted() {+ if (wantVideo && !on.value && SongPlayer.activeDevice.value == null) {+ val s = state.value as? State.Ready ?: return+ on.value = true+ start(s)+ }+ }++ fun setOn(value: Boolean) {+ val s = state.value+ if (value && s !is State.Ready) return+ com.music.spotui.di.Haptics.click()+ wantVideo = value+ on.value = value+ if (!value) { fullscreen.value = false; stop(); return }+ start(s as State.Ready)+ }++ private fun ensurePlayer(): ExoPlayer = player ?: ExoPlayer.Builder(app)+ .setLoadControl(+ androidx.media3.exoplayer.DefaultLoadControl.Builder()+ // Start fast: half a second of video is enough to show frames.+ .setBufferDurationsMs(4_000, 20_000, 400, 1_000)+ .setBackBuffer(5_000, true)+ .build()+ )+ .build().also { np ->+ playerState.value = np+ np.volume = 0f+ np.addListener(object : Player.Listener {+ override fun onVideoSizeChanged(videoSize: VideoSize) {+ if (videoSize.width > 0 && videoSize.height > 0) {+ aspect.floatValue = videoSize.width * videoSize.pixelWidthHeightRatio / videoSize.height+ }+ }+ override fun onPlayerError(error: androidx.media3.common.PlaybackException) {+ // Expired / refused URL (403): drop it and resolve again once.+ Log.w(TAG, "playback error: ${error.message}")+ val st = state.value as? State.Ready ?: return+ sources.remove(st.videoUrl); warmedFor = null+ if (!on.value || errorRetryUsedFor == st.trackId) { stop(); on.value = false; return }+ errorRetryUsedFor = st.trackId+ preloadStream(st.videoUrl, fresh = true) {+ if (on.value && st.trackId == currentTrackId) start(st)+ }+ }+ })+ }++ private fun start(s: State.Ready) {+ if (!appVisible || !on.value || s.trackId != currentTrackId || SongPlayer.activeDevice.value != null) return+ val t0 = SystemClock.elapsedRealtime()+ val vs = freshSource(s.videoUrl)+ if (vs == null) { preloadStream(s.videoUrl) { if (on.value && s.trackId == currentTrackId) start(s) }; return }+ val p = ensurePlayer()+ if (warmedFor != s.videoUrl || p.playbackState == Player.STATE_IDLE) {+ p.setMediaSource(vs.source)+ p.prepare()+ warmedFor = s.videoUrl+ }+ videoDurationMs = vs.durationMs+ p.seekTo(s.map.toVideo(SongPlayer.getCurrentPosition()))+ p.playWhenReady = SongPlayer.isPlaying() && !SongPlayer.isBuffering+ p.addListener(object : Player.Listener {+ override fun onRenderedFirstFrame() {+ Log.i(TAG, "first frame ${SystemClock.elapsedRealtime() - t0} ms after the switch")+ p.removeListener(this)+ }+ })+ sync(p, s.map)+ ensureRefinement(s)+ }++ /** Headers googlevideo expects for the client the URL was made for (else 403). */+ fun streamHeaders(url: String): Map<String, String> {+ val loc = org.schabi.newpipe.extractor.localization.Localization.DEFAULT+ return when {+ YoutubeParsingHelper.isAndroidStreamingUrl(url) -> mapOf("User-Agent" to YoutubeParsingHelper.getAndroidUserAgent(loc))+ YoutubeParsingHelper.isIosStreamingUrl(url) -> mapOf("User-Agent" to YoutubeParsingHelper.getIosUserAgent(loc))+ YoutubeParsingHelper.isVisionOsStreamingUrl(url) -> mapOf("User-Agent" to YoutubeParsingHelper.getVisionOsUserAgent(loc))+ // Web client URLs: plain requests (a browser User-Agent gets empty answers).+ else -> emptyMap()+ }+ }++ private fun buildSource(url: String, fresh: Boolean = false): VideoSource {+ val t0 = SystemClock.elapsedRealtime()+ val info = YouTubeSource.info(url, fresh = fresh)+ Log.i(TAG, "stream info in ${SystemClock.elapsedRealtime() - t0} ms")+ val maxHeight = EnergySettings.state.value.policy.videoMaxHeight+ val allStreams = info.videoOnlyStreams.filter { it.height in 1..1080 }+ val streams = allStreams.filter { it.height <= maxHeight }.ifEmpty {+ val lowestHeight = allStreams.minOfOrNull { it.height }+ allStreams.filter { it.height == lowestHeight }+ }+ // H.264 remains preferred; the saver cap selects a smaller available stream.+ val preferredHeight = minOf(720, maxHeight)+ val avc = streams.filter { it.format == MediaFormat.MPEG_4 && it.codec?.startsWith("avc") == true }+ val v = avc.filter { it.height <= preferredHeight }.maxByOrNull { it.height }+ ?: avc.minByOrNull { it.height }+ ?: streams.filter { it.height <= preferredHeight }.maxByOrNull { it.height }+ ?: streams.minByOrNull { it.height }+ ?: error("no video stream")+ Log.i(TAG, "video ${v.height}p ${v.codec}")+ val headers = streamHeaders(v.content)+ val http = DefaultHttpDataSource.Factory()+ .apply { headers["User-Agent"]?.let { setUserAgent(it) } }+ .setDefaultRequestProperties(headers - "User-Agent")+ .setAllowCrossProtocolRedirects(true)+ val item = v.itagItem+ val source = if (item != null) {+ // As NewPipe: a DASH manifest over the progressive stream (ranged requests).+ val mpd = YoutubeProgressiveDashManifestCreator.fromProgressiveStreamingUrl(v.content, item, info.duration)+ val manifest = DashManifestParser().parse(Uri.parse(v.content), mpd.byteInputStream())+ DashMediaSource.Factory(http).createMediaSource(manifest, MediaItem.fromUri(v.content))+ } else {+ ProgressiveMediaSource.Factory(http).createMediaSource(MediaItem.fromUri(v.content))+ }+ return VideoSource(url, source, info.duration * 1000, SystemClock.elapsedRealtime(), maxHeight)+ }++ /** Keeps the video on the song: small drifts by speed, big ones by seeking. */+ private fun sync(p: ExoPlayer, initial: AudioAlign.TimeMap) {+ syncJob?.cancel()+ syncJob = scope.launch {+ while (isActive && on.value) {+ // The full map replaces the quick one when [refine] finishes.+ val map = (state.value as? State.Ready)?.map ?: initial+ val playing = SongPlayer.isPlaying()+ val shown = playing && !SongPlayer.isBuffering && appVisible && surfaces > 0 && SongPlayer.activeDevice.value == null+ if (p.playWhenReady != shown) p.playWhenReady = shown+ if (!shown) {+ if (p.playbackParameters.speed != 1f) p.playbackParameters = PlaybackParameters(1f)+ delay(500)+ continue+ }+ if (p.playbackState == Player.STATE_READY) {+ if (p.duration > 0) videoDurationMs = p.duration+ val target = map.toVideo(SongPlayer.getCurrentPosition())+ val drift = p.currentPosition - target+ when {+ abs(drift) > 600 -> { p.seekTo(target); p.playbackParameters = PlaybackParameters(1f) }+ playing && abs(drift) > 40 -> p.playbackParameters = PlaybackParameters((1f - drift / 2000f).coerceIn(0.9f, 1.1f))+ p.playbackParameters.speed != 1f -> p.playbackParameters = PlaybackParameters(1f)+ }+ }+ delay(150)+ }+ }+ }++ private fun stop() {+ syncJob?.cancel()+ player?.let { it.playWhenReady = false }+ refineJob?.cancel()+ // Keep the buffered source: switching back on is instant.+ }++ // ── Timeline shown while the video is on: the clip's time and length ──++ private fun activeMap(): AudioAlign.TimeMap? =+ if (on.value && SongPlayer.activeDevice.value == null) (state.value as? State.Ready)?.map else null++ fun position(): Long {+ val song = SongPlayer.getCurrentPosition()+ val m = activeMap() ?: return song+ val d = videoDurationMs+ return m.toVideo(song).coerceIn(0, if (d > 0) d else Long.MAX_VALUE)+ }++ fun duration(): Long = if (activeMap() != null && videoDurationMs > 0) videoDurationMs else SongPlayer.getDuration()++ fun seekTo(ms: Long) {+ val m = activeMap()+ SongPlayer.seekTo(if (m == null) ms else m.toSong(ms).coerceIn(0, SongPlayer.getDuration()))+ // Move the clip now (not at the next sync tick), to the nearest keyframe:+ // decoding starts sooner; the sync loop absorbs the few ms of difference.+ if (m != null) player?.let { p ->+ p.setSeekParameters(androidx.media3.exoplayer.SeekParameters.CLOSEST_SYNC)+ p.seekTo(ms)+ }+ }++ /** Audio transport has priority over optional clip work during startup/rebuffering. */+ fun onAudioBuffering(buffering: Boolean, trackId: String) {+ if (!buffering) {+ val ready = (state.value as? State.Ready)?.takeIf { it.trackId == trackId }+ if (SongPlayer.isPlaying() && appVisible && ready != null) {+ // Back from the background while the audio was buffering: onForeground+ // left the clip stopped. Restart it once, not on every status event.+ if (on.value && syncJob?.isActive != true) start(ready)+ else if (!on.value) resumeWanted()+ if (on.value) ensureRefinement(ready)+ } else refineJob?.cancel()+ return+ }+ prepareJob?.cancel()+ prefetchJobs.values.forEach { it.cancel() }+ refineJob?.cancel()+ if (state.value is State.Searching) { state.value = State.Idle; nextPrepareAt = 0L }+ if (trackId.isNotBlank() && currentTrackId != trackId) {+ generation.incrementAndGet()+ discardRetained()+ currentTrackId = trackId+ nextPrepareAt = 0L+ wantVideo = wantVideo || on.value+ on.value = false+ fullscreen.value = false+ syncJob?.cancel()+ warmedFor = null+ player?.let { it.stop(); it.clearMediaItems() }+ state.value = State.Idle+ }+ }++ /** Called on a policy change so an old high-quality source is not reused. */+ fun onEnergyPolicyChanged() {+ scope.launch {+ warmedFor = null+ if (!EnergySettings.state.value.policy.allowBackgroundLookups) prefetchJobs.values.forEach { it.cancel() }+ if (on.value && appVisible) (state.value as? State.Ready)?.let(::start)+ else if (!EnergySettings.state.value.policy.allowBackgroundLookups) player?.stop()+ }+ }++ /** App in the background: the video pauses (nothing to show), video mode stays. */+ fun onBackground() {+ appVisible = false+ prepareJob?.cancel()+ prefetchJobs.values.forEach { it.cancel() }+ refineJob?.cancel()+ surfaceIdleJob?.cancel()+ surfaceIdleJob = null+ syncJob?.cancel()+ discardRetained()+ player?.let { it.playWhenReady = false; it.stop() }+ warmedFor = null+ if (state.value is State.Searching) { state.value = State.Idle; nextPrepareAt = 0L }+ }++ /** Back in the foreground: the sync loop seeks the video to the song and plays. */+ fun onForeground() {+ appVisible = true+ if (SongPlayer.isBuffering || !videoLookupOnResumeAllowed(+ EnergySettings.state.value.policy.allowBackgroundLookups, wantVideo, on.value, playerScreens > 0)) return+ val actual = SongPlayer.currentTrackId+ if (actual.isNotBlank() && actual != currentTrackId) {+ prepare(actual, Graph.currentSongState.title.value, Graph.currentSongState.singer.value, SongPlayer.getDuration())+ } else if (state.value is State.Idle && currentTrackId.isNotBlank()) {+ prepare(currentTrackId, currentTitle, currentArtist, currentDuration)+ } else if (on.value) (state.value as? State.Ready)?.let(::start) else resumeWanted()+ }+}diff --git a/base/app/src/main/java/com/music/spotui/video/OrderedClipResolver.kt b/base/app/src/main/java/com/music/spotui/video/OrderedClipResolver.ktnew file mode 100644index 00000000..3ab570da--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/video/OrderedClipResolver.kt@@ -0,0 +1,37 @@+package com.music.spotui.video++import kotlinx.coroutines.async+import kotlinx.coroutines.coroutineScope++internal data class ClipVerification<T>(val value: T? = null, val failed: Boolean = false)+internal data class ClipResolution<T>(val value: T?, val failed: Boolean)++/** Rank is preserved; at most two classifications and one audio candidate at a time. */+internal suspend fun <C, T> firstVerifiedClip(+ candidates: List<C>,+ classify: suspend (C) -> String?,+ verify: suspend (C) -> ClipVerification<T>,+): ClipResolution<T> = coroutineScope {+ var failed = false+ var verified = 0+ for (batch in candidates.chunked(2)) {+ val types = batch.map { candidate -> async { classify(candidate) } }+ for ((index, candidate) in batch.withIndex()) {+ val type = types[index].await()+ if (type == null) { failed = true; continue }+ if (type != "MUSIC_VIDEO_TYPE_OMV") continue+ verified+++ val result = verify(candidate)+ failed = failed || result.failed+ if (result.value != null) {+ types.forEach { it.cancel() }+ return@coroutineScope ClipResolution(result.value, failed)+ }+ if (verified == 3) {+ types.forEach { it.cancel() }+ return@coroutineScope ClipResolution(null, failed)+ }+ }+ }+ ClipResolution(null, failed)+}diff --git a/base/app/src/main/java/com/music/spotui/video/RangeAudioDownload.kt b/base/app/src/main/java/com/music/spotui/video/RangeAudioDownload.ktnew file mode 100644index 00000000..714702e6--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/video/RangeAudioDownload.kt@@ -0,0 +1,70 @@+package com.music.spotui.video++import kotlinx.coroutines.currentCoroutineContext+import kotlinx.coroutines.ensureActive+import kotlinx.coroutines.suspendCancellableCoroutine+import okhttp3.Call+import okhttp3.Callback+import okhttp3.HttpUrl.Companion.toHttpUrl+import okhttp3.OkHttpClient+import okhttp3.Request+import okhttp3.Response+import java.io.File+import java.io.IOException+import java.io.OutputStream+import kotlin.coroutines.resume+import kotlin.coroutines.resumeWithException++/** Bounded copying, with the active HTTP request cancelled on track/background changes. */+internal object RangeAudioDownload {+ suspend fun fetch(client: OkHttpClient, url: String, out: File, headers: Map<String, String>) {+ val parsed = url.toHttpUrl()+ val length = parsed.queryParameter("clen")?.toLongOrNull()?.takeIf { it > 0 }+ out.outputStream().use { output ->+ var start = 0L+ val chunk = 4L shl 20+ while (true) {+ currentCoroutineContext().ensureActive()+ val end = if (length != null) minOf(length, start + chunk) - 1 else start + chunk - 1+ val rangeUrl = parsed.newBuilder().setQueryParameter("range", "$start-$end").build()+ val request = Request.Builder().url(rangeUrl)+ .apply { headers.forEach { (key, value) -> header(key, value) } }.build()+ val count = copyRange(client.newCall(request), output)+ if (start == 0L && count < 1024) throw IOException("Audio response too short")+ start += count+ if (count == 0L || (length != null && start >= length) || (length == null && count < chunk)) break+ }+ }+ }++ private suspend fun copyRange(call: Call, output: OutputStream): Long = suspendCancellableCoroutine { pending ->+ pending.invokeOnCancellation { call.cancel() }+ call.enqueue(object : Callback {+ override fun onFailure(call: Call, e: IOException) {+ if (pending.isActive) pending.resumeWithException(e)+ }+ override fun onResponse(call: Call, response: Response) {+ try {+ val count = response.use { r ->+ if (!r.isSuccessful) throw IOException("Audio HTTP ${r.code}")+ val body = r.body ?: throw IOException("Empty audio response")+ body.byteStream().use { input ->+ val buffer = ByteArray(8192)+ var copied = 0L+ while (pending.isActive) {+ val n = input.read(buffer)+ if (n < 0) break+ output.write(buffer, 0, n)+ copied += n+ }+ copied+ }+ }+ if (pending.isActive) pending.resume(count)+ } catch (t: Exception) {+ if (pending.isActive) pending.resumeWithException(t)+ }+ }+ })+ }+}diff --git a/base/app/src/main/java/com/music/spotui/video/RefinementFiles.kt b/base/app/src/main/java/com/music/spotui/video/RefinementFiles.ktnew file mode 100644index 00000000..2fd1ae4a--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/video/RefinementFiles.kt@@ -0,0 +1,30 @@+package com.music.spotui.video++import java.io.Closeable+import java.io.File+import java.util.UUID++/** Temporary audio owned by exactly one full-map computation. */+internal data class RefinementFiles(val reference: File, val candidate: File) : Closeable {+ override fun close() {+ reference.delete()+ candidate.delete()+ }++ companion object {+ fun retain(reference: File, candidate: File, directory: File): RefinementFiles? {+ val token = UUID.randomUUID().toString()+ val owned = RefinementFiles(File(directory, "mv_full_ref_$token"), File(directory, "mv_full_cand_$token"))+ if (!reference.renameTo(owned.reference) || !candidate.renameTo(owned.candidate)) {+ owned.close()+ return null+ }+ return owned+ }++ fun empty(directory: File): RefinementFiles {+ val token = UUID.randomUUID().toString()+ return RefinementFiles(File(directory, "mv_full_ref_$token"), File(directory, "mv_full_cand_$token"))+ }+ }+}diff --git a/base/app/src/main/java/com/music/spotui/video/SingleFlightCache.kt b/base/app/src/main/java/com/music/spotui/video/SingleFlightCache.ktnew file mode 100644index 00000000..3e39880b--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/video/SingleFlightCache.kt@@ -0,0 +1,75 @@+package com.music.spotui.video++import java.util.concurrent.CompletableFuture+import java.util.concurrent.ExecutionException++/** Caller-owned synchronous loads; a cancelled owner never leaves a detached retry. */+internal class SingleFlightCache<K : Any, V : Any>(+ private val capacity: Int,+ private val ttlMs: Long,+ private val nowMs: () -> Long = { System.nanoTime() / 1_000_000 },+) {+ private data class Entry<V>(val value: V, val at: Long)+ private val lock = Any()+ private val values = LinkedHashMap<K, Entry<V>>(16, 0.75f, true)+ private val flights = HashMap<K, CompletableFuture<V>>()++ init { require(capacity > 0 && ttlMs >= 0) }++ internal val cachedSize: Int get() = synchronized(lock) { values.size }+ internal val inFlightCount: Int get() = synchronized(lock) { flights.size }++ fun get(key: K, fresh: Boolean = false, load: () -> V): V {+ checkInterrupted()+ val future: CompletableFuture<V>+ val owner: Boolean+ synchronized(lock) {+ val now = nowMs()+ values.entries.removeAll { (_, entry) -> now - entry.at !in 0 until ttlMs }+ val active = flights[key]+ if (active != null) {+ future = active+ owner = false+ } else {+ if (!fresh) values[key]?.let { return it.value }+ // A forced refresh normally follows a refused URL; do not reuse it after failure.+ if (fresh) values.remove(key)+ future = CompletableFuture()+ flights[key] = future+ owner = true+ }+ }+ if (!owner) {+ try {+ return future.get().also { checkInterrupted() }+ } catch (t: InterruptedException) {+ Thread.currentThread().interrupt()+ throw t+ } catch (t: ExecutionException) {+ throw t.cause ?: t+ }+ }+ try {+ val value = load()+ checkInterrupted()+ synchronized(lock) {+ if (ttlMs > 0) values[key] = Entry(value, nowMs())+ while (values.size > capacity) values.remove(values.keys.first())+ flights.remove(key)+ future.complete(value)+ }+ return value+ } catch (t: Throwable) {+ if (t is InterruptedException) Thread.currentThread().interrupt()+ synchronized(lock) {+ flights.remove(key)+ future.completeExceptionally(t)+ }+ throw t+ }+ }+}++internal fun checkInterrupted() {+ if (Thread.currentThread().isInterrupted) throw InterruptedException("Video metadata request interrupted")+}diff --git a/base/app/src/main/java/com/music/spotui/video/VideoLookupPolicy.kt b/base/app/src/main/java/com/music/spotui/video/VideoLookupPolicy.ktnew file mode 100644index 00000000..dce2a785--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/video/VideoLookupPolicy.kt@@ -0,0 +1,9 @@+package com.music.spotui.video++/** Saver skips automatic app-resume lookup; a visible player or video intent still requests it. */+internal fun videoLookupOnResumeAllowed(+ allowAutomatic: Boolean,+ wantVideo: Boolean,+ videoOn: Boolean,+ playerVisible: Boolean,+): Boolean = allowAutomatic || wantVideo || videoOn || playerVisiblediff --git a/base/app/src/main/java/com/music/spotui/video/YouTubeSource.kt b/base/app/src/main/java/com/music/spotui/video/YouTubeSource.ktnew file mode 100644index 00000000..66f8af15--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/video/YouTubeSource.kt@@ -0,0 +1,303 @@+package com.music.spotui.video++import android.util.Log+import okhttp3.OkHttpClient+import okhttp3.RequestBody.Companion.toRequestBody+import org.schabi.newpipe.extractor.NewPipe+import org.schabi.newpipe.extractor.ServiceList+import org.schabi.newpipe.extractor.downloader.Downloader+import org.schabi.newpipe.extractor.downloader.Request+import org.schabi.newpipe.extractor.downloader.Response+import org.schabi.newpipe.extractor.localization.ContentCountry+import org.schabi.newpipe.extractor.localization.Localization+import org.schabi.newpipe.extractor.services.youtube.linkHandler.YoutubeSearchQueryHandlerFactory+import org.schabi.newpipe.extractor.stream.StreamInfo+import org.schabi.newpipe.extractor.stream.StreamInfoItem+import java.util.Locale+import org.json.JSONObject+import java.util.concurrent.TimeUnit+import java.io.IOException+import java.util.concurrent.CancellationException+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.async+import kotlinx.coroutines.coroutineScope+import kotlinx.coroutines.runInterruptible++/**+ * YouTube side of music videos, through NewPipeExtractor (as Spotui / NewPipe do):+ * find the track's YouTube Music "song" (same master as Spotify) and its official+ * music video, and resolve their streams.+ */+object YouTubeSource {+ private const val TAG = "MusicVideo"+ private const val UA = "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:128.0) Gecko/20100101 Firefox/128.0"++ val http: OkHttpClient = OkHttpClient.Builder()+ .addInterceptor(com.music.spotui.data.DataSaver.interceptor)+ .connectTimeout(15, TimeUnit.SECONDS)+ .readTimeout(30, TimeUnit.SECONDS)+ .build()++ @Volatile private var ready = false+ @Volatile private var extractorLocale = ""+ private val infoCache = SingleFlightCache<String, StreamInfo>(24, 30 * 60_000L)+ private val typeCache = SingleFlightCache<String, String>(128, 6 * 3_600_000L)+ private val staticCache = SingleFlightCache<String, Boolean>(64, 6 * 3_600_000L)+ private val searchCache = SingleFlightCache<String, List<Hit>>(24, 2 * 60_000L)+ private class Undecidable : IOException("Video classification unavailable")++ private fun <T> optionalExtraction(name: String, block: () -> T): T? = try {+ checkInterrupted()+ block()+ } catch (t: Throwable) {+ if (t is CancellationException) throw t+ if (t is InterruptedException || Thread.currentThread().isInterrupted) {+ Thread.currentThread().interrupt()+ if (t is InterruptedException) throw t+ throw InterruptedException("Video metadata extraction interrupted").apply { initCause(t) }+ }+ Log.w(TAG, "$name failed: ${t.javaClass.simpleName}")+ null+ }++ private fun init() {+ if (ready) return+ synchronized(this) {+ if (ready) return+ val loc = Locale.getDefault()+ extractorLocale = loc.toLanguageTag()+ NewPipe.init(OkDownloader, Localization(loc.language, loc.country.ifBlank { null }), ContentCountry(loc.country.ifBlank { "US" }))+ ready = true+ }+ }++ private object OkDownloader : Downloader() {+ override fun execute(request: Request): Response {+ val body = request.dataToSend()?.toRequestBody()+ val b = okhttp3.Request.Builder()+ .url(request.url())+ .method(request.httpMethod(), body)+ .header("User-Agent", UA)+ request.headers().forEach { (k, values) ->+ b.removeHeader(k)+ values.forEach { b.addHeader(k, it) }+ }+ return InterruptibleHttp.read(http.newCall(b.build())) { r ->+ Response(+ r.code, r.message, r.headers.toMultimap(),+ r.body?.string(), r.request.url.toString(),+ )+ }+ }+ }++ data class Hit(val url: String, val name: String, val uploader: String, val durationSec: Long)++ private fun folded(s: String) = java.text.Normalizer.normalize(s, java.text.Normalizer.Form.NFD)+ .replace(Regex("""\p{M}+"""), "").lowercase(Locale.ROOT)++ private fun norm(s: String) = folded(s)+ .replace(Regex("""\(.*?\)|\[.*?]"""), " ")+ .replace(Regex("""\b(?:feat|ft)\.?(?=\s|$)|\b(?:official|music|video|audio|clip|lyrics?)\b"""), " ")+ .filter { it.isLetterOrDigit() }++ private fun search(query: String, filter: String): List<Hit> {+ checkInterrupted()+ init()+ val key = "$filter\u0000$query\u0000$extractorLocale"+ return searchCache.get(key) {+ // Extractors are mutable and never shared; only a completed list of immutable Hits is cached.+ val ext = ServiceList.YouTube.getSearchExtractor(query, listOf(filter), "")+ ext.fetchPage()+ checkInterrupted()+ ext.initialPage.items.filterIsInstance<StreamInfoItem>().map {+ Hit(it.url.replace("://music.youtube.com/", "://www.youtube.com/"), it.name, it.uploaderName.orEmpty(), it.duration)+ }+ }+ }++ private fun elided(s: String) = s.replace(Regex("""(?<=\p{L})['’](?=\p{L})"""), "")++ /** The YouTube Music "song" of the track (Topic / art track), duration within 3 s. */+ fun findSong(title: String, artist: String, durationMs: Long): Hit? {+ val main = artist.substringBefore(",").trim()+ val hits = search("$title $main", YoutubeSearchQueryHandlerFactory.MUSIC_SONGS)+ return hits.firstOrNull { h ->+ val nameOk = titleMatches(h.name, title)+ val durOk = durationMs <= 0 || kotlin.math.abs(h.durationSec * 1000 - durationMs) <= 3000+ nameOk && durOk && sameArtist(h, main)+ }+ }++ private val excluded = Regex("""(?i)\b(lyrics?|paroles|cover|remix|reaction|karaok[eé]|slowed|sped ?up|nightcore|8d|instrumentale?|extended|tutorial|piano|guitar)\b""")++ /** Title words that must appear in a candidate's name (most of them). */+ private fun titleMatches(candidate: String, title: String): Boolean {+ // An elided word stays one word ("J'SAVAIS" is "jsavais", not "savais", which+ // "Si tu savais" also holds).+ val words = elided(folded(title)).replace(Regex("""\(.*?\)|\[.*?]|\b(?:feat|ft)\.?\s+.*"""), " ")+ .split(Regex("""[^\p{L}\p{N}]+""")).filter { it.length > 1 }+ if (words.isEmpty()) return norm(candidate).contains(norm(title))+ val candidateWords = elided(folded(candidate)).split(Regex("""[^\p{L}\p{N}]+""")).toSet()+ return words.count { it in candidateWords } >= (words.size * 0.6).coerceAtLeast(1.0)+ }++ /**+ * Possible music videos for the track, best first: YouTube Music's videos, then a+ * plain YouTube search (clips posted by a label, a radio, a collective…). The+ * channel is not trusted; [MusicVideoController] keeps the one whose soundtrack+ * really aligns with the song.+ */+ suspend fun videoCandidates(title: String, artist: String, durationMs: Long): List<Hit> = coroutineScope {+ val main = artist.substringBefore(",").trim()+ val a = norm(main)+ val music = async(Dispatchers.IO) { runInterruptible { search("$title $main", YoutubeSearchQueryHandlerFactory.MUSIC_VIDEOS) } }+ val plain = async(Dispatchers.IO) { runInterruptible { search("$title $main clip officiel official video", YoutubeSearchQueryHandlerFactory.VIDEOS) } }+ (music.await().take(6) + plain.await().take(8))+ .distinctBy { it.url }+ .filter { h ->+ val sec = h.durationSec * 1000+ titleMatches(h.name, title) && !excluded.containsMatchIn(h.name) &&+ (durationMs <= 0 || (sec >= durationMs - 10_000 && sec <= durationMs + 240_000))+ }+ // Same artist (in the channel or the title) first, then the search order.+ .sortedBy { h -> if (norm(h.uploader).contains(a) || norm(h.name).contains(a)) 0 else 1 }+ }++ /** A YouTube upload of the plain song (official audio) when YouTube Music has none. */+ fun findAudio(title: String, artist: String, durationMs: Long): Hit? {+ val main = artist.substringBefore(",").trim()+ val hits = search("$title $main audio", YoutubeSearchQueryHandlerFactory.VIDEOS)+ return hits.firstOrNull { h ->+ titleMatches(h.name, title) && !excluded.containsMatchIn(h.name) &&+ durationMs > 0 && kotlin.math.abs(h.durationSec * 1000 - durationMs) <= 2500+ }+ }++ /** Completed metadata is shared read-only; never mutate its streams or the returned StreamInfo. */+ fun info(url: String, fresh: Boolean = false): StreamInfo {+ checkInterrupted()+ init()+ val canonical = YouTubeUrlKey.canonicalUrl(url)+ return infoCache.get(YouTubeUrlKey.cacheKey(url, extractorLocale), fresh) {+ StreamInfo.getInfo(ServiceList.YouTube, canonical)+ }+ }++ fun videoId(url: String): String? = YouTubeUrlKey.videoId(url)++ /**+ * YouTube Music's own classification of a video: MUSIC_VIDEO_TYPE_OMV (official+ * music video), _ATV (the song with its cover: no clip), _UGC (any other upload)…+ */+ fun musicVideoType(url: String): String? = optionalExtraction("video type") {+ val id = videoId(url) ?: throw Undecidable()+ val loc = Locale.getDefault()+ typeCache.get(YouTubeUrlKey.cacheKey(url, loc.toLanguageTag())) {+ val body = JSONObject().put("context", JSONObject().put("client", JSONObject()+ .put("clientName", "WEB_REMIX").put("clientVersion", "1.20250929.01.00")+ .put("hl", loc.language).put("gl", loc.country.ifBlank { "US" })))+ .put("videoId", id).toString()+ val req = okhttp3.Request.Builder().url("https://music.youtube.com/youtubei/v1/next?prettyPrint=false")+ .post(body.toRequestBody())+ .header("Content-Type", "application/json").header("User-Agent", UA)+ .header("Origin", "https://music.youtube.com").build()+ val text = InterruptibleHttp.read(http.newCall(req)) {+ if (!it.isSuccessful) throw IOException("Video type HTTP ${it.code}")+ it.body?.string().orEmpty()+ }+ val i = text.indexOf("\"videoId\":\"$id\"")+ if (i < 0) throw Undecidable()+ // Preserve the existing OMV/ATV/UGC classification; unknown responses are never cached.+ Regex("""\"musicVideoType\":\"(MUSIC_VIDEO_TYPE_\w+)\"""")+ .find(text.substring(i, minOf(text.length, i + 3000)))?.groupValues?.get(1) ?: throw Undecidable()+ }+ }++ /**+ * True when the video is a still image (the song over its cover): the storyboard+ * thumbnails YouTube makes for the seek bar barely change from frame to frame.+ */+ fun isStatic(info: StreamInfo): Boolean? = optionalExtraction("storyboard") {+ staticCache.get(YouTubeUrlKey.cacheKey(info.url, extractorLocale)) {+ val fs = info.previewFrames.minByOrNull { it.frameWidth } ?: throw Undecidable()+ val urls = fs.urls+ if (urls.isEmpty()) throw Undecidable()+ // A full sheet from the middle (intros are often a title card; the last sheet+ // can hold just a few frames of a single shot).+ val perPageAll = fs.framesPerPageX * fs.framesPerPageY+ val fullSheets = maxOf(1, fs.totalCount / maxOf(1, perPageAll))+ val sheet = minOf(urls.size / 2, fullSheets - 1).coerceIn(0, urls.size - 1)+ val sheetUrl = urls[sheet]+ val perPage = fs.framesPerPageX * fs.framesPerPageY+ // The last sheet is only partly filled: empty (black) cells are not frames.+ val inSheet = minOf(perPage, fs.totalCount - sheet * perPage)+ val bytes = InterruptibleHttp.read(http.newCall(okhttp3.Request.Builder().url(sheetUrl).header("User-Agent", UA).build())) {+ if (!it.isSuccessful) throw IOException("Storyboard HTTP ${it.code}")+ it.body?.bytes()+ } ?: throw Undecidable()+ val bmp = android.graphics.BitmapFactory.decodeByteArray(bytes, 0, bytes.size) ?: throw Undecidable()+ try {+ val w = fs.frameWidth; val h = fs.frameHeight+ val frames = ArrayList<IntArray>()+ for (y in 0 until fs.framesPerPageY) for (x in 0 until fs.framesPerPageX) {+ checkInterrupted()+ if (y * fs.framesPerPageX + x >= inSheet) continue+ if ((x + 1) * w > bmp.width || (y + 1) * h > bmp.height) continue+ val px = IntArray(w * h)+ bmp.getPixels(px, 0, w, x * w, y * h, w, h)+ frames.add(px)+ }+ if (frames.size < 12) throw Undecidable()+ // Share of pixels that clearly change between neighbouring thumbnails. A still+ // cover only shows JPEG noise (max ~0.3 %); real clips, even dark ones, change+ // far more (measured: 19–77 % at their cuts).+ var maxChanged = 0.0+ for (f in 1 until frames.size) {+ checkInterrupted()+ val a = frames[f - 1]; val b = frames[f]+ var changed = 0+ for (p in a.indices) {+ val la = (a[p] shr 16 and 255) + (a[p] shr 8 and 255) + (a[p] and 255)+ val lb = (b[p] shr 16 and 255) + (b[p] shr 8 and 255) + (b[p] and 255)+ if (kotlin.math.abs(la - lb) > 90) changed+++ }+ maxChanged = maxOf(maxChanged, changed.toDouble() / a.size)+ }+ Log.i(TAG, "storyboard ${info.name}: ${frames.size} frames ${w}x$h (sheet ${bmp.width}x${bmp.height}), max changed ${"%.1f".format(maxChanged * 100)} %")+ maxChanged < 0.02+ } finally { bmp.recycle() }+ }+ }++ /** Uploads that are not a clip even when YouTube Music files them as one. */+ private val notAClip = Regex("""(?i)\b(audio officiel|official audio|lyric video|paroles\s*/\s*lyrics|letra|testo|sped up|reverb)\b""")++ /**+ * Whether the real YouTube upload behind a candidate can be the artist's clip.+ * YouTube Music rewrites a matched upload's channel to the artist and its title to the+ * song's (a fan's "melodrama (Paroles/Lyrics)" shows as "melodrama" by "disiz et+ * Theodora", typed OMV), so [info] (read from youtube.com) is the one to check: the real+ * title must not be a lyric / audio / edited upload, and the real channel must be one of+ * the artists' own (or their VEVO / Topic), or a verified channel (label, radio)+ * whose title says it is a clip.+ */+ fun isTrustedClip(info: StreamInfo, artist: String): Boolean {+ val name = info.name.orEmpty()+ if (excluded.containsMatchIn(name) || notAClip.containsMatchIn(name)) return false+ val hit = Hit(info.url, name, info.uploaderName.orEmpty(), info.duration)+ val own = artist.split(",").map { it.trim() }.filter { it.isNotEmpty() }.any { sameArtist(hit, it) }+ return own || (info.isUploaderVerified && looksLikeClip(name))+ }++ /** A title that says it is a clip (official / music video / clip officiel…). */+ fun looksLikeClip(name: String): Boolean =+ Regex("""(?i)\b(clip|official (music )?video|music video|vid[eé]o officielle|vid[eé]oclip|videoclip|official visualizer)\b""").containsMatchIn(name)++ fun sameArtist(h: Hit, artist: String): Boolean {+ val a = norm(artist.substringBefore(",").trim())+ val channel = folded(h.uploader).replace(Regex("""\s*-\s*topic$|(?<=.)vevo$"""), "")+ val u = norm(channel)+ return a.isNotEmpty() && u == a+ }+}diff --git a/base/app/src/main/java/com/music/spotui/video/YouTubeUrlKey.kt b/base/app/src/main/java/com/music/spotui/video/YouTubeUrlKey.ktnew file mode 100644index 00000000..68003cd1--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/video/YouTubeUrlKey.kt@@ -0,0 +1,36 @@+package com.music.spotui.video++import java.net.URI+import java.net.URLDecoder+import java.util.Locale++internal object YouTubeUrlKey {+ private val idPattern = Regex("[A-Za-z0-9_-]{11}")+ fun videoId(url: String): String? = runCatching {+ val uri = URI(url)+ val scheme = uri.scheme?.lowercase(Locale.ROOT)+ if ((scheme != "http" && scheme != "https") || uri.rawUserInfo != null) return null+ if (uri.port != -1 && uri.port != if (scheme == "https") 443 else 80) return null+ val host = uri.host?.lowercase(Locale.ROOT) ?: return null+ val id = when (host) {+ "youtu.be" -> uri.path.removePrefix("/").takeIf { '/' !in it }+ "youtube.com", "www.youtube.com", "music.youtube.com", "m.youtube.com" -> when {+ uri.path == "/watch" -> {+ val ids = uri.rawQuery.orEmpty().split('&').mapNotNull { part ->+ if (part.substringBefore('=') != "v") null+ else URLDecoder.decode(part.substringAfter('=', ""), "UTF-8")+ }+ ids.singleOrNull()+ }+ uri.path.startsWith("/shorts/") -> uri.path.removePrefix("/shorts/").takeIf { '/' !in it }+ uri.path.startsWith("/embed/") -> uri.path.removePrefix("/embed/").takeIf { '/' !in it }+ else -> null+ }+ else -> null+ }+ id?.takeIf { idPattern.matches(it) }+ }.getOrNull()++ fun canonicalUrl(url: String): String = videoId(url)?.let { "https://www.youtube.com/watch?v=$it" } ?: url+ fun cacheKey(url: String, locale: String): String = canonicalUrl(url) + "|locale=" + locale+}diff --git a/base/app/src/main/java/com/music/spotui/widget/NowPlayingWidget.kt b/base/app/src/main/java/com/music/spotui/widget/NowPlayingWidget.ktnew file mode 100644index 00000000..2e1a79b8--- /dev/null+++ b/base/app/src/main/java/com/music/spotui/widget/NowPlayingWidget.kt@@ -0,0 +1,99 @@+package com.music.spotui.widget++import android.app.PendingIntent+import android.appwidget.AppWidgetManager+import android.appwidget.AppWidgetProvider+import android.content.ComponentName+import android.content.Context+import android.content.Intent+import android.graphics.Bitmap+import android.graphics.BitmapFactory+import android.widget.RemoteViews+import app.myspoti.engine.R+import com.music.spotui.di.SongPlayer+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.SupervisorJob+import kotlinx.coroutines.launch+import okhttp3.OkHttpClient+import okhttp3.Request+import java.util.concurrent.TimeUnit++/**+ * Home screen widget (4x1): the current track with previous, play / pause and next.+ * [show] is called with each now-playing change; the buttons drive [SongPlayer].+ */+class NowPlayingWidget : AppWidgetProvider() {++ override fun onUpdate(context: Context, manager: AppWidgetManager, ids: IntArray) = render(context, manager, ids)++ override fun onReceive(context: Context, intent: Intent) {+ when (intent.action) {+ ACTION_PREVIOUS -> SongPlayer.previous()+ ACTION_TOGGLE -> if (SongPlayer.isPlaying()) SongPlayer.pause() else SongPlayer.play()+ ACTION_NEXT -> SongPlayer.next()+ else -> super.onReceive(context, intent)+ }+ }++ companion object {+ private const val ACTION_PREVIOUS = "app.myspoti.widget.PREVIOUS"+ private const val ACTION_TOGGLE = "app.myspoti.widget.TOGGLE"+ private const val ACTION_NEXT = "app.myspoti.widget.NEXT"++ private data class Shown(val title: String, val artist: String, val coverUrl: String?, val playing: Boolean)++ @Volatile private var shown = Shown("", "", null, false)+ @Volatile private var cover: Bitmap? = null+ @Volatile private var coverUrl: String? = null+ private val io = CoroutineScope(SupervisorJob() + Dispatchers.IO)+ private val http by lazy { OkHttpClient.Builder().callTimeout(10, TimeUnit.SECONDS).build() }++ /** The track on screen changed (or its play state): redraw the widgets, if any. */+ fun show(context: Context, title: String, artist: String, coverUrl: String?, playing: Boolean) {+ val next = Shown(title, artist, coverUrl, playing)+ if (next == shown) return+ shown = next+ val app = context.applicationContext+ val manager = AppWidgetManager.getInstance(app)+ val ids = manager.getAppWidgetIds(ComponentName(app, NowPlayingWidget::class.java))+ if (ids.isEmpty()) return+ render(app, manager, ids)+ if (coverUrl != null && coverUrl != this.coverUrl) io.launch {+ val bmp = runCatching {+ http.newCall(Request.Builder().url(coverUrl).build()).execute().use { r ->+ BitmapFactory.decodeStream(r.body.byteStream())?.let { Bitmap.createScaledBitmap(it, 160, 160, true) }+ }+ }.getOrNull() ?: return@launch+ // A later track may have replaced it meanwhile.+ if (shown.coverUrl != coverUrl) return@launch+ cover = bmp+ [email protected] = coverUrl+ render(app, manager, ids)+ }+ }++ private fun render(context: Context, manager: AppWidgetManager, ids: IntArray) {+ val s = shown+ val views = RemoteViews(context.packageName, R.layout.widget_now_playing).apply {+ setTextViewText(R.id.widget_title, s.title.ifBlank { context.getString(R.string.app_name) })+ setTextViewText(R.id.widget_artist, s.artist)+ val bmp = cover.takeIf { coverUrl == s.coverUrl }+ if (bmp != null) setImageViewBitmap(R.id.widget_cover, bmp) else setImageViewResource(R.id.widget_cover, R.mipmap.ic_launcher)+ setImageViewResource(R.id.widget_play, if (s.playing) app.myspoti.host.android.R.drawable.msp_ic_pause else app.myspoti.host.android.R.drawable.msp_ic_play)+ setOnClickPendingIntent(R.id.widget_previous, action(context, ACTION_PREVIOUS, 1))+ setOnClickPendingIntent(R.id.widget_play, action(context, ACTION_TOGGLE, 2))+ setOnClickPendingIntent(R.id.widget_next, action(context, ACTION_NEXT, 3))+ val open = context.packageManager.getLaunchIntentForPackage(context.packageName)+ if (open != null) setOnClickPendingIntent(R.id.widget_root,+ PendingIntent.getActivity(context, 4, open, PendingIntent.FLAG_IMMUTABLE or PendingIntent.FLAG_UPDATE_CURRENT))+ }+ manager.updateAppWidget(ids, views)+ }++ private fun action(context: Context, action: String, code: Int) = PendingIntent.getBroadcast(+ context, code, Intent(context, NowPlayingWidget::class.java).setAction(action),+ PendingIntent.FLAG_IMMUTABLE or PendingIntent.FLAG_UPDATE_CURRENT,+ )+ }+}diff --git a/base/app/src/main/res/drawable/added.xml b/base/app/src/main/res/drawable/added.xmlnew file mode 100644index 00000000..ba55950b--- /dev/null+++ b/base/app/src/main/res/drawable/added.xml@@ -0,0 +1,9 @@+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="512dp"+ android:height="512dp"+ android:viewportWidth="408.58"+ android:viewportHeight="408.58">+ <path+ android:pathData="M204.29,0C91.65,0 0,91.65 0,204.29s91.65,204.29 204.29,204.29 204.29,-91.65 204.29,-204.29S316.93,0 204.29,0zM318.46,150.53 L187.9,280.06c-7.68,7.68 -19.97,8.19 -28.16,0.51L90.62,217.6c-8.19,-7.68 -8.7,-20.48 -1.54,-28.67 7.68,-8.19 20.48,-8.7 28.67,-1.02l54.78,50.18L289.28,121.34c8.19,-8.19 20.99,-8.19 29.18,0s8.19,20.99 0,29.18z"+ android:fillColor="#000000"/>+</vector>diff --git a/base/app/src/main/res/drawable/album.jpeg b/base/app/src/main/res/drawable/album.jpegnew file mode 100644index 00000000..ff6a8e18Binary files /dev/null and b/base/app/src/main/res/drawable/album.jpeg differdiff --git a/base/app/src/main/res/drawable/downloads_cover.xml b/base/app/src/main/res/drawable/downloads_cover.xmlnew file mode 100644index 00000000..31a4a41d--- /dev/null+++ b/base/app/src/main/res/drawable/downloads_cover.xml@@ -0,0 +1,10 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- "Downloaded" cover: a white download arrow on green (Material "download", Apache 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="64dp" android:height="64dp"+ android:viewportWidth="64" android:viewportHeight="64">+ <path android:fillColor="#FF1D6B45" android:pathData="M0,0h64v64h-64z" />+ <group android:translateX="14" android:translateY="14" android:scaleX="1.5" android:scaleY="1.5">+ <path android:fillColor="#FFFFFFFF" android:pathData="M19,9h-4V3H9v6H5l7,7 7,-7zM5,18v2h14v-2H5z" />+ </group>+</vector>diff --git a/base/app/src/main/res/drawable/folder_cover.xml b/base/app/src/main/res/drawable/folder_cover.xmlnew file mode 100644index 00000000..e84f1f17--- /dev/null+++ b/base/app/src/main/res/drawable/folder_cover.xml@@ -0,0 +1,10 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Library folder cover: a white folder on dark grey (Material "folder", Apache 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="64dp" android:height="64dp"+ android:viewportWidth="64" android:viewportHeight="64">+ <path android:fillColor="#FF333333" android:pathData="M0,0h64v64h-64z" />+ <group android:translateX="14" android:translateY="14" android:scaleX="1.5" android:scaleY="1.5">+ <path android:fillColor="#FFB3B3B3" android:pathData="M10,4H4c-1.1,0 -1.99,0.9 -1.99,2L2,18c0,1.1 0.9,2 2,2h16c1.1,0 2,-0.9 2,-2V8c0,-1.1 -0.9,-2 -2,-2h-8l-2,-2z" />+ </group>+</vector>diff --git a/base/app/src/main/res/drawable/ic_add.xml b/base/app/src/main/res/drawable/ic_add.xmlnew file mode 100644index 00000000..cb9dbbf6--- /dev/null+++ b/base/app/src/main/res/drawable/ic_add.xml@@ -0,0 +1,12 @@+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="512dp"+ android:height="512dp"+ android:viewportWidth="512"+ android:viewportHeight="512">+ <path+ android:pathData="M256,0C114.83,0 0,114.83 0,256s114.83,256 256,256 256,-114.85 256,-256S397.17,0 256,0zM256,472.34c-119.28,0 -216.34,-97.05 -216.34,-216.34S136.73,39.66 256,39.66 472.34,136.71 472.34,256 375.3,472.34 256,472.34z"+ android:fillColor="#000000"/>+ <path+ android:pathData="M355.15,234.39H275.83v-79.32c0,-10.95 -8.86,-19.83 -19.83,-19.83s-19.83,8.88 -19.83,19.83v79.32h-79.32c-10.97,0 -19.83,8.88 -19.83,19.83s8.86,19.83 19.83,19.83h79.32v79.32c0,10.95 8.86,19.83 19.83,19.83s19.83,-8.88 19.83,-19.83v-79.32h79.32c10.97,0 19.83,-8.88 19.83,-19.83s-8.86,-19.83 -19.83,-19.83z"+ android:fillColor="#000000"/>+</vector>diff --git a/base/app/src/main/res/drawable/ic_devices.xml b/base/app/src/main/res/drawable/ic_devices.xmlnew file mode 100644index 00000000..96238f29--- /dev/null+++ b/base/app/src/main/res/drawable/ic_devices.xml@@ -0,0 +1,10 @@+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="512dp"+ android:height="512dp"+ android:viewportWidth="512"+ android:viewportHeight="512">+ <path+ android:pathData="M478.32,125.94L478.32,72.5c0,-25.21 -20.51,-45.71 -45.71,-45.71h-386.9C20.51,26.78 0,47.29 0,72.5L0,308.06c0,25.21 20.51,45.71 45.71,45.71h107.12l-5.93,48.03h-26.56c-23,0 -41.71,18.71 -41.71,41.71 0,23 18.71,41.71 41.71,41.71h343.7c26.44,0 47.95,-21.51 47.95,-47.95L512,171.72c0,-21.47 -14.19,-39.69 -33.68,-45.78zM32,308.06L32,72.5c0,-7.56 6.15,-13.71 13.71,-13.71h386.9c7.56,0 13.71,6.15 13.71,13.71v51.27L339.2,123.77c-26.44,0 -47.95,21.51 -47.95,47.95v150.05L45.71,321.77C38.15,321.77 32,315.62 32,308.06zM185.08,353.77h106.17v48.03L179.15,401.8zM110.64,443.51c0,-5.26 4.45,-9.71 9.71,-9.71h170.91v3.46c0,5.59 0.97,10.96 2.74,15.95L120.34,453.22c-5.26,0 -9.71,-4.45 -9.71,-9.71zM480,437.26c0,8.8 -7.16,15.95 -15.95,15.95L339.2,453.22c-8.8,0 -15.95,-7.16 -15.95,-15.95L323.25,171.72c0,-8.8 7.16,-15.95 15.95,-15.95h124.84c8.8,0 15.95,7.16 15.95,15.95zM424.87,406.81c0,12.8 -10.44,23.25 -23.25,23.25s-23.25,-10.44 -23.25,-23.25 10.44,-23.25 23.25,-23.25 23.25,10.44 23.25,23.25z"+ android:fillColor="#000000"+ android:fillType="evenOdd"/>+</vector>diff --git a/base/app/src/main/res/drawable/ic_down.xml b/base/app/src/main/res/drawable/ic_down.xmlnew file mode 100644index 00000000..8bdeed09--- /dev/null+++ b/base/app/src/main/res/drawable/ic_down.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons "keyboard_arrow_down" (Google, Apache License 2.0). Tinted by the caller. -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M7.41,8.59L12,13.17l4.59,-4.58L18,10l-6,6 -6,-6 1.41,-1.41z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_favorite.xml b/base/app/src/main/res/drawable/ic_favorite.xmlnew file mode 100644index 00000000..50bfe125--- /dev/null+++ b/base/app/src/main/res/drawable/ic_favorite.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons (Google, Apache License 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M16.5,3c-1.74,0 -3.41,0.81 -4.5,2.09C10.91,3.81 9.24,3 7.5,3 4.42,3 2,5.42 2,8.5c0,3.78 3.4,6.86 8.55,11.54L12,21.35l1.45,-1.32C18.6,15.36 22,12.28 22,8.5 22,5.42 19.58,3 16.5,3zM12.1,18.55l-0.1,0.1 -0.1,-0.1C7.14,14.24 4,11.39 4,8.5 4,6.5 5.5,5 7.5,5c1.54,0 3.04,0.99 3.57,2.36h1.87C13.46,5.99 14.96,5 16.5,5c2,0 3.5,1.5 3.5,3.5 0,2.89 -3.14,5.74 -7.9,10.05z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_favorite_filled.xml b/base/app/src/main/res/drawable/ic_favorite_filled.xmlnew file mode 100644index 00000000..87f25a7f--- /dev/null+++ b/base/app/src/main/res/drawable/ic_favorite_filled.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons (Google, Apache License 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FF1ED760" android:pathData="M12,21.35l-1.45,-1.32C5.4,15.36 2,12.28 2,8.5 2,5.42 4.42,3 7.5,3c1.74,0 3.41,0.81 4.5,2.09C13.09,3.81 14.76,3 16.5,3 19.58,3 22,5.42 22,8.5c0,3.78 -3.4,6.86 -8.55,11.54L12,21.35z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_home_filled.xml b/base/app/src/main/res/drawable/ic_home_filled.xmlnew file mode 100644index 00000000..d8dbdb61--- /dev/null+++ b/base/app/src/main/res/drawable/ic_home_filled.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons "home" (Google, Apache License 2.0). Tinted by the caller. -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="23dp" android:height="22dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M10,20v-6h4v6h5v-8h3L12,3 2,12h3v8z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_launcher_background.xml b/base/app/src/main/res/drawable/ic_launcher_background.xmlnew file mode 100644index 00000000..15188bab--- /dev/null+++ b/base/app/src/main/res/drawable/ic_launcher_background.xml@@ -0,0 +1,6 @@+<?xml version="1.0" encoding="utf-8"?>+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="108dp" android:height="108dp"+ android:viewportWidth="108" android:viewportHeight="108">+ <path android:fillColor="#121212" android:pathData="M0,0h108v108h-108z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_launcher_foreground.xml b/base/app/src/main/res/drawable/ic_launcher_foreground.xmlnew file mode 100644index 00000000..c3b3711d--- /dev/null+++ b/base/app/src/main/res/drawable/ic_launcher_foreground.xml@@ -0,0 +1,10 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Myspoti launcher mark: four rounded equalizer bars (adaptive-icon safe zone). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="108dp" android:height="108dp"+ android:viewportWidth="108" android:viewportHeight="108">+ <path android:pathData="M38,47 L38,61" android:strokeColor="#1ED760" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M48.7,37 L48.7,71" android:strokeColor="#1ED760" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M59.3,42 L59.3,66" android:strokeColor="#1ED760" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M70,49 L70,59" android:strokeColor="#1ED760" android:strokeWidth="7.5" android:strokeLineCap="round" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_launcher_foreground_blue.xml b/base/app/src/main/res/drawable/ic_launcher_foreground_blue.xmlnew file mode 100644index 00000000..a4ecf1df--- /dev/null+++ b/base/app/src/main/res/drawable/ic_launcher_foreground_blue.xml@@ -0,0 +1,10 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Myspoti launcher mark (blue, a supporter icon): four rounded equalizer bars (adaptive-icon safe zone). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="108dp" android:height="108dp"+ android:viewportWidth="108" android:viewportHeight="108">+ <path android:pathData="M38,47 L38,61" android:strokeColor="#509BF5" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M48.7,37 L48.7,71" android:strokeColor="#509BF5" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M59.3,42 L59.3,66" android:strokeColor="#509BF5" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M70,49 L70,59" android:strokeColor="#509BF5" android:strokeWidth="7.5" android:strokeLineCap="round" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_launcher_foreground_orange.xml b/base/app/src/main/res/drawable/ic_launcher_foreground_orange.xmlnew file mode 100644index 00000000..2cdb9950--- /dev/null+++ b/base/app/src/main/res/drawable/ic_launcher_foreground_orange.xml@@ -0,0 +1,10 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Myspoti launcher mark (orange, a supporter icon): four rounded equalizer bars (adaptive-icon safe zone). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="108dp" android:height="108dp"+ android:viewportWidth="108" android:viewportHeight="108">+ <path android:pathData="M38,47 L38,61" android:strokeColor="#FF9E3D" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M48.7,37 L48.7,71" android:strokeColor="#FF9E3D" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M59.3,42 L59.3,66" android:strokeColor="#FF9E3D" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M70,49 L70,59" android:strokeColor="#FF9E3D" android:strokeWidth="7.5" android:strokeLineCap="round" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_launcher_foreground_pink.xml b/base/app/src/main/res/drawable/ic_launcher_foreground_pink.xmlnew file mode 100644index 00000000..597d2e0a--- /dev/null+++ b/base/app/src/main/res/drawable/ic_launcher_foreground_pink.xml@@ -0,0 +1,10 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Myspoti launcher mark (pink, a supporter icon): four rounded equalizer bars (adaptive-icon safe zone). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="108dp" android:height="108dp"+ android:viewportWidth="108" android:viewportHeight="108">+ <path android:pathData="M38,47 L38,61" android:strokeColor="#F573A0" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M48.7,37 L48.7,71" android:strokeColor="#F573A0" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M59.3,42 L59.3,66" android:strokeColor="#F573A0" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M70,49 L70,59" android:strokeColor="#F573A0" android:strokeWidth="7.5" android:strokeLineCap="round" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_launcher_foreground_purple.xml b/base/app/src/main/res/drawable/ic_launcher_foreground_purple.xmlnew file mode 100644index 00000000..3d5e6699--- /dev/null+++ b/base/app/src/main/res/drawable/ic_launcher_foreground_purple.xml@@ -0,0 +1,10 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Myspoti launcher mark (purple, a supporter icon): four rounded equalizer bars (adaptive-icon safe zone). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="108dp" android:height="108dp"+ android:viewportWidth="108" android:viewportHeight="108">+ <path android:pathData="M38,47 L38,61" android:strokeColor="#AF7AF6" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M48.7,37 L48.7,71" android:strokeColor="#AF7AF6" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M59.3,42 L59.3,66" android:strokeColor="#AF7AF6" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M70,49 L70,59" android:strokeColor="#AF7AF6" android:strokeWidth="7.5" android:strokeLineCap="round" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_launcher_monochrome.xml b/base/app/src/main/res/drawable/ic_launcher_monochrome.xmlnew file mode 100644index 00000000..60fd3f30--- /dev/null+++ b/base/app/src/main/res/drawable/ic_launcher_monochrome.xml@@ -0,0 +1,10 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Myspoti launcher mark: four rounded equalizer bars (adaptive-icon safe zone). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="108dp" android:height="108dp"+ android:viewportWidth="108" android:viewportHeight="108">+ <path android:pathData="M38,47 L38,61" android:strokeColor="#FFFFFFFF" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M48.7,37 L48.7,71" android:strokeColor="#FFFFFFFF" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M59.3,42 L59.3,66" android:strokeColor="#FFFFFFFF" android:strokeWidth="7.5" android:strokeLineCap="round" />+ <path android:pathData="M70,49 L70,59" android:strokeColor="#FFFFFFFF" android:strokeWidth="7.5" android:strokeLineCap="round" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_library_big.xml b/base/app/src/main/res/drawable/ic_library_big.xmlnew file mode 100644index 00000000..71a4c854--- /dev/null+++ b/base/app/src/main/res/drawable/ic_library_big.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons "library_music" (Google, Apache License 2.0). Tinted by the caller. -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="23dp" android:height="23dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M20,2H8c-1.1,0 -2,0.9 -2,2v12c0,1.1 0.9,2 2,2h12c1.1,0 2,-0.9 2,-2V4c0,-1.1 -0.9,-2 -2,-2zM18,7h-3v5.5c0,1.38 -1.12,2.5 -2.5,2.5S10,13.88 10,12.5s1.12,-2.5 2.5,-2.5c0.57,0 1.08,0.19 1.5,0.51V5h4v2zM4,6H2v14c0,1.1 0.9,2 2,2h14v-2H4V6z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_notification.xml b/base/app/src/main/res/drawable/ic_notification.xmlnew file mode 100644index 00000000..227a5207--- /dev/null+++ b/base/app/src/main/res/drawable/ic_notification.xml@@ -0,0 +1,10 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Status bar mark: the launcher's equalizer bars. -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:pathData="M6.5,10 L6.5,14" android:strokeColor="#FFFFFFFF" android:strokeWidth="2.6" android:strokeLineCap="round" />+ <path android:pathData="M10.2,6.5 L10.2,17.5" android:strokeColor="#FFFFFFFF" android:strokeWidth="2.6" android:strokeLineCap="round" />+ <path android:pathData="M13.8,8.2 L13.8,15.8" android:strokeColor="#FFFFFFFF" android:strokeWidth="2.6" android:strokeLineCap="round" />+ <path android:pathData="M17.5,10.6 L17.5,13.4" android:strokeColor="#FFFFFFFF" android:strokeWidth="2.6" android:strokeLineCap="round" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_pause.xml b/base/app/src/main/res/drawable/ic_pause.xmlnew file mode 100644index 00000000..46cccb87--- /dev/null+++ b/base/app/src/main/res/drawable/ic_pause.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons (Google, Apache License 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M6,19h4V5H6v14zM14,5v14h4V5h-4z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_play.xml b/base/app/src/main/res/drawable/ic_play.xmlnew file mode 100644index 00000000..43055436--- /dev/null+++ b/base/app/src/main/res/drawable/ic_play.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons (Google, Apache License 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M8,5v14l11,-7z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_player_back.xml b/base/app/src/main/res/drawable/ic_player_back.xmlnew file mode 100644index 00000000..11eaf6a3--- /dev/null+++ b/base/app/src/main/res/drawable/ic_player_back.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons "skip_previous" (Google, Apache License 2.0). Tinted by the caller. -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M6,6h2v12H6zM9.5,12l8.5,6V6z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_player_shuffle.xml b/base/app/src/main/res/drawable/ic_player_shuffle.xmlnew file mode 100644index 00000000..2f412b99--- /dev/null+++ b/base/app/src/main/res/drawable/ic_player_shuffle.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons "shuffle" (Google, Apache License 2.0). Tinted by the caller. -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M10.59,9.17L5.41,4 4,5.41l5.17,5.17 1.42,-1.41zM14.5,4l2.04,2.04L4,18.59 5.41,20 17.96,7.46 20,9.5L20,4h-5.5zM14.83,13.41l-1.41,1.41 3.13,3.13L14.5,20L20,20v-5.5l-2.04,2.04 -3.13,-3.13z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_player_skip.xml b/base/app/src/main/res/drawable/ic_player_skip.xmlnew file mode 100644index 00000000..532b81b2--- /dev/null+++ b/base/app/src/main/res/drawable/ic_player_skip.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons "skip_next" (Google, Apache License 2.0). Tinted by the caller. -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M6,18l8.5,-6L6,6v12zM16,6v12h2V6h-2z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_playing.xml b/base/app/src/main/res/drawable/ic_playing.xmlnew file mode 100644index 00000000..052dafa8--- /dev/null+++ b/base/app/src/main/res/drawable/ic_playing.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons "pause" (Google, Apache License 2.0). Tinted by the caller. -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="33dp" android:height="33dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M6,19h4V5H6v14zM14,5v14h4V5h-4z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_repeat.xml b/base/app/src/main/res/drawable/ic_repeat.xmlnew file mode 100644index 00000000..a2d13e99--- /dev/null+++ b/base/app/src/main/res/drawable/ic_repeat.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons (Google, Apache License 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M7,7h10v3l4,-4 -4,-4v3H5v6h2V7zM17,17H7v-3l-4,4 4,4v-3h12v-6h-2v4z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_repeat_off.xml b/base/app/src/main/res/drawable/ic_repeat_off.xmlnew file mode 100644index 00000000..97b52d53--- /dev/null+++ b/base/app/src/main/res/drawable/ic_repeat_off.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons (Google, Apache License 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#80FFFFFF" android:pathData="M7,7h10v3l4,-4 -4,-4v3H5v6h2V7zM17,17H7v-3l-4,4 4,4v-3h12v-6h-2v4z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_repeat_one.xml b/base/app/src/main/res/drawable/ic_repeat_one.xmlnew file mode 100644index 00000000..738108d4--- /dev/null+++ b/base/app/src/main/res/drawable/ic_repeat_one.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons (Google, Apache License 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M7,7h10v3l4,-4 -4,-4v3H5v6h2V7zM17,17H7v-3l-4,4 4,4v-3h12v-6h-2v4zM13,15V9h-1l-2,1v1h1.5v4H13z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_repeat_spotui.xml b/base/app/src/main/res/drawable/ic_repeat_spotui.xmlnew file mode 100644index 00000000..fafc95f2--- /dev/null+++ b/base/app/src/main/res/drawable/ic_repeat_spotui.xml@@ -0,0 +1,9 @@+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="512dp"+ android:height="512dp"+ android:viewportWidth="512"+ android:viewportHeight="512">+ <path+ android:pathData="M20,346.91a20,20 0,0 1,-20 -20L0,185.09A102,102 0,0 1,101.89 83.2h268.78l-28.96,-28.96a20,20 0,0 1,28.28 -28.28l63.1,63.1a20,20 0,0 1,0 28.28l-64.97,64.97a20,20 0,1 1,-28.28 -28.28l30.84,-30.83h-268.78A61.96,61.96 0,0 0,40 185.09v141.82a20,20 0,0 1,-20 20zM492,165.09a20,20 0,0 0,-20 20v141.82a61.96,61.96 0,0 1,-61.89 61.89h-268.78l30.83,-30.83a20,20 0,1 0,-28.28 -28.28l-64.97,64.97a20,20 0,0 0,0 28.28l63.1,63.1a20,20 0,0 0,28.28 -28.28L141.33,428.8h268.78A102,102 0,0 0,512 326.91L512,185.09a20,20 0,0 0,-20 -20z"+ android:fillColor="#000000"/>+</vector>diff --git a/base/app/src/main/res/drawable/ic_search_big.xml b/base/app/src/main/res/drawable/ic_search_big.xmlnew file mode 100644index 00000000..fd56a87b--- /dev/null+++ b/base/app/src/main/res/drawable/ic_search_big.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons "search" (Google, Apache License 2.0). Tinted by the caller. -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="23dp" android:height="23dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M15.5,14h-0.79l-0.28,-0.27C15.41,12.59 16,11.11 16,9.5 16,5.91 13.09,3 9.5,3S3,5.91 3,9.5 5.91,16 9.5,16c1.61,0 3.09,-0.59 4.23,-1.57l0.27,0.28v0.79l5,4.99L20.49,19l-4.99,-5zM9.5,14C7.01,14 5,11.99 5,9.5S7.01,5 9.5,5 14,7.01 14,9.5 11.99,14 9.5,14z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_share.xml b/base/app/src/main/res/drawable/ic_share.xmlnew file mode 100644index 00000000..b834b048--- /dev/null+++ b/base/app/src/main/res/drawable/ic_share.xml@@ -0,0 +1,9 @@+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="512dp"+ android:height="512dp"+ android:viewportWidth="227.22"+ android:viewportHeight="227.22">+ <path+ android:pathData="M175.9,141.48c-13.25,0 -25.11,6.04 -32.98,15.52l-51.19,-29.07a42.67,42.67 0,0 0,2.47 -14.32,42.67 42.67,0 0,0 -2.47,-14.32l51.19,-29.07c7.87,9.48 19.73,15.52 32.98,15.52 23.63,0 42.86,-19.24 42.86,-42.88C218.76,19.23 199.53,0 175.9,0 152.26,0 133.03,19.23 133.03,42.87c0,5.02 0.87,9.84 2.47,14.32L84.3,86.26c-7.87,-9.47 -19.73,-15.51 -32.97,-15.51 -23.64,0 -42.87,19.23 -42.87,42.87 0,23.64 19.23,42.87 42.87,42.87 13.25,0 25.1,-6.04 32.97,-15.51l51.19,29.07a42.67,42.67 0,0 0,-2.47 14.32c0,23.64 19.23,42.87 42.87,42.87 23.63,0 42.86,-19.23 42.86,-42.87 0,-23.64 -19.23,-42.87 -42.86,-42.87zM175.9,15c15.36,0 27.86,12.5 27.86,27.86 0,15.37 -12.5,27.88 -27.86,27.88 -15.37,0 -27.87,-12.51 -27.87,-27.88C148.03,27.5 160.53,15 175.9,15zM51.33,141.48c-15.37,0 -27.87,-12.5 -27.87,-27.86 0,-15.37 12.5,-27.87 27.87,-27.87 15.36,0 27.86,12.5 27.86,27.87 0,15.36 -12.5,27.86 -27.86,27.86zM175.9,212.22c-15.37,0 -27.87,-12.5 -27.87,-27.86 0,-15.37 12.5,-27.88 27.87,-27.88 15.36,0 27.86,12.51 27.86,27.88 0,15.36 -12.5,27.86 -27.86,27.86z"+ android:fillColor="#000000"/>+</vector>diff --git a/base/app/src/main/res/drawable/ic_shuffle.xml b/base/app/src/main/res/drawable/ic_shuffle.xmlnew file mode 100644index 00000000..7bca4754--- /dev/null+++ b/base/app/src/main/res/drawable/ic_shuffle.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons (Google, Apache License 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M10.59,9.17L5.41,4 4,5.41l5.17,5.17 1.42,-1.41zM14.5,4l2.04,2.04L4,18.59 5.41,20 17.96,7.46 20,9.5L20,4h-5.5zM14.83,13.41l-1.41,1.41 3.13,3.13L14.5,20L20,20v-5.5l-2.04,2.04 -3.13,-3.13z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_shuffle_active.xml b/base/app/src/main/res/drawable/ic_shuffle_active.xmlnew file mode 100644index 00000000..1bd4f3af--- /dev/null+++ b/base/app/src/main/res/drawable/ic_shuffle_active.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons (Google, Apache License 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FF1ED760" android:pathData="M10.59,9.17L5.41,4 4,5.41l5.17,5.17 1.42,-1.41zM14.5,4l2.04,2.04L4,18.59 5.41,20 17.96,7.46 20,9.5L20,4h-5.5zM14.83,13.41l-1.41,1.41 3.13,3.13L14.5,20L20,20v-5.5l-2.04,2.04 -3.13,-3.13z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_shuffle_smart_active.xml b/base/app/src/main/res/drawable/ic_shuffle_smart_active.xmlnew file mode 100644index 00000000..f59474e5--- /dev/null+++ b/base/app/src/main/res/drawable/ic_shuffle_smart_active.xml@@ -0,0 +1,8 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons (Google, Apache License 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FF1ED760" android:pathData="M10.59,9.17L5.41,4 4,5.41l5.17,5.17 1.42,-1.41zM14.5,4l2.04,2.04L4,18.59 5.41,20 17.96,7.46 20,9.5L20,4h-5.5zM14.83,13.41l-1.41,1.41 3.13,3.13L14.5,20L20,20v-5.5l-2.04,2.04 -3.13,-3.13z" />+ <path android:fillColor="#FF1ED760" android:pathData="M21,1.5l0.6,1.4 1.4,0.6 -1.4,0.6 -0.6,1.4 -0.6,-1.4 -1.4,-0.6 1.4,-0.6z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_skip_next.xml b/base/app/src/main/res/drawable/ic_skip_next.xmlnew file mode 100644index 00000000..c255146f--- /dev/null+++ b/base/app/src/main/res/drawable/ic_skip_next.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons (Google, Apache License 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M6,18l8.5,-6L6,6v12zM16,6v12h2V6h-2z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_skip_prev.xml b/base/app/src/main/res/drawable/ic_skip_prev.xmlnew file mode 100644index 00000000..5cae57a7--- /dev/null+++ b/base/app/src/main/res/drawable/ic_skip_prev.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons (Google, Apache License 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M6,6h2v12H6zM9.5,12l8.5,6V6z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_translate_lyrics.xml b/base/app/src/main/res/drawable/ic_translate_lyrics.xmlnew file mode 100644index 00000000..a16808f0--- /dev/null+++ b/base/app/src/main/res/drawable/ic_translate_lyrics.xml@@ -0,0 +1,10 @@+<?xml version="1.0" encoding="utf-8"?>+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp"+ android:height="24dp"+ android:viewportWidth="24"+ android:viewportHeight="24">+ <path+ android:fillColor="#FFFFFFFF"+ android:pathData="M8.155,1.012Q8.571,1.012 8.863,1.304Q9.155,1.595 9.155,2.012L9.155,3.583L14.167,3.583Q14.583,3.583 14.875,3.875Q15.167,4.167 15.167,4.577Q15.167,4.988 14.875,5.286Q14.583,5.583 14.167,5.583L12.202,5.583Q12.155,7.429 11.482,9.161Q10.81,10.893 9.607,12.298Q10.536,13.036 11.643,13.476Q12.75,13.917 13.94,14.012L15.774,9.81Q15.893,9.536 16.143,9.369Q16.393,9.202 16.69,9.202Q16.988,9.202 17.238,9.369Q17.488,9.536 17.607,9.81L22.762,21.607Q22.929,21.988 22.774,22.375Q22.619,22.762 22.244,22.923Q21.869,23.083 21.482,22.935Q21.095,22.786 20.929,22.417L19.512,19.167L13.869,19.167L12.452,22.417Q12.345,22.667 12.131,22.833Q11.917,23 11.643,23.03Q11.369,23.06 11.125,22.952Q10.881,22.845 10.72,22.625Q10.56,22.405 10.53,22.131Q10.5,21.857 10.619,21.607L13.095,15.929Q11.738,15.714 10.476,15.149Q9.214,14.583 8.155,13.69Q6.893,14.702 5.393,15.298Q3.893,15.893 2.286,16.012Q1.869,16.048 1.554,15.78Q1.238,15.512 1.208,15.095Q1.179,14.679 1.446,14.363Q1.714,14.048 2.131,14.024Q3.381,13.929 4.56,13.476Q5.738,13.024 6.738,12.262Q5.333,10.524 4.786,8.357Q4.726,8.095 4.798,7.833Q4.869,7.571 5.06,7.387Q5.25,7.202 5.512,7.137Q5.774,7.071 6.036,7.143Q6.298,7.214 6.482,7.411Q6.667,7.607 6.726,7.869Q7.143,9.524 8.19,10.869Q9.119,9.75 9.637,8.393Q10.155,7.036 10.19,5.583L2.155,5.583Q1.738,5.583 1.446,5.286Q1.155,4.988 1.155,4.577Q1.155,4.167 1.446,3.875Q1.738,3.583 2.155,3.583L7.155,3.583L7.155,2.012Q7.155,1.595 7.452,1.304Q7.75,1.012 8.155,1.012ZM14.75,17.167L18.643,17.167L16.69,12.702Z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_view_grid.xml b/base/app/src/main/res/drawable/ic_view_grid.xmlnew file mode 100644index 00000000..5a30f7b4--- /dev/null+++ b/base/app/src/main/res/drawable/ic_view_grid.xml@@ -0,0 +1,9 @@+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp"+ android:height="24dp"+ android:viewportWidth="24"+ android:viewportHeight="24">+ <path+ android:fillColor="#FFFFFFFF"+ android:pathData="M4,4h7v7H4zM13,4h7v7h-7zM4,13h7v7H4zM13,13h7v7h-7z" />+</vector>diff --git a/base/app/src/main/res/drawable/ic_view_list.xml b/base/app/src/main/res/drawable/ic_view_list.xmlnew file mode 100644index 00000000..d4aca49d--- /dev/null+++ b/base/app/src/main/res/drawable/ic_view_list.xml@@ -0,0 +1,9 @@+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp"+ android:height="24dp"+ android:viewportWidth="24"+ android:viewportHeight="24">+ <path+ android:fillColor="#FFFFFFFF"+ android:pathData="M4,5h2v2H4zM8,5h12v2H8zM4,11h2v2H4zM8,11h12v2H8zM4,17h2v2H4zM8,17h12v2H8z" />+</vector>diff --git a/base/app/src/main/res/drawable/local_files_cover.xml b/base/app/src/main/res/drawable/local_files_cover.xmlnew file mode 100644index 00000000..4b620da1--- /dev/null+++ b/base/app/src/main/res/drawable/local_files_cover.xml@@ -0,0 +1,11 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- "Local Files" cover: a white folder with a note on green (Material "folder" / "music_note", Apache 2.0). -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="64dp" android:height="64dp"+ android:viewportWidth="64" android:viewportHeight="64">+ <path android:fillColor="#FF2E7D4F" android:pathData="M0,0h64v64h-64z" />+ <group android:translateX="14" android:translateY="14" android:scaleX="1.5" android:scaleY="1.5">+ <path android:fillColor="#FFFFFFFF" android:pathData="M10,4H4c-1.1,0 -1.99,0.9 -1.99,2L2,18c0,1.1 0.9,2 2,2h16c1.1,0 2,-0.9 2,-2V8c0,-1.1 -0.9,-2 -2,-2h-8l-2,-2z" />+ <path android:fillColor="#FF2E7D4F" android:pathData="M14,9.5v4.6c-0.3,-0.1 -0.6,-0.1 -1,-0.1 -1.1,0 -2,0.7 -2,1.5s0.9,1.5 2,1.5 2,-0.7 2,-1.5V11h2V9.5h-3z" />+ </group>+</vector>diff --git a/base/app/src/main/res/drawable/placeholder.xml b/base/app/src/main/res/drawable/placeholder.xmlnew file mode 100644index 00000000..46f58529--- /dev/null+++ b/base/app/src/main/res/drawable/placeholder.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Artwork placeholder (loading / missing image): a plain dark tile, as in the official app. -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="64dp" android:height="64dp"+ android:viewportWidth="64" android:viewportHeight="64">+ <path android:fillColor="#282828" android:pathData="M0,0h64v64h-64z" />+</vector>diff --git a/base/app/src/main/res/drawable/play_svgrepo_com.xml b/base/app/src/main/res/drawable/play_svgrepo_com.xmlnew file mode 100644index 00000000..ba138913--- /dev/null+++ b/base/app/src/main/res/drawable/play_svgrepo_com.xml@@ -0,0 +1,7 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Material Icons "play_arrow" (Google, Apache License 2.0). Tinted by the caller. -->+<vector xmlns:android="http://schemas.android.com/apk/res/android"+ android:width="24dp" android:height="24dp"+ android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M8,5v14l11,-7z" />+</vector>diff --git a/base/app/src/main/res/drawable/splash_icon.xml b/base/app/src/main/res/drawable/splash_icon.xmlnew file mode 100644index 00000000..ef732db7--- /dev/null+++ b/base/app/src/main/res/drawable/splash_icon.xml@@ -0,0 +1,5 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Launch screen mark: the launcher bars, smaller and centred. -->+<inset xmlns:android="http://schemas.android.com/apk/res/android"+ android:drawable="@drawable/ic_launcher_foreground"+ android:inset="22%" />diff --git a/base/app/src/main/res/drawable/widget_background.xml b/base/app/src/main/res/drawable/widget_background.xmlnew file mode 100644index 00000000..04723b86--- /dev/null+++ b/base/app/src/main/res/drawable/widget_background.xml@@ -0,0 +1,5 @@+<?xml version="1.0" encoding="utf-8"?>+<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle">+ <solid android:color="#E6181818" />+ <corners android:radius="16dp" />+</shape>diff --git a/base/app/src/main/res/font/app_sans.ttf b/base/app/src/main/res/font/app_sans.ttfnew file mode 100644index 00000000..579e2ab5Binary files /dev/null and b/base/app/src/main/res/font/app_sans.ttf differdiff --git a/base/app/src/main/res/layout/widget_now_playing.xml b/base/app/src/main/res/layout/widget_now_playing.xmlnew file mode 100644index 00000000..a089facf--- /dev/null+++ b/base/app/src/main/res/layout/widget_now_playing.xml@@ -0,0 +1,71 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Home screen widget (4x1): cover, title and artist, previous / play-pause / next. -->+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"+ android:id="@+id/widget_root"+ android:layout_width="match_parent"+ android:layout_height="match_parent"+ android:background="@drawable/widget_background"+ android:gravity="center_vertical"+ android:orientation="horizontal"+ android:padding="8dp">++ <ImageView+ android:id="@+id/widget_cover"+ android:layout_width="48dp"+ android:layout_height="48dp"+ android:contentDescription="@null"+ android:scaleType="centerCrop"+ android:src="@mipmap/ic_launcher" />++ <LinearLayout+ android:layout_width="0dp"+ android:layout_height="wrap_content"+ android:layout_marginStart="10dp"+ android:layout_weight="1"+ android:orientation="vertical">++ <TextView+ android:id="@+id/widget_title"+ android:layout_width="match_parent"+ android:layout_height="wrap_content"+ android:ellipsize="end"+ android:maxLines="1"+ android:text="@string/app_name"+ android:textColor="#FFFFFF"+ android:textSize="14sp"+ android:textStyle="bold" />++ <TextView+ android:id="@+id/widget_artist"+ android:layout_width="match_parent"+ android:layout_height="wrap_content"+ android:ellipsize="end"+ android:maxLines="1"+ android:textColor="#B3B3B3"+ android:textSize="12sp" />+ </LinearLayout>++ <ImageButton+ android:id="@+id/widget_previous"+ android:layout_width="40dp"+ android:layout_height="40dp"+ android:background="@android:color/transparent"+ android:contentDescription="@string/widget_previous"+ android:src="@drawable/msp_ic_previous" />++ <ImageButton+ android:id="@+id/widget_play"+ android:layout_width="44dp"+ android:layout_height="44dp"+ android:background="@android:color/transparent"+ android:contentDescription="@string/widget_play_pause"+ android:src="@drawable/msp_ic_play" />++ <ImageButton+ android:id="@+id/widget_next"+ android:layout_width="40dp"+ android:layout_height="40dp"+ android:background="@android:color/transparent"+ android:contentDescription="@string/widget_next"+ android:src="@drawable/msp_ic_next" />+</LinearLayout>diff --git a/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml b/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xmlnew file mode 100644index 00000000..04091bd1--- /dev/null+++ b/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml@@ -0,0 +1,6 @@+<?xml version="1.0" encoding="utf-8"?>+<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">+ <background android:drawable="@drawable/ic_launcher_background"/>+ <foreground android:drawable="@drawable/ic_launcher_foreground"/>+ <monochrome android:drawable="@drawable/ic_launcher_monochrome"/>+</adaptive-icon>\ No newline at end of filediff --git a/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_blue.xml b/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_blue.xmlnew file mode 100644index 00000000..3ad7202c--- /dev/null+++ b/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_blue.xml@@ -0,0 +1,6 @@+<?xml version="1.0" encoding="utf-8"?>+<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">+ <background android:drawable="@drawable/ic_launcher_background"/>+ <foreground android:drawable="@drawable/ic_launcher_foreground_blue"/>+ <monochrome android:drawable="@drawable/ic_launcher_monochrome"/>+</adaptive-icon>diff --git a/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_orange.xml b/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_orange.xmlnew file mode 100644index 00000000..10a231e6--- /dev/null+++ b/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_orange.xml@@ -0,0 +1,6 @@+<?xml version="1.0" encoding="utf-8"?>+<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">+ <background android:drawable="@drawable/ic_launcher_background"/>+ <foreground android:drawable="@drawable/ic_launcher_foreground_orange"/>+ <monochrome android:drawable="@drawable/ic_launcher_monochrome"/>+</adaptive-icon>diff --git a/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_pink.xml b/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_pink.xmlnew file mode 100644index 00000000..e62ed734--- /dev/null+++ b/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_pink.xml@@ -0,0 +1,6 @@+<?xml version="1.0" encoding="utf-8"?>+<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">+ <background android:drawable="@drawable/ic_launcher_background"/>+ <foreground android:drawable="@drawable/ic_launcher_foreground_pink"/>+ <monochrome android:drawable="@drawable/ic_launcher_monochrome"/>+</adaptive-icon>diff --git a/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_purple.xml b/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_purple.xmlnew file mode 100644index 00000000..1a3fd850--- /dev/null+++ b/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_purple.xml@@ -0,0 +1,6 @@+<?xml version="1.0" encoding="utf-8"?>+<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">+ <background android:drawable="@drawable/ic_launcher_background"/>+ <foreground android:drawable="@drawable/ic_launcher_foreground_purple"/>+ <monochrome android:drawable="@drawable/ic_launcher_monochrome"/>+</adaptive-icon>diff --git a/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml b/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xmlnew file mode 100644index 00000000..04091bd1--- /dev/null+++ b/base/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml@@ -0,0 +1,6 @@+<?xml version="1.0" encoding="utf-8"?>+<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">+ <background android:drawable="@drawable/ic_launcher_background"/>+ <foreground android:drawable="@drawable/ic_launcher_foreground"/>+ <monochrome android:drawable="@drawable/ic_launcher_monochrome"/>+</adaptive-icon>\ No newline at end of filediff --git a/base/app/src/main/res/values-af/spotify_plurals.xml b/base/app/src/main/res/values-af/spotify_plurals.xmlnew file mode 100644index 00000000..9f16df79--- /dev/null+++ b/base/app/src/main/res/values-af/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d liedjie</item>+ <item quantity="other">%1$d liedjies</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d keer gestoor</item>+ <item quantity="other">%1$,d keer gestoor</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s speellys</item>+ <item quantity="other">%1$s speellyste</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s liedjie</item>+ <item quantity="other">%1$s liedjies</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-af/spotify_strings.xml b/base/app/src/main/res/values-af/spotify_strings.xmlnew file mode 100644index 00000000..95691c63--- /dev/null+++ b/base/app/src/main/res/values-af/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Voeg by liedjies waarvan jy hou</string>+ <string name="collection_liked_songs_title" formatted="false">Liedjie-laaiks</string>+ <string name="context_menu_add_to_playlist" formatted="false">Voeg by speellys</string>+ <string name="context_menu_play_next" formatted="false">Speel volgende</string>+ <string name="context_menu_add_to_queue" formatted="false">Voeg by waglys</string>+ <string name="context_menu_go_to_queue" formatted="false">Gaan na waglys</string>+ <string name="context_menu_browse_album" formatted="false">Gaan na album</string>+ <string name="context_menu_browse_artist" formatted="false">Gaan na kunstenaar</string>+ <string name="context_menu_share" formatted="false">Deel</string>+ <string name="context_menu_sleep_timer" formatted="false">Slaaptydhouer</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Skakel tydhouer af</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Einde van liedjie</string>+ <string name="snackbar_added_to_queue" formatted="false">By waglys gevoeg</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Bygevoeg by Liedjie-laaiks.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Uit Liedjie-laaiks verwyder.</string>+ <string name="content_description_context_menu" formatted="false">Meer opsies</string>+ <string name="close_button_content_description" formatted="false">Maak toe</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Gestoor in</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nuwe speellys</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Kanselleer</string>+ <string name="create_playlist_create_button" formatted="false">Skep</string>+ <string name="lyrics_card_title" formatted="false">Lirieke</string>+ <string name="lyrics_card_title_preview" formatted="false">Liriekevoorskou</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Wys lirieke</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Maak volskerm-lirieke oop</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Deel lirieke</string>+ <string name="lyrics_credential_note" formatted="false">Lirieke voorsien deur %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Deel</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Vertaal</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Maak lirieke toe</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Vertaal lirieke</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Hou op om lirieke te vertaal</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmmm. Ons ken nie die lirieke vir hierdie een nie.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Hierdie lirieke is nog nie met die tyd gesinkroniseer nie.</string>+ <string name="av_switch_to_video" formatted="false">Skakel oor na video</string>+ <string name="av_switch_to_audio" formatted="false">Skakel oor na klank</string>+ <string name="av_content_desc" formatted="false">Wissel tussen klank en video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Tuis</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Soek</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Jou biblioteek</string>+ <string name="search_header_field_hint" formatted="false">Waarna wil jy luister?</string>+ <string name="filter_chip_all_label" formatted="false">Alles</string>+ <string name="recents_content_filter_music" formatted="false">Musiek</string>+ <string name="ad_category_title_podcasts" formatted="false">Podsendings</string>+ <string name="audiobooks_title" formatted="false">Luisterboeke</string>+ <string name="artist_popular_tracks" formatted="false">Gewild</string>+ <string name="curation_button_follow_state_text" formatted="false">Volg</string>+ <string name="curation_button_following_state_text" formatted="false">Volg tans</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Kunstenaar</string>+ <string name="connect_phone_is_self" formatted="false">Hierdie foon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Kort, herhalende patrone wanneer ’n liedjie speel.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Nie nou nie</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Opdatering</string>+ <string name="context_type_description_play_queue" formatted="false">Speel vanaf speelry</string>+ <string name="context_type_description_collection_your_library" formatted="false">Speel vanaf Jou biblioteek</string>+ <string name="context_type_description_playlist" formatted="false">Speel vanaf speellys</string>+ <string name="context_type_description_album" formatted="false">Speel vanaf album</string>+ <string name="context_type_description_artist" formatted="false">Speel vanaf kunstenaar</string>+ <string name="context_type_description_show" formatted="false">Speel vanaf podsending</string>+ <string name="context_type_description_search" formatted="false">Speel vanaf soek</string>+ <string name="default_notification_channel_name" formatted="false">Speel tans</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Toestelle</string>+ <string name="action_share_label" formatted="false">Deel</string>+ <string name="action_queue_label" formatted="false">Waglys</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 uur</string>+ <string name="curation_actions_edit_button_title" formatted="false">Redigeer</string>+ <string name="content_description_pause_button" formatted="false">Laat wag</string>+ <string name="content_description_play_button" formatted="false">Speel</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Wissel</string>+ <string name="np_content_desc_repeat" formatted="false">Herhaal</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Slaaptydhouer</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Verwyder</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Skuif</string>+ <string name="bottom_actions_close" formatted="false">Maak toe</string>+ <string name="add_to_queue_action_content_description" formatted="false">Voeg by waglys</string>+ <string name="curation_button_saved_text" formatted="false">Gestoor</string>+ <string name="np_content_desc_prev" formatted="false">Vorige</string>+ <string name="np_content_desc_next" formatted="false">Volgende</string>+ <string name="accessibility_navigate_back" formatted="false">Terug</string>+ <string name="monthly_listeners_text" formatted="false">%1$s maandelikse luisteraars</string>+ <string name="profile_bio_show_less" formatted="false">Wys minder</string>+ <string name="audiobook_series_see_more_button" formatted="false">Wys meer</string>+ <string name="popular_releases_section_title" formatted="false">Gewilde vrystellings</string>+ <string name="creator_biography_section_title" formatted="false">Meer oor</string>+ <string name="fans_also_like_section_title" formatted="false">Aanhangers hou ook van</string>+ <string name="appears_on_section_title" formatted="false">Verskyn op</string>+ <string name="composer_section_button_show_all" formatted="false">Wys alles</string>+ <string name="releases_title" formatted="false">Vrystellings</string>+ <string name="artist_releases_albums" formatted="false">Albums</string>+ <string name="artist_releases_singles" formatted="false">Enkelsnitte en EP’s</string>+ <string name="latest_release_title" formatted="false">Nuutste vrystelling</string>+ <string name="artist_subtitle" formatted="false">Kunstenaar</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Onlangse soektogte</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Vee uit</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podsendings</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episodes</string>+ <string name="assisted_curation_search_song" formatted="false">Liedjie</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podsending</string>+ <string name="recently_played_user_profile" formatted="false">Profiel</string>+ <string name="connect_device_menu_logout" formatted="false">Meld af</string>+ <string name="library_search_text_hint" formatted="false">Soek in jou biblioteek</string>+ <string name="account_title" formatted="false">Rekening</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Gevolgde kunstenaars</string>+ <string name="settings_item_crossfade_title" formatted="false">Kruisverdowing</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Plaaslike lêers</string>+ <string name="local_files_empty_section_title" formatted="false">Voeg jou eie klanklêers by Jou biblioteek</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Het jy \'n liedjie of persoonlike podsending wat nie op Spotify is nie?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Jou klanklêers sal hier verskyn</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Gee toegang</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Gaan na Instellings</string>+ <string name="context_menu_download" formatted="false">Laai af</string>+ <string name="context_menu_undownload" formatted="false">Verwyder aflaai</string>+ <string name="collection_downloaded" formatted="false">Afgelaai</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Afgelaai</string>+ <string name="download_badge_downloading_content_description" formatted="false">Laai tans af</string>+ <string name="download_badge_error_content_description" formatted="false">Aflaai het misluk</string>+ <string name="download_notification_downloading" formatted="false">Laai tans af …</string>+ <string name="toast_undownload" formatted="false">Aflaai is verwyder.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Verwyder uit aflaaie?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Jy sal dit nie vanlyn kan speel nie.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Verwyder</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Verwyder alle aflaaie</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Verwyder alle aflaaie?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Enkelsnit</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Samestelling</string>+ <string name="assisted_curation_search_playlist" formatted="false">Speellys</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Top</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Liedjies</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Kunstenaars</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albums</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Speellyste</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Vee filter uit</string>+ <string name="ad_category_title_music" formatted="false">Musiek</string>+ <string name="made_for_you_hub_title" formatted="false">Vir jou geskep</string>+ <string name="settings_item_app_language_title" formatted="false">Toep-taal</string>+ <string name="create_menu_item_folder_title" formatted="false">Vouer</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nuwe vouer</string>+ <string name="context_menu_rename_folder" formatted="false">Hernoem vouer</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Vouer naam</string>+ <string name="create_playlist_content_description" formatted="false">Maak speel lys</string>+ <string name="actions_picker_delete" formatted="false">Vee uit</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sorteer volgens</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alfabeties</string>+ <string name="your_library_sort_order_creator" formatted="false">Maker</string>+ <string name="your_library_sort_order_custom" formatted="false">Pasgemaakte volgorde</string>+ <string name="settings_item_version_title" formatted="false">Weergawe</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Gaan na liedjieradio</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Vind in liedjie-laaiks</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Vind in speellyste</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Kon nie “%1$s” kry nie</string>+</resources>diff --git a/base/app/src/main/res/values-am/spotify_plurals.xml b/base/app/src/main/res/values-am/spotify_plurals.xmlnew file mode 100644index 00000000..797fa625--- /dev/null+++ b/base/app/src/main/res/values-am/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d ሙዚቃ</item>+ <item quantity="other">%1$d ሙዚቃዎች</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d የተቀመጠ</item>+ <item quantity="other">%1$,d የተቀመጡ</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s አጫዋች ዝርዝር</item>+ <item quantity="other">%1$s አጫዋች ዝርዝሮች</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s ሙዚቃ</item>+ <item quantity="other">%1$s ሙዚቃዎች</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-am/spotify_strings.xml b/base/app/src/main/res/values-am/spotify_strings.xmlnew file mode 100644index 00000000..983b1956--- /dev/null+++ b/base/app/src/main/res/values-am/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">ወደ የተወደዱ ሙዚቃዎች አክል</string>+ <string name="collection_liked_songs_title" formatted="false">የተወደዱ ሙዚቃዎች</string>+ <string name="context_menu_add_to_playlist" formatted="false">ወደ አጫዋች ዝርዝር አክል</string>+ <string name="context_menu_play_next" formatted="false">ቀጣይ አጫውት</string>+ <string name="context_menu_add_to_queue" formatted="false">ወደ ወረፋ ያክሉ</string>+ <string name="context_menu_go_to_queue" formatted="false">ወደ ወረፋ ይሂዱ</string>+ <string name="context_menu_browse_album" formatted="false">ወደ አልበም ይሂዱ</string>+ <string name="context_menu_browse_artist" formatted="false">ወደ አርቲስት ይሂዱ</string>+ <string name="context_menu_share" formatted="false">አጋራ</string>+ <string name="context_menu_sleep_timer" formatted="false">የመተኛ ሰዓት መቁጠሪያ</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">ሰዓት ቆጣሪን ያጥፉ</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">የዘፈን መጨረሻ</string>+ <string name="snackbar_added_to_queue" formatted="false">ወደ ተራ ታክሏል</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">ወደ ተወደዱ ሙዚቃዎች ታክሏል።</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">ከተወደዱ ሙዚቃዎች ተወግደዋል።</string>+ <string name="content_description_context_menu" formatted="false">ተጨማሪ አማራጮች</string>+ <string name="close_button_content_description" formatted="false">ዝጋ</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">በሚከተለው ውስጥ ተቀምጧል</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">አዲስ አጫዋች ዝርዝር</string>+ <string name="add_to_playlist_button_cancel" formatted="false">ሰርዝ</string>+ <string name="create_playlist_create_button" formatted="false">ፍጠር</string>+ <string name="lyrics_card_title" formatted="false">የሙዚቃ ግጥሞች</string>+ <string name="lyrics_card_title_preview" formatted="false">የሙዚቃ ግጥም ቅድመ ዕይታ</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">የሙዚቃ ግጥም አሳይ</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">የሙሉ ማያ ገጽ የሙዚቃ ግጥምን ይክፈቱ</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">የሙዚቃ ግጥም ያጋሩ</string>+ <string name="lyrics_credential_note" formatted="false">የሙዚቃ ግጥም የቀረበው በ%1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">አጋራ</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">ተርጉም</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">የሙዚቃ ግጥም ዝጋ</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">የሙዚቃ ግጥም ተርጉም</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">የሙዚቃ ግጥሞችን መተርጎም አቁም</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">ህምም። የዚህን ሙዚቃ ግጥም አናውቀውም።</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">እነዚህ ግጥሞች ገና በጊዜ-የተመሳሰሉ አይደሉም።</string>+ <string name="av_switch_to_video" formatted="false">ወደ ቪድዮ ቀይር</string>+ <string name="av_switch_to_audio" formatted="false">ወደ ኦዲዮ ቀይር</string>+ <string name="av_content_desc" formatted="false">በድምፅ እና በቪድዮ መካከል ቀያይር</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">መነሻ ገጽ</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">ፈልግ</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">የእርስዎ ቤተ-ሙዚቃ</string>+ <string name="search_header_field_hint" formatted="false">ማዳመጥ የሚፈልጉት ምንድን ነው?</string>+ <string name="filter_chip_all_label" formatted="false">ሁሉም</string>+ <string name="recents_content_filter_music" formatted="false">ሙዚቃ</string>+ <string name="ad_category_title_podcasts" formatted="false">ፖድካስቶች</string>+ <string name="audiobooks_title" formatted="false">ኦዲዮ መጽሐፍት</string>+ <string name="artist_popular_tracks" formatted="false">ታዋቂ</string>+ <string name="curation_button_follow_state_text" formatted="false">ተከተል</string>+ <string name="curation_button_following_state_text" formatted="false">በመከተል ላይ</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">አርቲስት</string>+ <string name="connect_phone_is_self" formatted="false">ይህ ስልክ</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">አንድ ሙዚቃ ሲጫወት አጭር፣ የሚዘለሉ ምስሎች።</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">አሁን አይሆንም</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">አዘምን</string>+ <string name="context_type_description_play_queue" formatted="false">ከ ጨዋታ ወረፋ በመጫወት ላይ</string>+ <string name="context_type_description_collection_your_library" formatted="false">ከእርስዎ ማከማቻ በመጫወት ላይ</string>+ <string name="context_type_description_playlist" formatted="false">ከአጫዋች ዝርዝር በመጫወት ላይ</string>+ <string name="context_type_description_album" formatted="false">ከአልበም በመጫወት ላይ</string>+ <string name="context_type_description_artist" formatted="false">ከአርቲስት በመጫወት ላይ</string>+ <string name="context_type_description_show" formatted="false">ከፖድካስት በመጫወት ላይ</string>+ <string name="context_type_description_search" formatted="false">ከፍለጋ በመጫወት ላይ</string>+ <string name="default_notification_channel_name" formatted="false">አሁን እየተጫወተ ያለ</string>+ <string name="label_bluetooth" formatted="false">ብሉቱዝ</string>+ <string name="mr_user_route_category_name" formatted="false">መሣሪያዎች</string>+ <string name="action_share_label" formatted="false">አጋራ</string>+ <string name="action_queue_label" formatted="false">ተራ</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 ሰዓት</string>+ <string name="curation_actions_edit_button_title" formatted="false">አርትዕ</string>+ <string name="content_description_pause_button" formatted="false">ለአፍታ አቁም</string>+ <string name="content_description_play_button" formatted="false">አጫውት</string>+ <string name="play_mode_item_shuffle_title" formatted="false">በውዝ</string>+ <string name="np_content_desc_repeat" formatted="false">ድገም</string>+ <string name="np_content_desc_sleep_timer" formatted="false">የመተኛ ሰዓት መቁጠሪያ</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">አስወግድ</string>+ <string name="edit_playlist_items_move_chip" formatted="false">አንቀሳቅስ</string>+ <string name="bottom_actions_close" formatted="false">ዝጋ</string>+ <string name="add_to_queue_action_content_description" formatted="false">ወደ ወረፋ ያክሉ</string>+ <string name="curation_button_saved_text" formatted="false">ተቀምጧል</string>+ <string name="np_content_desc_prev" formatted="false">የበፊት</string>+ <string name="np_content_desc_next" formatted="false">ቀጣይ</string>+ <string name="accessibility_navigate_back" formatted="false">ተመለስ</string>+ <string name="monthly_listeners_text" formatted="false">%1$s ወርሃዊ አድማጮች</string>+ <string name="profile_bio_show_less" formatted="false">ያነሰ አሳይ</string>+ <string name="audiobook_series_see_more_button" formatted="false">ተጨማሪ አሳይ</string>+ <string name="popular_releases_section_title" formatted="false">ታዋቂ ልቀቶች</string>+ <string name="creator_biography_section_title" formatted="false">ስለ</string>+ <string name="fans_also_like_section_title" formatted="false">አድናቂዎች እንዲሁ የሚወዱት</string>+ <string name="appears_on_section_title" formatted="false">የሚታየው በሚከተሉት ላይ ነው</string>+ <string name="composer_section_button_show_all" formatted="false">ሁሉንም አሳይ</string>+ <string name="releases_title" formatted="false">የተለቀቁ</string>+ <string name="artist_releases_albums" formatted="false">አልበሞች</string>+ <string name="artist_releases_singles" formatted="false">ነጠላዎች እና EP ዎች</string>+ <string name="latest_release_title" formatted="false">በቅርብ ጊዜ የተለቀቀ</string>+ <string name="artist_subtitle" formatted="false">አርቲስት</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">የቅርብ ጊዜ ፍለጋዎች</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">አጽዳ</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">ፖድካስቶች</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">ክፍሎች</string>+ <string name="assisted_curation_search_song" formatted="false">ሙዚቃ</string>+ <string name="album" formatted="false">አልበም</string>+ <string name="album_type_podcast" formatted="false">ፖድካስት</string>+ <string name="recently_played_user_profile" formatted="false">መገለጫ</string>+ <string name="connect_device_menu_logout" formatted="false">ውጣ</string>+ <string name="library_search_text_hint" formatted="false">የእርስዎ ቤተ-ሙዚቃ ፈልግ</string>+ <string name="account_title" formatted="false">መለያ</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">የተከተሏቸው አርቲስቶች</string>+ <string name="settings_item_crossfade_title" formatted="false">ሲሻገር አደብዝዝ</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d ሰ</string>+ <string name="local_files_title" formatted="false">አካባቢያዊ ፋይሎች</string>+ <string name="local_files_empty_section_title" formatted="false">የራስዎን የኦዲዮ ፋይሎች ወደ የእርስዎ ቤተ-ሙዚቃ ያክሉ</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Spotify ላይ የሌለ ሙዚቃ ወይም የግል ፖድካስት አግኝተዋል?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">የእርስዎ የኦዲዮ ፋይሎች እዚህ ይታያሉ</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">ማግኛ ፈቃድ ይስጡ</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">ወደ ቅንብሮች ይሂዱ</string>+ <string name="context_menu_download" formatted="false">አውርድ</string>+ <string name="context_menu_undownload" formatted="false">የወረደውን አስወግድ</string>+ <string name="collection_downloaded" formatted="false">ወርዷል</string>+ <string name="download_badge_downloaded_content_description" formatted="false">ወርዷል</string>+ <string name="download_badge_downloading_content_description" formatted="false">በማውረድ ላይ</string>+ <string name="download_badge_error_content_description" formatted="false">ማውረድ አልተሳካም</string>+ <string name="download_notification_downloading" formatted="false">በማውረድ ላይ…</string>+ <string name="toast_undownload" formatted="false">አውርድ ተወግዷል።</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">ከውርዶች ይወገድ?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">ይህንን ከመስመር ውጪ ማጫወት አይችሉም።</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">አስወግድ</string>+ <string name="settings_item_remove_downloads_title" formatted="false">ሁሉንም ውርዶች አስወግድ</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">ሁሉም የወረዱት ይወገዱ?</string>+ <string name="album_type_album" formatted="false">አልበም</string>+ <string name="album_type_single" formatted="false">ነጠላ</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">ጥንቅሮች</string>+ <string name="assisted_curation_search_playlist" formatted="false">አጫዋች ዝርዝር</string>+ <string name="assisted_curation_search_filter_top" formatted="false">ከላይ</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">ሙዚቃዎች</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">አርቲስቶች</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">አልበሞች</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">አጫዋች ዝርዝሮች</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">ማጣሪያን አጽዳ</string>+ <string name="ad_category_title_music" formatted="false">ሙዚቃ</string>+ <string name="made_for_you_hub_title" formatted="false">ለእርስዎ የተሰራ</string>+ <string name="settings_item_app_language_title" formatted="false">የመተግበሪያ ቋንቋ</string>+ <string name="create_menu_item_folder_title" formatted="false">አቃፊ</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">አዲስ አቃፊ</string>+ <string name="context_menu_rename_folder" formatted="false">አቃፊን እንደገና ይሰይሙ</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">የአቃፊ ስም</string>+ <string name="create_playlist_content_description" formatted="false">አጫዋች ዝርዝር ይፍጠሩ</string>+ <string name="actions_picker_delete" formatted="false">አጥፋ</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">ደርድር በ</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">በፊደል ቅደም ተከተል</string>+ <string name="your_library_sort_order_creator" formatted="false">ፈጣሪ</string>+ <string name="your_library_sort_order_custom" formatted="false">ብጁ ትዕዛዝ</string>+ <string name="settings_item_version_title" formatted="false">ስሪት</string>+ <string name="context_menu_go_to_song_radio" formatted="false">ወደ ሙዚቃ ሬዲዮ ይሂዱ</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">በሚወደዱ ሙዚቃዎች ውስጥ ይፈልጉ</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">በአጫዋች ዝርዝሮች ውስጥ ያግኙ</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\" ን ማግኘት አልተቻለም</string>+</resources>diff --git a/base/app/src/main/res/values-ar-rEG/spotify_plurals.xml b/base/app/src/main/res/values-ar-rEG/spotify_plurals.xmlnew file mode 100644index 00000000..1ff7a0aa--- /dev/null+++ b/base/app/src/main/res/values-ar-rEG/spotify_plurals.xml@@ -0,0 +1,36 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="zero">مفيش أغاني (%1$d)</item>+ <item quantity="one">أغنية واحدة (%1$d)</item>+ <item quantity="two">أغنيتين (%1$d)</item>+ <item quantity="few">%1$d أغاني</item>+ <item quantity="many">%1$d أغنية</item>+ <item quantity="other">%1$d أغنية</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="zero">متحفظتش ولا مرة (%1$,d)</item>+ <item quantity="one">اتحفظت مرة واحدة (%1$,d)</item>+ <item quantity="two">اتحفظت مرتين (%1$,d)</item>+ <item quantity="few">اتحفظت %1$,d مرات</item>+ <item quantity="many">اتحفظت %1$,d مرة</item>+ <item quantity="other">اتحفظت %1$,d مرة</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="zero">ولا قايمة أغاني (%1$s)</item>+ <item quantity="one">قايمة أغاني واحدة (%1$s)</item>+ <item quantity="two">قايمتين أغاني (%1$s)</item>+ <item quantity="few">%1$s قوايم أغاني</item>+ <item quantity="many">%1$s قايمة أغاني</item>+ <item quantity="other">%1$s قايمة أغاني</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="zero">ولا أغنية (%1$s)</item>+ <item quantity="one">أغنية واحدة (%1$s)</item>+ <item quantity="two">أغنيتين (%1$s)</item>+ <item quantity="few">%1$s أغاني</item>+ <item quantity="many">%1$s أغنية</item>+ <item quantity="other">%1$s أغنية</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ar-rEG/spotify_strings.xml b/base/app/src/main/res/values-ar-rEG/spotify_strings.xmlnew file mode 100644index 00000000..db70b630--- /dev/null+++ b/base/app/src/main/res/values-ar-rEG/spotify_strings.xml@@ -0,0 +1,159 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">إضافة لقايمة \"أغاني عجبتني\"</string>+ <string name="collection_liked_songs_title" formatted="false">أغاني عجبتني</string>+ <string name="context_menu_add_to_playlist" formatted="false">إضافة لقايمة الأغاني</string>+ <string name="context_menu_play_next" formatted="false">سماع بعد كدة</string>+ <string name="context_menu_add_to_queue" formatted="false">إضافة لقايمة السماع</string>+ <string name="context_menu_go_to_queue" formatted="false">روح لقايمة السماع</string>+ <string name="context_menu_browse_album" formatted="false">انتقال للألبوم</string>+ <string name="context_menu_browse_artist" formatted="false">انتقال للفنان</string>+ <string name="context_menu_share" formatted="false">مشاركة</string>+ <string name="context_menu_sleep_timer" formatted="false">موقت النوم</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">وقَّف موقت النوم</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">نهاية المقطع</string>+ <string name="snackbar_added_to_queue" formatted="false">اتضاف لقايمة السماع</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">اتضافت للأغاني اللي عجبتني.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">الأغنية اتشالت من الأغاني اللي عجبتني.</string>+ <string name="content_description_context_menu" formatted="false">خيارات أكتر</string>+ <string name="close_button_content_description" formatted="false">قفل</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">مجلد الحفظ</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">قايمة أغاني جديدة</string>+ <string name="add_to_playlist_button_cancel" formatted="false">إلغاء</string>+ <string name="create_playlist_create_button" formatted="false">إنشاء</string>+ <string name="lyrics_card_title" formatted="false">الكلمات</string>+ <string name="lyrics_card_title_preview" formatted="false">معاينة الكلمات</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">عرض الكلمات</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">فتح الكلمات في شاشة كاملة</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">مشاركة الكلمات</string>+ <string name="lyrics_credential_note" formatted="false">الكلمات قدمها %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">مشاركة</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">ترجمة</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">اقفل الكلمات</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">ترجمة الكلمات</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">وقَّف ترجمة الكلمات</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">للأسف. منعرفش كلمات الأغنية دي.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">الكلمات دي لسه مش متزامنة مع اللحن.</string>+ <string name="av_switch_to_video" formatted="false">تبديل للفيديو</string>+ <string name="av_switch_to_audio" formatted="false">تبديل للصوت</string>+ <string name="av_content_desc" formatted="false">تبديل بين الصوت والفيديو</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">الصفحة الرئيسية</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">بحث</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">مكتبتك الموسيقية</string>+ <string name="search_header_field_hint" formatted="false">عاوز تسمع إيه؟</string>+ <string name="filter_chip_all_label" formatted="false">الكل</string>+ <string name="recents_content_filter_music" formatted="false">الموسيقى</string>+ <string name="ad_category_title_podcasts" formatted="false">برامج البودكاست</string>+ <string name="audiobooks_title" formatted="false">الكتب الصوتية</string>+ <string name="artist_popular_tracks" formatted="false">محتوى مشهور</string>+ <string name="curation_button_follow_state_text" formatted="false">متابعة</string>+ <string name="curation_button_following_state_text" formatted="false">بتتابعه</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">الفنان</string>+ <string name="connect_phone_is_self" formatted="false">التليفون ده</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">مؤثرات بصرية قصيرة ومتكررة بتظهر والأغنية شغالة.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">مش دلوقتي</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">تحديث</string>+ <string name="context_type_description_play_queue" formatted="false">الاستماع من \"قايمة السماع\"</string>+ <string name="context_type_description_collection_your_library" formatted="false">الاستماع من \"مكتبتك الموسيقية\"</string>+ <string name="context_type_description_playlist" formatted="false">سماع من قايمة الأغاني</string>+ <string name="context_type_description_album" formatted="false">الاستماع من \"الألبوم\"</string>+ <string name="context_type_description_artist" formatted="false">الاستماع من \"الفنان\"</string>+ <string name="context_type_description_show" formatted="false">سماع من البودكاست</string>+ <string name="context_type_description_search" formatted="false">الاستماع من \"البحث\"</string>+ <string name="default_notification_channel_name" formatted="false">Spotify</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="action_share_label" formatted="false">مشاركة</string>+ <string name="action_queue_label" formatted="false">قايمة السماع</string>+ <string name="mute_chat_duration_one_hour" formatted="false">ساعة</string>+ <string name="curation_actions_edit_button_title" formatted="false">تعديل</string>+ <string name="content_description_pause_button" formatted="false">توقيف مؤقت</string>+ <string name="content_description_play_button" formatted="false">تشغيل</string>+ <string name="play_mode_item_shuffle_title" formatted="false">تشغيل عشوائي</string>+ <string name="np_content_desc_repeat" formatted="false">تشغيل تاني</string>+ <string name="np_content_desc_sleep_timer" formatted="false">موقت النوم</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">مسح</string>+ <string name="edit_playlist_items_move_chip" formatted="false">نقل</string>+ <string name="bottom_actions_close" formatted="false">اقفل</string>+ <string name="add_to_queue_action_content_description" formatted="false">إضافة لقايمة السماع</string>+ <string name="curation_button_saved_text" formatted="false">محتوى محفوظ</string>+ <string name="np_content_desc_prev" formatted="false">اللي قبله</string>+ <string name="np_content_desc_next" formatted="false">اللي بعده</string>+ <string name="accessibility_navigate_back" formatted="false">رجوع</string>+ <string name="monthly_listeners_text" formatted="false">%1$s مستمع شهرياً</string>+ <string name="profile_bio_show_less" formatted="false">تفاصيل أقل</string>+ <string name="audiobook_series_see_more_button" formatted="false">تفاصيل أكتر</string>+ <string name="popular_releases_section_title" formatted="false">إصدارات مشهورة</string>+ <string name="creator_biography_section_title" formatted="false">عن</string>+ <string name="fans_also_like_section_title" formatted="false">المعجبين بيحبوا كمان</string>+ <string name="appears_on_section_title" formatted="false">بيظهر في</string>+ <string name="composer_section_button_show_all" formatted="false">عرض الكل</string>+ <string name="releases_title" formatted="false">الإصدارات</string>+ <string name="artist_releases_albums" formatted="false">الألبومات</string>+ <string name="artist_releases_singles" formatted="false">الإصدارات المنفردة والأسطوانات المطوّلة (EP)</string>+ <string name="latest_release_title" formatted="false">أحدث الإصدارات</string>+ <string name="artist_subtitle" formatted="false">الفنان</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">عمليات البحث الأخيرة</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">مسح</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">برامج البودكاست</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">الحلقات</string>+ <string name="assisted_curation_search_song" formatted="false">أغنية</string>+ <string name="album" formatted="false">ألبوم</string>+ <string name="album_type_podcast" formatted="false">بودكاست</string>+ <string name="recently_played_user_profile" formatted="false">الصفحة الشخصية</string>+ <string name="connect_device_menu_logout" formatted="false">تسجيل الخروج</string>+ <string name="library_search_text_hint" formatted="false">بحث في \"مكتبتك الموسيقية\"</string>+ <string name="account_title" formatted="false">الحساب</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">فنانين بتتابعهم</string>+ <string name="settings_item_crossfade_title" formatted="false">مزج الأغاني</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d ثانية</string>+ <string name="local_files_title" formatted="false">الملفات</string>+ <string name="local_files_empty_section_title" formatted="false">إضافة الملفات الصوتية بتاعتك لمكتبتك الموسيقية</string>+ <string name="local_files_empty_section_subtitle" formatted="false">عندك أغنية أو بودكاست شخصي مش موجود على Spotify؟</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">ملفاتك الصوتية هتظهر هنا</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">سماح بالدخول</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">انتقل للإعدادات</string>+ <string name="context_menu_download" formatted="false">تنزيل</string>+ <string name="context_menu_undownload" formatted="false">مسح التنزيل</string>+ <string name="collection_downloaded" formatted="false">نزل</string>+ <string name="download_badge_downloaded_content_description" formatted="false">التنزيل خلص</string>+ <string name="download_badge_downloading_content_description" formatted="false">التنزيل شغال</string>+ <string name="download_badge_error_content_description" formatted="false">فشل التنزيل</string>+ <string name="download_notification_downloading" formatted="false">جارٍ التنزيل…</string>+ <string name="toast_undownload" formatted="false">الملفات اللي نزلتها اتشالت.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">عايز تشيل المحتوى ده من الملفات اللي نزلتها؟</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">مش هتقدر تشغل المحتوى ده من غير نت.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">إزالة</string>+ <string name="settings_item_remove_downloads_title" formatted="false">شيل كل الأغاني اللي نزلت</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">عايز تشيل كل الأغاني اللي نزلت؟</string>+ <string name="album_type_album" formatted="false">الألبوم</string>+ <string name="album_type_single" formatted="false">إصدار منفرد</string>+ <string name="album_type_ep" formatted="false">أسطوانة مطوّلة (EP)</string>+ <string name="album_type_compilation" formatted="false">مجموعة</string>+ <string name="assisted_curation_search_playlist" formatted="false">قايمة أغاني</string>+ <string name="assisted_curation_search_filter_top" formatted="false">الأغاني التوب</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">الأغاني</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">الفنانين</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">الألبومات</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">قوايم الأغاني</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">امسح التصنيف</string>+ <string name="ad_category_title_music" formatted="false">الموسيقى</string>+ <string name="made_for_you_hub_title" formatted="false">مخصوص علشانك</string>+ <string name="settings_item_app_language_title" formatted="false">لغة التطبيق</string>+ <string name="create_menu_item_folder_title" formatted="false">المجلد</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">مجلد جديد</string>+ <string name="context_menu_rename_folder" formatted="false">تغيير اسم المجلد</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">اسم المجلد</string>+ <string name="create_playlist_content_description" formatted="false">عمل قايمة أغاني</string>+ <string name="actions_picker_delete" formatted="false">مسح</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">ترتيب حسب</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">الترتيب الأبجدي</string>+ <string name="your_library_sort_order_creator" formatted="false">صانع المحتوى</string>+ <string name="your_library_sort_order_custom" formatted="false">ترتيب مخصوص</string>+ <string name="settings_item_version_title" formatted="false">الإصدار</string>+ <string name="context_menu_go_to_song_radio" formatted="false">روح لراديو الأغاني</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">دوّر في قايمة \"أغاني عجبتني\"</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">دوَّر في قايمة الأغاني</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">معرفناش نلاقي \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-ar-rMA/spotify_plurals.xml b/base/app/src/main/res/values-ar-rMA/spotify_plurals.xmlnew file mode 100644index 00000000..7a298a10--- /dev/null+++ b/base/app/src/main/res/values-ar-rMA/spotify_plurals.xml@@ -0,0 +1,36 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="zero">%1$d أغنية</item>+ <item quantity="one">%1$d أغنية</item>+ <item quantity="two">%1$d أغاني</item>+ <item quantity="few">%1$d أغاني</item>+ <item quantity="many">%1$d أغنية</item>+ <item quantity="other">%1$d أغنية</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="zero">%1$,d تسجيل</item>+ <item quantity="one">%1$,d تسجيل</item>+ <item quantity="two">%1$,d تسجيلات</item>+ <item quantity="few">%1$,d تسجيلات</item>+ <item quantity="many">%1$,d تسجيل</item>+ <item quantity="other">%1$,d تسجيل</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="zero">%1$s قوائم</item>+ <item quantity="one">%1$s قائمة</item>+ <item quantity="two">%1$s قوائم</item>+ <item quantity="few">%1$s قوائم</item>+ <item quantity="many">%1$s قوائم</item>+ <item quantity="other">%1$s قوائم</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="zero">%1$s أغاني</item>+ <item quantity="one">%1$s أغنية</item>+ <item quantity="two">%1$s أغاني</item>+ <item quantity="few">%1$s أغاني</item>+ <item quantity="many">%1$s أغاني</item>+ <item quantity="other">%1$s أغاني</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ar-rMA/spotify_strings.xml b/base/app/src/main/res/values-ar-rMA/spotify_strings.xmlnew file mode 100644index 00000000..b3aee3c6--- /dev/null+++ b/base/app/src/main/res/values-ar-rMA/spotify_strings.xml@@ -0,0 +1,159 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">زيد في الأغاني اللي عاجباك</string>+ <string name="collection_liked_songs_title" formatted="false">الأغاني اللي عاجباك</string>+ <string name="context_menu_add_to_playlist" formatted="false">زيد لقائمة الأغاني</string>+ <string name="context_menu_play_next" formatted="false">اطلق اللي من بعد</string>+ <string name="context_menu_add_to_queue" formatted="false">زيد لقائمة الاستماع</string>+ <string name="context_menu_go_to_queue" formatted="false">سير للتصفح</string>+ <string name="context_menu_browse_album" formatted="false">سير للألبوم</string>+ <string name="context_menu_browse_artist" formatted="false">سير للفنان</string>+ <string name="context_menu_share" formatted="false">شارك</string>+ <string name="context_menu_sleep_timer" formatted="false">توقيت النعاس</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">اطفي الكرونو</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">نهاية المقطع</string>+ <string name="snackbar_added_to_queue" formatted="false">تزاد للقائمة</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">تزادت للأغاني اللي عاجباك.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">تمسحات من الأغاني اللي عاجباك.</string>+ <string name="content_description_context_menu" formatted="false">اختيارات أخرى</string>+ <string name="close_button_content_description" formatted="false">سد</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">مسجّل في</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">قائمة أغاني جديدة</string>+ <string name="add_to_playlist_button_cancel" formatted="false">الغي</string>+ <string name="create_playlist_create_button" formatted="false">دير</string>+ <string name="lyrics_card_title" formatted="false">كلمات الأغاني</string>+ <string name="lyrics_card_title_preview" formatted="false">معاينة الكلمات</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">اعرض الكلمات</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">اعرض الكلمات فالشاشة كاملة</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">شارك كلمات الأغنية</string>+ <string name="lyrics_credential_note" formatted="false">الكلمات من عند %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">شارك</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">ترجم</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">حيّد الكلمات</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">ترجم الكلمات</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">وقّف ترجمة الكلمات</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">اممم. ماعارفينش الكلمات ديال هادي.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">هاد الكلمات ما كتبانش فورا، مؤقتا.</string>+ <string name="av_switch_to_video" formatted="false">حوّل للفيديو</string>+ <string name="av_switch_to_audio" formatted="false">حوّل للصوت</string>+ <string name="av_content_desc" formatted="false">بدِّل بين الفيديو والمقطع الصوتي</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">الصفحة الرئيسية</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">قلّب</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">مكتبتك</string>+ <string name="search_header_field_hint" formatted="false">لاش بغيتي اتصنت؟</string>+ <string name="filter_chip_all_label" formatted="false">كلشي</string>+ <string name="recents_content_filter_music" formatted="false">الموسيقى</string>+ <string name="ad_category_title_podcasts" formatted="false">البودكاسات</string>+ <string name="audiobooks_title" formatted="false">كتب صوتية</string>+ <string name="artist_popular_tracks" formatted="false">معروفة</string>+ <string name="curation_button_follow_state_text" formatted="false">تبّع</string>+ <string name="curation_button_following_state_text" formatted="false">متابع</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">فنان</string>+ <string name="connect_phone_is_self" formatted="false">هاد التليفون</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">مؤثرات بصرية قصيرة ومتكررة كنبان فاش كتكون الأغنية خدّامة.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">ماشي دابا</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">أكتياليزي</string>+ <string name="context_type_description_play_queue" formatted="false">مطلوق من قائمة التشغيل</string>+ <string name="context_type_description_collection_your_library" formatted="false">مطلوق من مكتبتك</string>+ <string name="context_type_description_playlist" formatted="false">خدّم من القائمة</string>+ <string name="context_type_description_album" formatted="false">مطلوق من الألبوم</string>+ <string name="context_type_description_artist" formatted="false">مطلوق من الفنان</string>+ <string name="context_type_description_show" formatted="false">خدم من البودكاست</string>+ <string name="context_type_description_search" formatted="false">مطلوق من البحث</string>+ <string name="default_notification_channel_name" formatted="false">Spotify</string>+ <string name="label_bluetooth" formatted="false">بلوتوت</string>+ <string name="action_share_label" formatted="false">شارك</string>+ <string name="action_queue_label" formatted="false">قائمة الاستماع</string>+ <string name="mute_chat_duration_one_hour" formatted="false">ساعة (1)</string>+ <string name="curation_actions_edit_button_title" formatted="false">بدّل</string>+ <string name="content_description_pause_button" formatted="false">حبّسْ</string>+ <string name="content_description_play_button" formatted="false">خدّم</string>+ <string name="play_mode_item_shuffle_title" formatted="false">خدّم عشوائيا</string>+ <string name="np_content_desc_repeat" formatted="false">عاود</string>+ <string name="np_content_desc_sleep_timer" formatted="false">توقيت النعاس</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">امسح</string>+ <string name="edit_playlist_items_move_chip" formatted="false">حرّك</string>+ <string name="bottom_actions_close" formatted="false">سد</string>+ <string name="add_to_queue_action_content_description" formatted="false">زيد لقائمة الاستماع</string>+ <string name="curation_button_saved_text" formatted="false">مسجل</string>+ <string name="np_content_desc_prev" formatted="false">اللي قبل</string>+ <string name="np_content_desc_next" formatted="false">اللي من بعد</string>+ <string name="accessibility_navigate_back" formatted="false">ارجع</string>+ <string name="monthly_listeners_text" formatted="false">%1$s مستمع كل شهر</string>+ <string name="profile_bio_show_less" formatted="false">اعرض أقل</string>+ <string name="audiobook_series_see_more_button" formatted="false">اعرض أكثر</string>+ <string name="popular_releases_section_title" formatted="false">إصدارات مشهورة</string>+ <string name="creator_biography_section_title" formatted="false">معلومات إضافية</string>+ <string name="fans_also_like_section_title" formatted="false">المعجبين كيبغيوا حتى</string>+ <string name="appears_on_section_title" formatted="false">طالع في</string>+ <string name="composer_section_button_show_all" formatted="false">شوف كلشي</string>+ <string name="releases_title" formatted="false">الإصدارات</string>+ <string name="artist_releases_albums" formatted="false">الألبومات</string>+ <string name="artist_releases_singles" formatted="false">السینگل والأسطوانات المطولة</string>+ <string name="latest_release_title" formatted="false">آخر إصدار</string>+ <string name="artist_subtitle" formatted="false">فنان</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">آخر عمليات البحث</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">امسح</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">البودكاسات</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">الحلقات</string>+ <string name="assisted_curation_search_song" formatted="false">أغنية</string>+ <string name="album" formatted="false">ألبوم</string>+ <string name="album_type_podcast" formatted="false">بودكاست</string>+ <string name="recently_played_user_profile" formatted="false">الصفحة الشخصية</string>+ <string name="connect_device_menu_logout" formatted="false">سجّل الخروج</string>+ <string name="library_search_text_hint" formatted="false">قلّب في مكتبتك</string>+ <string name="account_title" formatted="false">الحساب</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">فنانين متابعهم</string>+ <string name="settings_item_crossfade_title" formatted="false">دمج</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d ثانية</string>+ <string name="local_files_title" formatted="false">الفيشيات ديالك</string>+ <string name="local_files_empty_section_title" formatted="false">زيد الملفات الصوتية ديالك لمكتبتك الموسيقية</string>+ <string name="local_files_empty_section_subtitle" formatted="false">واش عندك أغنية أو بودكاست شخصي مكاينش في Spotify؟</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">الملفات الصوتية ديالك غادي تبان هنا</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">اسمح بالولوج</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">ادخل للإعدادات</string>+ <string name="context_menu_download" formatted="false">تليشارجي</string>+ <string name="context_menu_undownload" formatted="false">امسح التليشارجومون</string>+ <string name="collection_downloaded" formatted="false">تليشارجا</string>+ <string name="download_badge_downloaded_content_description" formatted="false">تيليشارجا</string>+ <string name="download_badge_downloading_content_description" formatted="false">كايتليشارجا</string>+ <string name="download_badge_error_content_description" formatted="false">ما تلیشارجاش</string>+ <string name="download_notification_downloading" formatted="false">كايتليشارجا…</string>+ <string name="toast_undownload" formatted="false">التحميل اتّمْسَح.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">امسح من التليشارجومون؟</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">ماتقدرش تخدّم هادشي بلا أنترنت.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">امسح</string>+ <string name="settings_item_remove_downloads_title" formatted="false">تمسحْ كاع التليشارج</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">تبغي تمسحْ كاع التليشارجومون؟</string>+ <string name="album_type_album" formatted="false">ألبوم</string>+ <string name="album_type_single" formatted="false">أغنية واحدة</string>+ <string name="album_type_ep" formatted="false">مجموعة أغاني</string>+ <string name="album_type_compilation" formatted="false">مجموعة أغاني</string>+ <string name="assisted_curation_search_playlist" formatted="false">قائمة الأغاني</string>+ <string name="assisted_curation_search_filter_top" formatted="false">الأكثر نجاح</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">أغاني</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">الفنانين</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">الألبومات</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">قوائم الأغاني</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">امسح التصنيف</string>+ <string name="ad_category_title_music" formatted="false">الموسيقى</string>+ <string name="made_for_you_hub_title" formatted="false">مصممة على ودك</string>+ <string name="settings_item_app_language_title" formatted="false">اللغة ديال التطبيق</string>+ <string name="create_menu_item_folder_title" formatted="false">مجلّد</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">مجلّد جديد</string>+ <string name="context_menu_rename_folder" formatted="false">اعطي اسم جديد للمجلّد</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">اسم المجلّد</string>+ <string name="create_playlist_content_description" formatted="false">دير قائمة أغاني جديدة</string>+ <string name="actions_picker_delete" formatted="false">امسَح</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">رتب حسب</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">أبجدي</string>+ <string name="your_library_sort_order_creator" formatted="false">صانع المحتوى</string>+ <string name="your_library_sort_order_custom" formatted="false">ترتيب مخصّص</string>+ <string name="settings_item_version_title" formatted="false">النسخة</string>+ <string name="context_menu_go_to_song_radio" formatted="false">سير لراديو الأغنية</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">قلب فالأغاني اللي عاجباك</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">ابحت فالقائمة</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">ماقدرناش نلقاوا\"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-ar-rSA/spotify_plurals.xml b/base/app/src/main/res/values-ar-rSA/spotify_plurals.xmlnew file mode 100644index 00000000..957f4860--- /dev/null+++ b/base/app/src/main/res/values-ar-rSA/spotify_plurals.xml@@ -0,0 +1,36 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="zero">ولا أغنية (%1$d)</item>+ <item quantity="one">أغنية واحدة (%1$d)</item>+ <item quantity="two">أغنيتين (%1$d)</item>+ <item quantity="few">%1$d أغاني</item>+ <item quantity="many">%1$d أغنية</item>+ <item quantity="other">%1$d أغنية</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="zero">ما في مرات حفظ (%1$,d)</item>+ <item quantity="one">مرة حفظ واحدة (%1$,d)</item>+ <item quantity="two">مرتين حفظ (%1$,d)</item>+ <item quantity="few">%1$,d مرات الحفظ</item>+ <item quantity="many">%1$,d مرة حفظ</item>+ <item quantity="other">%1$,d مرة حفظ</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="zero">ما في قوائم أغاني (%1$s)</item>+ <item quantity="one">قائمة أغاني واحدة (%1$s)</item>+ <item quantity="two">قائمتين أغاني (%1$s)</item>+ <item quantity="few">%1$s قوائم أغاني</item>+ <item quantity="many">%1$s قائمة أغاني</item>+ <item quantity="other">%1$s قائمة أغاني</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="zero">ولا أغنية (%1$s)</item>+ <item quantity="one">أغنية واحدة (%1$s)</item>+ <item quantity="two">أغنيتين (%1$s)</item>+ <item quantity="few">%1$s أغاني</item>+ <item quantity="many">%1$s أغنية</item>+ <item quantity="other">%1$s أغنية</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ar-rSA/spotify_strings.xml b/base/app/src/main/res/values-ar-rSA/spotify_strings.xmlnew file mode 100644index 00000000..32316810--- /dev/null+++ b/base/app/src/main/res/values-ar-rSA/spotify_strings.xml@@ -0,0 +1,159 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">إضافة لقائمة \"أغاني أعجبتني\"</string>+ <string name="collection_liked_songs_title" formatted="false">أغاني عجبتني</string>+ <string name="context_menu_add_to_playlist" formatted="false">إضافة إلى قايمة الأغاني</string>+ <string name="context_menu_play_next" formatted="false">تشغيل اللي بعده</string>+ <string name="context_menu_add_to_queue" formatted="false">ضيف لقائمة الاستماع</string>+ <string name="context_menu_go_to_queue" formatted="false">روح لقائمة الاستماع</string>+ <string name="context_menu_browse_album" formatted="false">روح على الألبوم</string>+ <string name="context_menu_browse_artist" formatted="false">روح على الفنان</string>+ <string name="context_menu_share" formatted="false">مشاركة</string>+ <string name="context_menu_sleep_timer" formatted="false">موقت النوم</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">إيقاف الموقت</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">نهاية المقطع</string>+ <string name="snackbar_added_to_queue" formatted="false">انضاف إلى قائمة الاستماع</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">انضافت لقائمة \"أغاني عجبتني\".</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">انشالت من قائمة :أغاني عجبتني\".</string>+ <string name="content_description_context_menu" formatted="false">خيارات أكثر</string>+ <string name="close_button_content_description" formatted="false">قفل</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">مجلد الحفظ</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">قائمة أغاني جديدة</string>+ <string name="add_to_playlist_button_cancel" formatted="false">إلغاء</string>+ <string name="create_playlist_create_button" formatted="false">إنشاء</string>+ <string name="lyrics_card_title" formatted="false">الكلمات</string>+ <string name="lyrics_card_title_preview" formatted="false">معاينة الكلمات</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">عرض الكلمات</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">فتح الكلمات بملء الشاشة</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">مشاركة الكلمات</string>+ <string name="lyrics_credential_note" formatted="false">الكلمات مقدمة من %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">مشاركة</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">ترجمة</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">إخفاء الكلمات</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">ترجمة الكلمات</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">إيقاف ترجمة الكلمات</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">همم. ما نعرف كلمات هذه الأغنية.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">هذه الكلمات لسى ما اتزامنت .</string>+ <string name="av_switch_to_video" formatted="false">تبديل إلى فيديو</string>+ <string name="av_switch_to_audio" formatted="false">تبديل إلى ملف صوتي</string>+ <string name="av_content_desc" formatted="false">تبديل بين مقطع صوتي ومقطع فيديو</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">الصفحة الرئيسية</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">بحث</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">مكتبتك الموسيقية</string>+ <string name="search_header_field_hint" formatted="false">ايش تبي تستمع له؟</string>+ <string name="filter_chip_all_label" formatted="false">الكل</string>+ <string name="recents_content_filter_music" formatted="false">موسيقى</string>+ <string name="ad_category_title_podcasts" formatted="false">برامج البودكاست</string>+ <string name="audiobooks_title" formatted="false">كتب صوتية</string>+ <string name="artist_popular_tracks" formatted="false">محتوى مشهور</string>+ <string name="curation_button_follow_state_text" formatted="false">متابعة</string>+ <string name="curation_button_following_state_text" formatted="false">المحتوى الي تتابعه</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">فنان</string>+ <string name="connect_phone_is_self" formatted="false">هذا التليفون</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">مؤثرات مرئية قصيرة تكرر نفسها مع تشغيل الأغاني.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">مو الحين</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">تحديث</string>+ <string name="context_type_description_play_queue" formatted="false">الاستماع من قائمة الاستماع</string>+ <string name="context_type_description_collection_your_library" formatted="false">الاستماع من مكتبتك الموسيقية</string>+ <string name="context_type_description_playlist" formatted="false">الاستماع من قائمة الأغاني</string>+ <string name="context_type_description_album" formatted="false">الاستماع من الألبوم</string>+ <string name="context_type_description_artist" formatted="false">الاستماع من الفنان</string>+ <string name="context_type_description_show" formatted="false">الاستماع من البودكاست</string>+ <string name="context_type_description_search" formatted="false">الاستماع من نتائج البحث</string>+ <string name="default_notification_channel_name" formatted="false">Spotify</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="action_share_label" formatted="false">مشاركة</string>+ <string name="action_queue_label" formatted="false">قائمة الاستماع</string>+ <string name="mute_chat_duration_one_hour" formatted="false">ساعة واحدة</string>+ <string name="curation_actions_edit_button_title" formatted="false">تعديل</string>+ <string name="content_description_pause_button" formatted="false">توقيف مؤقت</string>+ <string name="content_description_play_button" formatted="false">شغّل</string>+ <string name="play_mode_item_shuffle_title" formatted="false">تشغيل عشوائي</string>+ <string name="np_content_desc_repeat" formatted="false">تكرار المقطع</string>+ <string name="np_content_desc_sleep_timer" formatted="false">موقت النوم</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">حذف</string>+ <string name="edit_playlist_items_move_chip" formatted="false">تحريك</string>+ <string name="bottom_actions_close" formatted="false">إغلاق</string>+ <string name="add_to_queue_action_content_description" formatted="false">إضافة إلى قائمة الاستماع</string>+ <string name="curation_button_saved_text" formatted="false">انحفظ</string>+ <string name="np_content_desc_prev" formatted="false">السابق</string>+ <string name="np_content_desc_next" formatted="false">اللي بعده</string>+ <string name="accessibility_navigate_back" formatted="false">رجوع</string>+ <string name="monthly_listeners_text" formatted="false">%1$s مستمع شهريًا</string>+ <string name="profile_bio_show_less" formatted="false">عرض أقل</string>+ <string name="audiobook_series_see_more_button" formatted="false">عرض أكثر</string>+ <string name="popular_releases_section_title" formatted="false">الإصدارات الرائجة</string>+ <string name="creator_biography_section_title" formatted="false">معلومات عن</string>+ <string name="fans_also_like_section_title" formatted="false">المعجبين يحبون كمان</string>+ <string name="appears_on_section_title" formatted="false">تظهر في</string>+ <string name="composer_section_button_show_all" formatted="false">عرض الكل</string>+ <string name="releases_title" formatted="false">الإصدارات</string>+ <string name="artist_releases_albums" formatted="false">الألبومات</string>+ <string name="artist_releases_singles" formatted="false">إصدار منفرد واسطوانات مطولة</string>+ <string name="latest_release_title" formatted="false">أحدث الإصدارات</string>+ <string name="artist_subtitle" formatted="false">فنان</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">أحدث عمليات البحث</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">مسح</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">بودكاست</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">الحلقات</string>+ <string name="assisted_curation_search_song" formatted="false">أغنية</string>+ <string name="album" formatted="false">ألبوم</string>+ <string name="album_type_podcast" formatted="false">بودكاست</string>+ <string name="recently_played_user_profile" formatted="false">الصفحة الشخصية</string>+ <string name="connect_device_menu_logout" formatted="false">خروج</string>+ <string name="library_search_text_hint" formatted="false">ابحث في \"مكتبتك الموسيقية\"</string>+ <string name="account_title" formatted="false">الحساب</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">الفنانين اللي تتابعهم</string>+ <string name="settings_item_crossfade_title" formatted="false">مزج الأغاني</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d ث</string>+ <string name="local_files_title" formatted="false">الملفات</string>+ <string name="local_files_empty_section_title" formatted="false">إضافة الملفات الصوتية حقتك إلى مكتبتك الموسيقية</string>+ <string name="local_files_empty_section_subtitle" formatted="false">عندك أغنية أو بودكاست شخصي مو متوفر على Spotify؟</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">راح تظهر ملفاتك الصوتية هنا</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">منح إذن الوصول</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">روح إلى الإعدادات</string>+ <string name="context_menu_download" formatted="false">تنزيل</string>+ <string name="context_menu_undownload" formatted="false">إزالة التحميل</string>+ <string name="collection_downloaded" formatted="false">تم التنزيل</string>+ <string name="download_badge_downloaded_content_description" formatted="false">خلص التنزيل</string>+ <string name="download_badge_downloading_content_description" formatted="false">جاري التنزيل</string>+ <string name="download_badge_error_content_description" formatted="false">فشل التنزيل</string>+ <string name="download_notification_downloading" formatted="false">جاري التنزيل</string>+ <string name="toast_undownload" formatted="false">انحذف اللي تم تنزيله.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">إزالة من التنزيلات؟</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">ما رح تقدر تسمع هاذي الأغنية بدون اتصال بالإنترنت.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">إزالة</string>+ <string name="settings_item_remove_downloads_title" formatted="false">إزالة كل التنزيلات</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">تبي تحذف كل التنزيلات؟</string>+ <string name="album_type_album" formatted="false">ألبوم</string>+ <string name="album_type_single" formatted="false">إصدار منفرد</string>+ <string name="album_type_ep" formatted="false">أسطوانة مطوّلة (EP)</string>+ <string name="album_type_compilation" formatted="false">عمليات التجميع</string>+ <string name="assisted_curation_search_playlist" formatted="false">قائمة أغاني</string>+ <string name="assisted_curation_search_filter_top" formatted="false">الأكثر نجاحًا</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">الأغاني</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">الفنانين</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">الألبومات</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">قوائم الأغاني</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">مسح التصنيف</string>+ <string name="ad_category_title_music" formatted="false">الموسيقى</string>+ <string name="made_for_you_hub_title" formatted="false">مُصممة علشانك</string>+ <string name="settings_item_app_language_title" formatted="false">لغة التطبيق</string>+ <string name="create_menu_item_folder_title" formatted="false">المجلد</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">مجلد جديد</string>+ <string name="context_menu_rename_folder" formatted="false">إعادة تسمية المجلد</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">اسم المجلد</string>+ <string name="create_playlist_content_description" formatted="false">إنشاء قائمة أغاني</string>+ <string name="actions_picker_delete" formatted="false">حذف</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">تصنيف على حسب</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">ترتيب أبجدي</string>+ <string name="your_library_sort_order_creator" formatted="false">صانع المحتوى</string>+ <string name="your_library_sort_order_custom" formatted="false">ترتيب مخصص</string>+ <string name="settings_item_version_title" formatted="false">نسخة</string>+ <string name="context_menu_go_to_song_radio" formatted="false">روح على راديو الأغنية</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">البحث في أغانٍ أعجبتني</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">دوَّر في قائمة الأغاني</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">ما حصّلنا \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-ar/spotify_plurals.xml b/base/app/src/main/res/values-ar/spotify_plurals.xmlnew file mode 100644index 00000000..98cd2ab2--- /dev/null+++ b/base/app/src/main/res/values-ar/spotify_plurals.xml@@ -0,0 +1,36 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="zero">لا توجد أي أغنية (%1$d)</item>+ <item quantity="one">أغنية واحدة (%1$d)</item>+ <item quantity="two">أغنيتان (%1$d)</item>+ <item quantity="few">%1$d أغانٍ</item>+ <item quantity="many">%1$d أغنية</item>+ <item quantity="other">%1$d أغنية</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="zero">لم يتم الحفظ (%1$,d)</item>+ <item quantity="one">تم الحفظ مرة واحدة (%1$,d)</item>+ <item quantity="two">تم الحفظ مرّتَين (%1$,d)</item>+ <item quantity="few">تم الحفظ %1$,d مرات</item>+ <item quantity="many">تم الحفظ %1$,d مرة</item>+ <item quantity="other">تم الحفظ %1$,d مرة</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="zero">لا توجد أي قوائم أغاني (%1$s)</item>+ <item quantity="one">قائمة واحدة للأغاني (%1$s)</item>+ <item quantity="two">قائمتان للأغاني (%1$s)</item>+ <item quantity="few">%1$s قوائم للأغاني</item>+ <item quantity="many">%1$s قائمة للأغاني</item>+ <item quantity="other">%1$s قائمة للأغاني</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="zero">لا توجد أغانٍ (%1$s)</item>+ <item quantity="one">أغنية واحدة (%1$s)</item>+ <item quantity="two">أغنيتان (%1$s)</item>+ <item quantity="few">%1$s أغانٍ</item>+ <item quantity="many">%1$s أغنية</item>+ <item quantity="other">%1$s أغنية</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ar/spotify_strings.xml b/base/app/src/main/res/values-ar/spotify_strings.xmlnew file mode 100644index 00000000..20623795--- /dev/null+++ b/base/app/src/main/res/values-ar/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">إضافة إلى \"أغانٍ أعجبتني\"</string>+ <string name="collection_liked_songs_title" formatted="false">أغانٍ أعجبتني</string>+ <string name="context_menu_add_to_playlist" formatted="false">إضافة إلى قائمة أغانٍ</string>+ <string name="context_menu_play_next" formatted="false">التشغيل بعد الأغنية الحالية</string>+ <string name="context_menu_add_to_queue" formatted="false">أضف إلى قائمة الاستماع</string>+ <string name="context_menu_go_to_queue" formatted="false">اذهب إلى قائمة الاستماع</string>+ <string name="context_menu_browse_album" formatted="false">الانتقال إلى الألبوم</string>+ <string name="context_menu_browse_artist" formatted="false">الانتقال إلى الفنان</string>+ <string name="context_menu_share" formatted="false">شارك</string>+ <string name="context_menu_sleep_timer" formatted="false">مؤقت النوم</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">أوقف المؤقت</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">نهاية المقطع</string>+ <string name="snackbar_added_to_queue" formatted="false">تمت الإضافة إلى قائمة الاستماع</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">تمت الإضافة إلى قائمة \"أغانٍ أعجبتني\".</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">تم الحذف من \"أغانٍ أعجبتني\"</string>+ <string name="content_description_context_menu" formatted="false">خيارات إضافية</string>+ <string name="close_button_content_description" formatted="false">إغلاق</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">تم الحفظ في</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">قائمة للأغاني الجديدة</string>+ <string name="add_to_playlist_button_cancel" formatted="false">إلغاء</string>+ <string name="create_playlist_create_button" formatted="false">إنشاء</string>+ <string name="lyrics_card_title" formatted="false">كلمات الأغنية</string>+ <string name="lyrics_card_title_preview" formatted="false">معاينة الكلمات</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">عرض الكلمات</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">عرض الكلمات بملء الشاشة</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">مشاركة كلمات الأغنية</string>+ <string name="lyrics_credential_note" formatted="false">تم توفير الكلمات من قبل: %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">مشاركة</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">ترجمة</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">إغلاق الكلمات</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">ترجمة الكلمات</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">إيقاف ترجمة الكلمات</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">نحن لا نعرف كلمات هذه الأغنية.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">لم تتم مزامنة كلمات هذه الأغنية بعد.</string>+ <string name="av_switch_to_video" formatted="false">تحويل إلى فيديو</string>+ <string name="av_switch_to_audio" formatted="false">تحويل إلى ملف صوتي</string>+ <string name="av_content_desc" formatted="false">تنقُّل بين الملف الصوتي والفيديو</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">الصفحة الرئيسية</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">بحث</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">مكتبتك الموسيقية</string>+ <string name="search_header_field_hint" formatted="false">ما الذي تريد الاستماع إليه؟</string>+ <string name="filter_chip_all_label" formatted="false">الكل</string>+ <string name="recents_content_filter_music" formatted="false">الموسيقى</string>+ <string name="ad_category_title_podcasts" formatted="false">برامج البودكاست</string>+ <string name="audiobooks_title" formatted="false">الكتب الصوتية</string>+ <string name="artist_popular_tracks" formatted="false">الأغاني الشعبية</string>+ <string name="curation_button_follow_state_text" formatted="false">متابعة</string>+ <string name="curation_button_following_state_text" formatted="false">تتم المتابعة</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">الفنان</string>+ <string name="connect_phone_is_self" formatted="false">هذا الهاتف</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">مؤثِّرات بصرية قصيرة متكرِّرة تُعرض عند الاستماع إلى أغنية.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">ليس الآن</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">تحديث</string>+ <string name="context_type_description_play_queue" formatted="false">الاستماع إلى الأغاني من قائمة الاستماع</string>+ <string name="context_type_description_collection_your_library" formatted="false">الاستماع إلى الأغاني من مكتبتك الموسيقية</string>+ <string name="context_type_description_playlist" formatted="false">الاستماع من قائمة الأغاني</string>+ <string name="context_type_description_album" formatted="false">الاستماع إلى الأغاني من الألبوم</string>+ <string name="context_type_description_artist" formatted="false">الاستماع إلى أغاني الفنان</string>+ <string name="context_type_description_show" formatted="false">الاستماع من البودكاست</string>+ <string name="context_type_description_search" formatted="false">الاستماع إلى الأغاني من البحث</string>+ <string name="default_notification_channel_name" formatted="false">قيد التشغيل الآن</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">الأجهزة</string>+ <string name="action_share_label" formatted="false">مشاركة</string>+ <string name="action_queue_label" formatted="false">قائمة الاستماع</string>+ <string name="mute_chat_duration_one_hour" formatted="false">ساعة واحدة</string>+ <string name="curation_actions_edit_button_title" formatted="false">تعديل</string>+ <string name="content_description_pause_button" formatted="false">إيقاف مؤقّت</string>+ <string name="content_description_play_button" formatted="false">استمع</string>+ <string name="play_mode_item_shuffle_title" formatted="false">تشغيل عشوائي</string>+ <string name="np_content_desc_repeat" formatted="false">أعد الأغنية</string>+ <string name="np_content_desc_sleep_timer" formatted="false">موقت النوم</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">إزالة</string>+ <string name="edit_playlist_items_move_chip" formatted="false">نقل</string>+ <string name="bottom_actions_close" formatted="false">إغلاق</string>+ <string name="add_to_queue_action_content_description" formatted="false">إضافة إلى قائمة الاستماع</string>+ <string name="curation_button_saved_text" formatted="false">تم الحفظ</string>+ <string name="np_content_desc_prev" formatted="false">السابق</string>+ <string name="np_content_desc_next" formatted="false">التالي</string>+ <string name="accessibility_navigate_back" formatted="false">عودة</string>+ <string name="monthly_listeners_text" formatted="false">%1$s مستمع نشط شهرياً</string>+ <string name="profile_bio_show_less" formatted="false">عرض أقل</string>+ <string name="audiobook_series_see_more_button" formatted="false">عرض المزيد</string>+ <string name="popular_releases_section_title" formatted="false">الإصدارات الرائجة</string>+ <string name="creator_biography_section_title" formatted="false">معلومات تعريفية</string>+ <string name="fans_also_like_section_title" formatted="false">المعجبون يحبون أيضاً</string>+ <string name="appears_on_section_title" formatted="false">يظهر في</string>+ <string name="composer_section_button_show_all" formatted="false">عرض الكل</string>+ <string name="releases_title" formatted="false">الإصدارات</string>+ <string name="artist_releases_albums" formatted="false">الألبومات</string>+ <string name="artist_releases_singles" formatted="false">أغاني منفردة وأسطوانات مطوّلة</string>+ <string name="latest_release_title" formatted="false">أحدث الإصدارات</string>+ <string name="artist_subtitle" formatted="false">الفنان</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">سجل البحث</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">حذف</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">برامج البودكاست</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">الحلقات</string>+ <string name="assisted_curation_search_song" formatted="false">أغنية</string>+ <string name="album" formatted="false">ألبوم</string>+ <string name="album_type_podcast" formatted="false">بودكاست</string>+ <string name="recently_played_user_profile" formatted="false">الصفحة الشخصية</string>+ <string name="connect_device_menu_logout" formatted="false">تسجيل الخروج</string>+ <string name="library_search_text_hint" formatted="false">ابحث في مكتبتك الموسيقية</string>+ <string name="account_title" formatted="false">حساب</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">الفنانون الذين تابعتهم</string>+ <string name="settings_item_crossfade_title" formatted="false">مزج الأغاني</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d ثانية</string>+ <string name="local_files_title" formatted="false">الملفات</string>+ <string name="local_files_empty_section_title" formatted="false">إضافة ملفاتك الصوتية إلى \"مكتبتك الموسيقية\"</string>+ <string name="local_files_empty_section_subtitle" formatted="false">هل لديك أغنية أو بودكاست شخصي غير متوفر على Spotify؟</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">ستظهر ملفاتك الصوتية هنا</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">السماح بالوصول</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">الانتقال إلى \"الإعدادات\"</string>+ <string name="context_menu_download" formatted="false">تنزيل</string>+ <string name="context_menu_undownload" formatted="false">إزالة الملف الذي تم تنزيله</string>+ <string name="collection_downloaded" formatted="false">المحتوى الذي تم تنزيله</string>+ <string name="download_badge_downloaded_content_description" formatted="false">الأغاني التي تمّ تحميلها</string>+ <string name="download_badge_downloading_content_description" formatted="false">تحميل</string>+ <string name="download_badge_error_content_description" formatted="false">فشل التحميل</string>+ <string name="download_notification_downloading" formatted="false">جاري التحميل…</string>+ <string name="toast_undownload" formatted="false">تمّ حذف التحميل.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">هل تريد إزالة القائمة من قسم الملفات التي تمّ تنزيلها؟</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">لن تتمكن من الاستماع إلى هذا المحتوى دون اتصال بالإنترنت.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">إزالة</string>+ <string name="settings_item_remove_downloads_title" formatted="false">إزالة جميع الملفات التي تمّ تنزيلها</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">هل تريد إزالة جميع الملفات التي تمّ تنزيلها؟</string>+ <string name="album_type_album" formatted="false">ألبوم</string>+ <string name="album_type_single" formatted="false">إصدار منفرد</string>+ <string name="album_type_ep" formatted="false">أسطوانة مطوّلة (EP)</string>+ <string name="album_type_compilation" formatted="false">مجموعة</string>+ <string name="assisted_curation_search_playlist" formatted="false">قائمة للأغاني</string>+ <string name="assisted_curation_search_filter_top" formatted="false">الأكثر نجاحاً</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">الأغاني</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">الفنانون</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">الألبومات</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">قوائم الأغاني</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">مسح الفلتر</string>+ <string name="ad_category_title_music" formatted="false">الموسيقى</string>+ <string name="made_for_you_hub_title" formatted="false">مُصممة من أجلك</string>+ <string name="settings_item_app_language_title" formatted="false">لغة التطبيق</string>+ <string name="create_menu_item_folder_title" formatted="false">المجلد</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">مجلد جديد</string>+ <string name="context_menu_rename_folder" formatted="false">إعادة تسمية المجلد</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">اسم المُجلّد</string>+ <string name="create_playlist_content_description" formatted="false">إنشاء قائمة الأغاني</string>+ <string name="actions_picker_delete" formatted="false">حذف</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">ترتيب حسب</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">أبجدياً</string>+ <string name="your_library_sort_order_creator" formatted="false">المؤلف</string>+ <string name="your_library_sort_order_custom" formatted="false">ترتيب مُخصص</string>+ <string name="settings_item_version_title" formatted="false">الإصدار</string>+ <string name="context_menu_go_to_song_radio" formatted="false">الانتقال إلى راديو الأغنية</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">البحث في قائمة \"أغانٍ أعجبتني\"</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">البحث في قائمة الأغاني</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">لم نستطع العثور على \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-az/spotify_plurals.xml b/base/app/src/main/res/values-az/spotify_plurals.xmlnew file mode 100644index 00000000..fa7bbfd5--- /dev/null+++ b/base/app/src/main/res/values-az/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d mahnı</item>+ <item quantity="other">%1$d mahnı</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d dəfə yaddaşda saxlanılıb</item>+ <item quantity="other">%1$,d dəfə yaddaşda saxlanılıb</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s pleylist</item>+ <item quantity="other">%1$s pleylist</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s mahnı</item>+ <item quantity="other">%1$s mahnı</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-az/spotify_strings.xml b/base/app/src/main/res/values-az/spotify_strings.xmlnew file mode 100644index 00000000..c477fe47--- /dev/null+++ b/base/app/src/main/res/values-az/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Bəyənilən Mahnılara əlavə et</string>+ <string name="collection_liked_songs_title" formatted="false">Bəyənilən Mahnılar</string>+ <string name="context_menu_add_to_playlist" formatted="false">Pleylistə əlavə et</string>+ <string name="context_menu_play_next" formatted="false">Növbətini oxut</string>+ <string name="context_menu_add_to_queue" formatted="false">Növbəyə Əlavə Et</string>+ <string name="context_menu_go_to_queue" formatted="false">Növbəyə Keç</string>+ <string name="context_menu_browse_album" formatted="false">Alboma keç</string>+ <string name="context_menu_browse_artist" formatted="false">İfaçıya keç</string>+ <string name="context_menu_share" formatted="false">Paylaş</string>+ <string name="context_menu_sleep_timer" formatted="false">Yuxu taymeri</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Taymeri deaktiv et</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Trekin sonu</string>+ <string name="snackbar_added_to_queue" formatted="false">Növbəyə əlavə edildi</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Bəyənilən Mahnılara əlavə edildi.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Bəyənilən mahnılardan silindi.</string>+ <string name="content_description_context_menu" formatted="false">Daha çox seçim</string>+ <string name="close_button_content_description" formatted="false">Bağla</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Burada saxlanılıb</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Yeni pleylist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Ləğv et</string>+ <string name="create_playlist_create_button" formatted="false">Yarat</string>+ <string name="lyrics_card_title" formatted="false">Sözlər</string>+ <string name="lyrics_card_title_preview" formatted="false">Mahnı sözlərinə baxış</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Mahnı sözlərini göstər</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Mahnı sözlərini tam ekranda aç</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Mahnı sözlərini paylaş</string>+ <string name="lyrics_credential_note" formatted="false">%1$s tərəfindən təqdim olunan mahnı sözləri</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Paylaş</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Tərcümə et</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Mahnı sözlərini bağla</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Mahnı sözlərini tərcümə et</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Mahnı sözlərinin tərcüməsini dayandır</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Bu mahnının sözlərini bilmirik.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Bu sözlər hələ vaxtla sinxronlaşdırılmayıb.</string>+ <string name="av_switch_to_video" formatted="false">Videoya keçin</string>+ <string name="av_switch_to_audio" formatted="false">Audioya keçin</string>+ <string name="av_content_desc" formatted="false">Audio və video arasında keçid edin</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Əsas səhifə</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Axtarış</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Kitabxanan</string>+ <string name="search_header_field_hint" formatted="false">Nə dinləmək istəyirsiniz?</string>+ <string name="filter_chip_all_label" formatted="false">Hamısı</string>+ <string name="recents_content_filter_music" formatted="false">Musiqi</string>+ <string name="ad_category_title_podcasts" formatted="false">Podkastlar</string>+ <string name="audiobooks_title" formatted="false">Audiokitablar</string>+ <string name="artist_popular_tracks" formatted="false">Populyar</string>+ <string name="curation_button_follow_state_text" formatted="false">İzlə</string>+ <string name="curation_button_following_state_text" formatted="false">İzlənilən</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">İfaçı</string>+ <string name="connect_phone_is_self" formatted="false">Bu telefon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Mahnı oxudularkən qısa, təkrarlanan vizuallar.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">İndi deyil</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Yenilə</string>+ <string name="context_type_description_play_queue" formatted="false">Oxutma Növbəsindən oxudulur</string>+ <string name="context_type_description_collection_your_library" formatted="false">Kitabxanandan oxudulur</string>+ <string name="context_type_description_playlist" formatted="false">Pleylistdən oxudulur</string>+ <string name="context_type_description_album" formatted="false">Albomdan oxudulur</string>+ <string name="context_type_description_artist" formatted="false">İfaçıdan oxudulur</string>+ <string name="context_type_description_show" formatted="false">Podkastdan Oxudulur</string>+ <string name="context_type_description_search" formatted="false">Axtarışdan oxudulur</string>+ <string name="default_notification_channel_name" formatted="false">İndi oxudulur</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Cihazlar</string>+ <string name="action_share_label" formatted="false">Paylaş</string>+ <string name="action_queue_label" formatted="false">Növbə</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 saat</string>+ <string name="curation_actions_edit_button_title" formatted="false">Redaktə et</string>+ <string name="content_description_pause_button" formatted="false">Fasilə ver</string>+ <string name="content_description_play_button" formatted="false">Oxut</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Təsadüfi qaydada oxut</string>+ <string name="np_content_desc_repeat" formatted="false">Təkrar oxudun</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Yuxu taymeri</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Sil</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Köçür</string>+ <string name="bottom_actions_close" formatted="false">Bağla</string>+ <string name="add_to_queue_action_content_description" formatted="false">Növbəyə əlavə et</string>+ <string name="curation_button_saved_text" formatted="false">Yaddaşda saxlanılıb</string>+ <string name="np_content_desc_prev" formatted="false">Əvvəlki</string>+ <string name="np_content_desc_next" formatted="false">Növbəti</string>+ <string name="accessibility_navigate_back" formatted="false">Geri</string>+ <string name="monthly_listeners_text" formatted="false">Aylıq %1$s dinləyici</string>+ <string name="profile_bio_show_less" formatted="false">Daha az göstər</string>+ <string name="audiobook_series_see_more_button" formatted="false">Daha çox göstər</string>+ <string name="popular_releases_section_title" formatted="false">Populyar buraxılışlar</string>+ <string name="creator_biography_section_title" formatted="false">Haqqında</string>+ <string name="fans_also_like_section_title" formatted="false">Pərəstişkarlar həmçinin bəyənirlər</string>+ <string name="appears_on_section_title" formatted="false">Burada görünür</string>+ <string name="composer_section_button_show_all" formatted="false">Hamısını göstər</string>+ <string name="releases_title" formatted="false">Buraxılışlar</string>+ <string name="artist_releases_albums" formatted="false">Albomlar</string>+ <string name="artist_releases_singles" formatted="false">Sinql və Mini Albomlar</string>+ <string name="latest_release_title" formatted="false">Ən son buraxılış</string>+ <string name="artist_subtitle" formatted="false">İfaçı</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Son axtarışlar</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Sil</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podkastlar</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Bölümlər</string>+ <string name="assisted_curation_search_song" formatted="false">Mahnı</string>+ <string name="album" formatted="false">Albom</string>+ <string name="album_type_podcast" formatted="false">Podkast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Çıxış et</string>+ <string name="library_search_text_hint" formatted="false">Kitabxananı axtar</string>+ <string name="account_title" formatted="false">Hesab</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">İzlənilən ifaçılar</string>+ <string name="settings_item_crossfade_title" formatted="false">Çarpaz keçid</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d san</string>+ <string name="local_files_title" formatted="false">Lokal Fayllar</string>+ <string name="local_files_empty_section_title" formatted="false">Öz audiofayllarınızı Kitabxana bölməsinə əlavə edin</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Spotify-da olmayan mahnı və ya şəxsi podkastınız var?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Audiofayllarınız burada görünəcək</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Giriş icazəsi ver</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Parametrlərə keç</string>+ <string name="context_menu_download" formatted="false">Endir</string>+ <string name="context_menu_undownload" formatted="false">Endirməni sil</string>+ <string name="collection_downloaded" formatted="false">Endirilmiş</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Endirilmiş</string>+ <string name="download_badge_downloading_content_description" formatted="false">Endirilir</string>+ <string name="download_badge_error_content_description" formatted="false">Endirmə uğursuz oldu</string>+ <string name="download_notification_downloading" formatted="false">Endirilir…</string>+ <string name="toast_undownload" formatted="false">Endirmə silindi.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Endirmələrdən silinsin?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Oflayn rejimdə bunu oxuda bilməyəcəksən.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Sil</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Bütün endirmələri sil</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Bütün endirmələr silinsin?</string>+ <string name="album_type_album" formatted="false">Albom</string>+ <string name="album_type_single" formatted="false">Sinql</string>+ <string name="album_type_ep" formatted="false">Mini albom</string>+ <string name="album_type_compilation" formatted="false">Toplu</string>+ <string name="assisted_curation_search_playlist" formatted="false">Pleylist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Populyar</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Mahnılar</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">İfaçılar</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albomlar</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Pleylistlər</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Filtri təmizlə</string>+ <string name="ad_category_title_music" formatted="false">Musiqi</string>+ <string name="made_for_you_hub_title" formatted="false">Sənin üçün Hazırlanıb</string>+ <string name="settings_item_app_language_title" formatted="false">Tətbiqin dili</string>+ <string name="create_menu_item_folder_title" formatted="false">Qovluq</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Yeni qovluq</string>+ <string name="context_menu_rename_folder" formatted="false">Qovluğun adını dəyiş</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Qovluq adı</string>+ <string name="create_playlist_content_description" formatted="false">Pleylist yarat</string>+ <string name="actions_picker_delete" formatted="false">Sil</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Çeşidlə:</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Əlifba sırası ilə</string>+ <string name="your_library_sort_order_creator" formatted="false">Yaradan</string>+ <string name="your_library_sort_order_custom" formatted="false">Xüsusi sıralama</string>+ <string name="settings_item_version_title" formatted="false">Versiya</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Mahnı radiosuna keç</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Bəyənilən mahnılarda tap</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Pleylistdə tap</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\" tapılmadı</string>+</resources>diff --git a/base/app/src/main/res/values-bg/spotify_plurals.xml b/base/app/src/main/res/values-bg/spotify_plurals.xmlnew file mode 100644index 00000000..df822e0f--- /dev/null+++ b/base/app/src/main/res/values-bg/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d песен</item>+ <item quantity="other">%1$d песни</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d запазване</item>+ <item quantity="other">%1$,d запазвания</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s плейлист</item>+ <item quantity="other">%1$s плейлиста</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s песен</item>+ <item quantity="other">%1$s песни</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-bg/spotify_strings.xml b/base/app/src/main/res/values-bg/spotify_strings.xmlnew file mode 100644index 00000000..e4f9b2c3--- /dev/null+++ b/base/app/src/main/res/values-bg/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Добавете към „Харесани песни“</string>+ <string name="collection_liked_songs_title" formatted="false">Харесани песни</string>+ <string name="context_menu_add_to_playlist" formatted="false">Добавете към плейлист</string>+ <string name="context_menu_play_next" formatted="false">Пуснете след това</string>+ <string name="context_menu_add_to_queue" formatted="false">Добавете към опашката</string>+ <string name="context_menu_go_to_queue" formatted="false">Към опашката</string>+ <string name="context_menu_browse_album" formatted="false">Към албума</string>+ <string name="context_menu_browse_artist" formatted="false">Към изпълнителя</string>+ <string name="context_menu_share" formatted="false">Споделете</string>+ <string name="context_menu_sleep_timer" formatted="false">Таймер за сън</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Изключете таймера</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Края на записа</string>+ <string name="snackbar_added_to_queue" formatted="false">Добавено към опашката</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Добавено в „Харесани песни“.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Премахнато от „Харесани песни“.</string>+ <string name="content_description_context_menu" formatted="false">Още опции</string>+ <string name="close_button_content_description" formatted="false">Затваряне</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Запазено в</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Нов плейлист</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Отмяна</string>+ <string name="create_playlist_create_button" formatted="false">Създаване</string>+ <string name="lyrics_card_title" formatted="false">Текст</string>+ <string name="lyrics_card_title_preview" formatted="false">Преглед на текста</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Покажете текста</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Отворете текста на цял екран</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Споделете текста</string>+ <string name="lyrics_credential_note" formatted="false">Текст, предоставен от %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Споделете</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Превод</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Затворете текста</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Преведете текста</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Спрете превода на текста</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Хмм. И ние не знаем текста този път.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Този текст все още не е синхронизиран по време.</string>+ <string name="av_switch_to_video" formatted="false">Превключете към видео</string>+ <string name="av_switch_to_audio" formatted="false">Превключете към аудио</string>+ <string name="av_content_desc" formatted="false">Изберете между аудио и видео</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Начало</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Търсете</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Вашата библиотека</string>+ <string name="search_header_field_hint" formatted="false">Какво искате да слушате?</string>+ <string name="filter_chip_all_label" formatted="false">Всички</string>+ <string name="recents_content_filter_music" formatted="false">Музика</string>+ <string name="ad_category_title_podcasts" formatted="false">Подкасти</string>+ <string name="audiobooks_title" formatted="false">Аудиокниги</string>+ <string name="artist_popular_tracks" formatted="false">Популярни</string>+ <string name="curation_button_follow_state_text" formatted="false">Последвайте</string>+ <string name="curation_button_following_state_text" formatted="false">Следвате</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Изпълнител</string>+ <string name="connect_phone_is_self" formatted="false">Този телефон</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Кратки, повтарящи се визуализации по време на възпроизвеждане на песен.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Не сега</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Актуализирайте</string>+ <string name="context_type_description_play_queue" formatted="false">Възпроизвежда се от опашката за възпроизвеждане</string>+ <string name="context_type_description_collection_your_library" formatted="false">Възпроизвежда се от вашата библиотека</string>+ <string name="context_type_description_playlist" formatted="false">Възпроизвежда се от плейлист</string>+ <string name="context_type_description_album" formatted="false">Възпроизвежда се от албум</string>+ <string name="context_type_description_artist" formatted="false">Възпроизвежда се от изпълнител</string>+ <string name="context_type_description_show" formatted="false">Възпроизвежда се от подкаст</string>+ <string name="context_type_description_search" formatted="false">Възпроизвежда се от търсене</string>+ <string name="default_notification_channel_name" formatted="false">Възпроизвеждано сега съдържание</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Устройства</string>+ <string name="action_share_label" formatted="false">Споделете</string>+ <string name="action_queue_label" formatted="false">Опашка</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 час</string>+ <string name="curation_actions_edit_button_title" formatted="false">Редактирайте</string>+ <string name="content_description_pause_button" formatted="false">Пауза</string>+ <string name="content_description_play_button" formatted="false">Пуснете</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Разбъркване</string>+ <string name="np_content_desc_repeat" formatted="false">Пуснете отново</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Таймер за сън</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Премахнете</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Преместете</string>+ <string name="bottom_actions_close" formatted="false">Затворете</string>+ <string name="add_to_queue_action_content_description" formatted="false">Добавете към опашката</string>+ <string name="curation_button_saved_text" formatted="false">Запазено</string>+ <string name="np_content_desc_prev" formatted="false">Предишно</string>+ <string name="np_content_desc_next" formatted="false">Напред</string>+ <string name="accessibility_navigate_back" formatted="false">Назад</string>+ <string name="monthly_listeners_text" formatted="false">%1$s месечни слушатели</string>+ <string name="profile_bio_show_less" formatted="false">Покажете по‑малко</string>+ <string name="audiobook_series_see_more_button" formatted="false">Покажете още</string>+ <string name="popular_releases_section_title" formatted="false">Популярни издания</string>+ <string name="creator_biography_section_title" formatted="false">Относно</string>+ <string name="fans_also_like_section_title" formatted="false">Феновете харесват също</string>+ <string name="appears_on_section_title" formatted="false">Участва в/ъв</string>+ <string name="composer_section_button_show_all" formatted="false">Покажете всичко</string>+ <string name="releases_title" formatted="false">Издания</string>+ <string name="artist_releases_albums" formatted="false">Албуми</string>+ <string name="artist_releases_singles" formatted="false">Сингли и EP албуми</string>+ <string name="latest_release_title" formatted="false">Най-ново издание</string>+ <string name="artist_subtitle" formatted="false">Изпълнител</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Скорошни търсения</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Изчистете</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Подкасти</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Епизоди</string>+ <string name="assisted_curation_search_song" formatted="false">Песен</string>+ <string name="album" formatted="false">Албум</string>+ <string name="album_type_podcast" formatted="false">Подкаст</string>+ <string name="recently_played_user_profile" formatted="false">Профил</string>+ <string name="connect_device_menu_logout" formatted="false">Излезте от акаунта</string>+ <string name="library_search_text_hint" formatted="false">Търсете във „Вашата библиотека“</string>+ <string name="account_title" formatted="false">Акаунт</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Последвани изпълнители</string>+ <string name="settings_item_crossfade_title" formatted="false">Плавен преход</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d сек</string>+ <string name="local_files_title" formatted="false">Локални файлове</string>+ <string name="local_files_empty_section_title" formatted="false">Добавете свои собствени аудиофайлове към „Вашата библиотека“</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Имате песен или личен подкаст, които не са в Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Аудиофайловете ви ще се показват тук</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Дайте достъп</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Към „Настройки“</string>+ <string name="context_menu_download" formatted="false">Изтеглете</string>+ <string name="context_menu_undownload" formatted="false">Премахнете изтеглянето</string>+ <string name="collection_downloaded" formatted="false">Изтеглени</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Изтеглено</string>+ <string name="download_badge_downloading_content_description" formatted="false">Изтегля се</string>+ <string name="download_badge_error_content_description" formatted="false">Неуспешно изтегляне</string>+ <string name="download_notification_downloading" formatted="false">Изтегля се…</string>+ <string name="toast_undownload" formatted="false">Изтеглянето е премахнато.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Премахване от изтеглянията?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Няма да можете да пускате това офлайн.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Премахнете</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Премахнете всички изтегляния</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Премахване на всички изтегляния?</string>+ <string name="album_type_album" formatted="false">Албум</string>+ <string name="album_type_single" formatted="false">Сингъл</string>+ <string name="album_type_ep" formatted="false">EP албум</string>+ <string name="album_type_compilation" formatted="false">Компилация</string>+ <string name="assisted_curation_search_playlist" formatted="false">Плейлист</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Най‑добри резултати</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Песни</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Изпълнители</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Албуми</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Плейлисти</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Изчистете филтъра</string>+ <string name="ad_category_title_music" formatted="false">Музика</string>+ <string name="made_for_you_hub_title" formatted="false">Подбрано за вас</string>+ <string name="settings_item_app_language_title" formatted="false">Език на приложението</string>+ <string name="create_menu_item_folder_title" formatted="false">Папка</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Нова папка</string>+ <string name="context_menu_rename_folder" formatted="false">Преименувайте папката</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Име на папката</string>+ <string name="create_playlist_content_description" formatted="false">Създайте плейлист</string>+ <string name="actions_picker_delete" formatted="false">Изтрийте</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Сортирайте по</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Азбучно</string>+ <string name="your_library_sort_order_creator" formatted="false">Създател</string>+ <string name="your_library_sort_order_custom" formatted="false">Персонализирано подреждане</string>+ <string name="settings_item_version_title" formatted="false">Версия</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Към радиото на песента</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Намерете в „Харесани песни“</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Намерете в плейлиста</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Не можахме да намерим „%1$s“</string>+</resources>diff --git a/base/app/src/main/res/values-bn/spotify_plurals.xml b/base/app/src/main/res/values-bn/spotify_plurals.xmlnew file mode 100644index 00000000..fa6d52c7--- /dev/null+++ b/base/app/src/main/res/values-bn/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$dটি গান</item>+ <item quantity="other">%1$dটি গান</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d বার সেভ করা হয়েছে</item>+ <item quantity="other">%1$,d বার সেভ করা হয়েছে</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s প্লেলিস্ট</item>+ <item quantity="other">%1$s প্লেলিস্ট</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$sটি গান</item>+ <item quantity="other">%1$sটি গান</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-bn/spotify_strings.xml b/base/app/src/main/res/values-bn/spotify_strings.xmlnew file mode 100644index 00000000..b9ceefc5--- /dev/null+++ b/base/app/src/main/res/values-bn/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">পছন্দ করা গান-এ যোগ করুন</string>+ <string name="collection_liked_songs_title" formatted="false">পছন্দ করা গান</string>+ <string name="context_menu_add_to_playlist" formatted="false">প্লেলিস্টে যোগ করুন</string>+ <string name="context_menu_play_next" formatted="false">পরের গান</string>+ <string name="context_menu_add_to_queue" formatted="false">কিউতে যুক্ত করুন</string>+ <string name="context_menu_go_to_queue" formatted="false">কিউতে যান</string>+ <string name="context_menu_browse_album" formatted="false">অ্যালবামে যান</string>+ <string name="context_menu_browse_artist" formatted="false">শিল্পী-তে যান</string>+ <string name="context_menu_share" formatted="false">শেয়ার করুন</string>+ <string name="context_menu_sleep_timer" formatted="false">স্লিপ টাইমার</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">টাইমার বন্ধ করুন</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">ট্র্যাকের সমাপ্তি</string>+ <string name="snackbar_added_to_queue" formatted="false">লিস্টে যোগ করা হয়েছে</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">পছন্দ করা গানগুলিতে যোগ করা হয়েছে।</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">পছন্দসই গানগুলি থেকে সরানো হয়েছে।</string>+ <string name="content_description_context_menu" formatted="false">আরও বিকল্প</string>+ <string name="close_button_content_description" formatted="false">বন্ধ করুন</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">এখানে সেভ করা হয়েছে</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">নতুন প্লেলিস্ট</string>+ <string name="add_to_playlist_button_cancel" formatted="false">বাতিল করুন</string>+ <string name="create_playlist_create_button" formatted="false">তৈরি করুন</string>+ <string name="lyrics_card_title" formatted="false">লিরিক্স</string>+ <string name="lyrics_card_title_preview" formatted="false">লিরিক্সের প্রিভিউ</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">লিরিক্স দেখান</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">সম্পূর্ণ স্ক্রিন সহ লিরিক্স খোলে</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">লিরিক্স শেয়ার করুন</string>+ <string name="lyrics_credential_note" formatted="false">লিরিক্স %1$s দ্বারা সরবরাহ করা</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">শেয়ার করুন</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">অনুবাদ করুন</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">লিরিক্স বন্ধ করুন</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">লিরিক্স অনুবাদ করুন</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">লিরিক্স অনুবাদ করা বন্ধ করুন</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">হুম। আমরা এই গানটির লিরিক জানি না।</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">এই লিরিকগুলি টাইম-সিঙ্কড হয়নি, এখনও।</string>+ <string name="av_switch_to_video" formatted="false">ভিডিওতে সুইচ করুন</string>+ <string name="av_switch_to_audio" formatted="false">অডিওতে সুইচ করুন</string>+ <string name="av_content_desc" formatted="false">অডিও ও ভিডিওর মধ্যে টগল করুন</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">হোম</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">সার্চ করুন</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">আপনার লাইব্রেরি</string>+ <string name="search_header_field_hint" formatted="false">আপনি কী শুনতে চান?</string>+ <string name="filter_chip_all_label" formatted="false">সব</string>+ <string name="recents_content_filter_music" formatted="false">মিউজিক</string>+ <string name="ad_category_title_podcasts" formatted="false">পডকাস্ট</string>+ <string name="audiobooks_title" formatted="false">অডিওবুক</string>+ <string name="artist_popular_tracks" formatted="false">জনপ্রিয়</string>+ <string name="curation_button_follow_state_text" formatted="false">ফলো করুন</string>+ <string name="curation_button_following_state_text" formatted="false">ফলো করছেন</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">শিল্পী</string>+ <string name="connect_phone_is_self" formatted="false">এই ফোনে</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">কোনও গান চলাকালীন ছোট, লুপিং ভিজ্যুয়াল।</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">এখনই না</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">আপডেট করুন</string>+ <string name="context_type_description_play_queue" formatted="false">প্লে কিউ থেকে চলছে</string>+ <string name="context_type_description_collection_your_library" formatted="false">আপনার লাইব্রেরি থেকে চলছে</string>+ <string name="context_type_description_playlist" formatted="false">প্লেলিস্ট থেকে চলছে</string>+ <string name="context_type_description_album" formatted="false">অ্যালবাম থেকে চলছে</string>+ <string name="context_type_description_artist" formatted="false">শিল্পী থেকে চলছে</string>+ <string name="context_type_description_show" formatted="false">পডকাস্ট থেকে চালানো হচ্ছে</string>+ <string name="context_type_description_search" formatted="false">অনুসন্ধান থেকে চলছে</string>+ <string name="default_notification_channel_name" formatted="false">এখন চলছে</string>+ <string name="label_bluetooth" formatted="false">ব্লুটুথ</string>+ <string name="mr_user_route_category_name" formatted="false">ডিভাইস</string>+ <string name="action_share_label" formatted="false">শেয়ার করুন</string>+ <string name="action_queue_label" formatted="false">লিস্ট</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 ঘণ্টা</string>+ <string name="curation_actions_edit_button_title" formatted="false">এডিট করুন</string>+ <string name="content_description_pause_button" formatted="false">পজ করুন</string>+ <string name="content_description_play_button" formatted="false">চালান</string>+ <string name="play_mode_item_shuffle_title" formatted="false">শাফেল</string>+ <string name="np_content_desc_repeat" formatted="false">আবার চালান</string>+ <string name="np_content_desc_sleep_timer" formatted="false">স্লিপ টাইমার</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">সরিয়ে ফেলুন</string>+ <string name="edit_playlist_items_move_chip" formatted="false">সরিয়ে নিয়ে যান</string>+ <string name="bottom_actions_close" formatted="false">বন্ধ করুন</string>+ <string name="add_to_queue_action_content_description" formatted="false">লিস্টে যোগ করুন</string>+ <string name="curation_button_saved_text" formatted="false">সেভ করা হয়েছে</string>+ <string name="np_content_desc_prev" formatted="false">আগের</string>+ <string name="np_content_desc_next" formatted="false">পরবর্তী</string>+ <string name="accessibility_navigate_back" formatted="false">ফিরে যান</string>+ <string name="monthly_listeners_text" formatted="false">%1$s জন মাসিক শ্রোতা</string>+ <string name="profile_bio_show_less" formatted="false">কম দেখুন</string>+ <string name="audiobook_series_see_more_button" formatted="false">আরও দেখুন</string>+ <string name="popular_releases_section_title" formatted="false">জনপ্রিয় রিলিজ</string>+ <string name="creator_biography_section_title" formatted="false">সম্বন্ধে</string>+ <string name="fans_also_like_section_title" formatted="false">ফ্যানরা এটাও পছন্দ করেন</string>+ <string name="appears_on_section_title" formatted="false">এতে পাওয়া যাবে</string>+ <string name="composer_section_button_show_all" formatted="false">সবকটি দেখুন</string>+ <string name="releases_title" formatted="false">রিলিজগুলি</string>+ <string name="artist_releases_albums" formatted="false">অ্যালবাম</string>+ <string name="artist_releases_singles" formatted="false">সিংগল্স এবং ইপি (EPs)</string>+ <string name="latest_release_title" formatted="false">সর্বশেষ রিলিজ</string>+ <string name="artist_subtitle" formatted="false">শিল্পী</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">সাম্প্রতিক অনুসন্ধানগুলি</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">মুছে ফেলুন</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">পডকাস্ট</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">পর্ব</string>+ <string name="assisted_curation_search_song" formatted="false">গান</string>+ <string name="album" formatted="false">অ্যালবাম</string>+ <string name="album_type_podcast" formatted="false">পডকাস্ট</string>+ <string name="recently_played_user_profile" formatted="false">প্রোফাইল</string>+ <string name="connect_device_menu_logout" formatted="false">লগ আউট করুন</string>+ <string name="library_search_text_hint" formatted="false">আপনার লাইব্রেরিতে অনুসন্ধান করুন</string>+ <string name="account_title" formatted="false">অ্যাকাউন্ট</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">শিল্পীকে ফলো করা হয়েছে</string>+ <string name="settings_item_crossfade_title" formatted="false">পর পর চালান</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d সেকেন্ড</string>+ <string name="local_files_title" formatted="false">লোকাল ফাইল</string>+ <string name="local_files_empty_section_title" formatted="false">আপনার নিজের অডিও ফাইল \'আপনার লাইব্রেরি\'-তে যোগ করুন</string>+ <string name="local_files_empty_section_subtitle" formatted="false">এমন কোনও গান বা ব্যক্তিগত পডকাস্ট আছে যা Spotify-তে নেই?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">আপনার অডিও ফাইল এখানে দেখা যাবে</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">অ্যাক্সেস দিন</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">সেটিংস-এ যান</string>+ <string name="context_menu_download" formatted="false">ডাউনলোড করুন</string>+ <string name="context_menu_undownload" formatted="false">ডাউনলোড সরিয়ে ফেলুন</string>+ <string name="collection_downloaded" formatted="false">ডাউনলোড হয়েছে</string>+ <string name="download_badge_downloaded_content_description" formatted="false">ডাউনলোড হয়েছে</string>+ <string name="download_badge_downloading_content_description" formatted="false">ডাউনলোড হচ্ছে</string>+ <string name="download_badge_error_content_description" formatted="false">ডাউনলোড করা যায়নি</string>+ <string name="download_notification_downloading" formatted="false">ডাউনলোড হচ্ছে…</string>+ <string name="toast_undownload" formatted="false">ডাউনলোড সরানো হয়েছে।</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">ডাউনলোডগুলি থেকে সরাবেন?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">আপনি এটি অফলাইন মোডে চালাতে পারবেন না।</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">সরিয়ে ফেলুন</string>+ <string name="settings_item_remove_downloads_title" formatted="false">সমস্ত ডাউনলোড সরান</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">সমস্ত ডাউনলোড সরাবেন?</string>+ <string name="album_type_album" formatted="false">অ্যালবাম</string>+ <string name="album_type_single" formatted="false">সিঙ্গল</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">সংকলন</string>+ <string name="assisted_curation_search_playlist" formatted="false">প্লেলিস্ট</string>+ <string name="assisted_curation_search_filter_top" formatted="false">টপ</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">গান</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">শিল্পী</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">অ্যালবাম</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">প্লেলিস্ট</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">ফিল্টার মুছে দিন</string>+ <string name="ad_category_title_music" formatted="false">মিউজিক</string>+ <string name="made_for_you_hub_title" formatted="false">আপনার জন্য তৈরি</string>+ <string name="settings_item_app_language_title" formatted="false">অ্যাপের ভাষা</string>+ <string name="create_menu_item_folder_title" formatted="false">ফোল্ডার</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">নতুন ফোল্ডার</string>+ <string name="context_menu_rename_folder" formatted="false">ফোল্ডারের নতুন নাম দিন</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">ফোল্ডারের নাম</string>+ <string name="create_playlist_content_description" formatted="false">প্লেলিস্ট তৈরি করুন</string>+ <string name="actions_picker_delete" formatted="false">মুছে ফেলুন</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">ক্রমানুসারে</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">বর্ণানুক্রমিক</string>+ <string name="your_library_sort_order_creator" formatted="false">স্রষ্টা</string>+ <string name="your_library_sort_order_custom" formatted="false">পছন্দ অনুযায়ী বাছাই</string>+ <string name="settings_item_version_title" formatted="false">ভার্সন</string>+ <string name="context_menu_go_to_song_radio" formatted="false">গান রেডিও-তে যান</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">পছন্দ করা গানগুলিতে খুঁজুন</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">প্লেলিস্টগুলিতে খুঁজুন</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\" খুঁজে পাওয়া যায়নি</string>+</resources>diff --git a/base/app/src/main/res/values-bs/spotify_plurals.xml b/base/app/src/main/res/values-bs/spotify_plurals.xmlnew file mode 100644index 00000000..b404c749--- /dev/null+++ b/base/app/src/main/res/values-bs/spotify_plurals.xml@@ -0,0 +1,24 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d pjesma</item>+ <item quantity="few">%1$d pjesme</item>+ <item quantity="other">%1$d pjesama</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d pohranjivanje</item>+ <item quantity="few">%1$,d pohranjivanja</item>+ <item quantity="other">%1$,d pohranjivanja</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s plejlista</item>+ <item quantity="few">%1$s plejliste</item>+ <item quantity="other">%1$s plejlisti</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s pjesma</item>+ <item quantity="few">%1$s pjesme</item>+ <item quantity="other">%1$s pjesama</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-bs/spotify_strings.xml b/base/app/src/main/res/values-bs/spotify_strings.xmlnew file mode 100644index 00000000..8f9196c4--- /dev/null+++ b/base/app/src/main/res/values-bs/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Dodavanje u pjesme označene sa \"Sviđa mi se\"</string>+ <string name="collection_liked_songs_title" formatted="false">Pjesme označene sa \"Sviđa mi se\"</string>+ <string name="context_menu_add_to_playlist" formatted="false">Dodaj na plejlistu</string>+ <string name="context_menu_play_next" formatted="false">Reproduciraj sljedeće</string>+ <string name="context_menu_add_to_queue" formatted="false">Dodavanje u red čekanja</string>+ <string name="context_menu_go_to_queue" formatted="false">Idite u red čekanja</string>+ <string name="context_menu_browse_album" formatted="false">Odlazak na album</string>+ <string name="context_menu_browse_artist" formatted="false">Odlazak na izvođača</string>+ <string name="context_menu_share" formatted="false">Dijeljenje</string>+ <string name="context_menu_sleep_timer" formatted="false">Tajmer za isključivanje</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Isključi tajmer</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Kraj numere</string>+ <string name="snackbar_added_to_queue" formatted="false">Dodano je u red čekanja</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Dodano u pjesme označene sa \"Sviđa mi se\".</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Uklonjeno iz pjesama označenih sa \"Sviđa mi se\".</string>+ <string name="content_description_context_menu" formatted="false">Više opcija</string>+ <string name="close_button_content_description" formatted="false">Zatvaranje</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Sačuvano u odjeljku</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nova plejlista</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Otkaži</string>+ <string name="create_playlist_create_button" formatted="false">Kreirajte</string>+ <string name="lyrics_card_title" formatted="false">Tekst pjesme</string>+ <string name="lyrics_card_title_preview" formatted="false">Pregled teksta pjesme</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Prikaži tekst pjesme</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Otvaranje teksta pjesme preko cijelog ekrana</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Dijeljenje teksta pjesme</string>+ <string name="lyrics_credential_note" formatted="false">Tekst pjesme pruža: %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Podijeli</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Prevedi</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Zatvaranje teksta pjesme</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Prevođenje teksta pjesme</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Prestanak prevođenja teksta pjesme</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hm. Ne znamo tekst ove pjesme.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Tekst pjesme nije vremenski sinhroniziran, zasad.</string>+ <string name="av_switch_to_video" formatted="false">Prebaci na videozapis</string>+ <string name="av_switch_to_audio" formatted="false">Prebaci na zvuk</string>+ <string name="av_content_desc" formatted="false">Prebacivanje između zvuka i videozapisa</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Početna stranica</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Pretražite</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Vaša biblioteka</string>+ <string name="search_header_field_hint" formatted="false">Šta želite slušati?</string>+ <string name="filter_chip_all_label" formatted="false">Sve</string>+ <string name="recents_content_filter_music" formatted="false">Muzika</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasti</string>+ <string name="audiobooks_title" formatted="false">Audio knjige</string>+ <string name="artist_popular_tracks" formatted="false">Popularno</string>+ <string name="curation_button_follow_state_text" formatted="false">Pratite</string>+ <string name="curation_button_following_state_text" formatted="false">Već pratite</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Izvođač</string>+ <string name="connect_phone_is_self" formatted="false">Ovaj telefon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Kratki, ponavljajući vizuelni elementi kada se pjesma reproducira.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Ne sada</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Ažuriraj</string>+ <string name="context_type_description_play_queue" formatted="false">Reproduciranje iz reda čekanja za reprodukciju</string>+ <string name="context_type_description_collection_your_library" formatted="false">Reproduciranje iz vaše biblioteke</string>+ <string name="context_type_description_playlist" formatted="false">Reproduciranje s plejliste</string>+ <string name="context_type_description_album" formatted="false">Reproduciranje iz albuma</string>+ <string name="context_type_description_artist" formatted="false">Reproduciranje izvođača</string>+ <string name="context_type_description_show" formatted="false">Reproduciranje iz podcasta</string>+ <string name="context_type_description_search" formatted="false">Reproduciranje iz Pretraživanja</string>+ <string name="default_notification_channel_name" formatted="false">Trenutno se reproducira</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Uređaji</string>+ <string name="action_share_label" formatted="false">Dijeljenje</string>+ <string name="action_queue_label" formatted="false">Dodaj u red čekanja</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 sat</string>+ <string name="curation_actions_edit_button_title" formatted="false">Uredite</string>+ <string name="content_description_pause_button" formatted="false">Pauziranje</string>+ <string name="content_description_play_button" formatted="false">Reprodukcija</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Nasumična reprodukcija</string>+ <string name="np_content_desc_repeat" formatted="false">Ponavljanje</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Tajmer za isključivanje</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Uklanjanje</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Premjesti</string>+ <string name="bottom_actions_close" formatted="false">Zatvaranje</string>+ <string name="add_to_queue_action_content_description" formatted="false">Dodaj u red čekanja</string>+ <string name="curation_button_saved_text" formatted="false">Sačuvano</string>+ <string name="np_content_desc_prev" formatted="false">Prethodno</string>+ <string name="np_content_desc_next" formatted="false">Sljedeće</string>+ <string name="accessibility_navigate_back" formatted="false">Nazad</string>+ <string name="monthly_listeners_text" formatted="false">Broj mjesečnih slušalaca: %1$s</string>+ <string name="profile_bio_show_less" formatted="false">Prikaži manje</string>+ <string name="audiobook_series_see_more_button" formatted="false">Prikaži više</string>+ <string name="popular_releases_section_title" formatted="false">Popularna izdanja</string>+ <string name="creator_biography_section_title" formatted="false">Informacije</string>+ <string name="fans_also_like_section_title" formatted="false">Obožavaocima se također sviđa</string>+ <string name="appears_on_section_title" formatted="false">Pojavljuje se na</string>+ <string name="composer_section_button_show_all" formatted="false">Prikaži sve</string>+ <string name="releases_title" formatted="false">Izdanja</string>+ <string name="artist_releases_albums" formatted="false">Albumi</string>+ <string name="artist_releases_singles" formatted="false">Singlovi i EP-ovi</string>+ <string name="latest_release_title" formatted="false">Posljednje izdanje</string>+ <string name="artist_subtitle" formatted="false">Izvođač</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Nedavna pretraživanja</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Očisti</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasti</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Epizode</string>+ <string name="assisted_curation_search_song" formatted="false">Pjesma</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Odjava</string>+ <string name="library_search_text_hint" formatted="false">Pretraživanje Vaše biblioteke</string>+ <string name="account_title" formatted="false">Račun</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Praćeni izvođači</string>+ <string name="settings_item_crossfade_title" formatted="false">Unakrsno utišavanje i pojačavanje</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Lokalni fajovi</string>+ <string name="local_files_empty_section_title" formatted="false">Dodajte audio fajlove u odjeljak Vaša biblioteka</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Imate pjesmu ili lični podcast koji nisu na Spotifyu?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Audio fajlovi će se prikazivati ovdje</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Dozvoli pristup</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Idite na Postavke</string>+ <string name="context_menu_download" formatted="false">Preuzmi</string>+ <string name="context_menu_undownload" formatted="false">Uklanjanje preuzimanja</string>+ <string name="collection_downloaded" formatted="false">Preuzeto</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Preuzeto</string>+ <string name="download_badge_downloading_content_description" formatted="false">Preuzimanje</string>+ <string name="download_badge_error_content_description" formatted="false">Preuzimanje nije uspjelo</string>+ <string name="download_notification_downloading" formatted="false">Preuzimanje…</string>+ <string name="toast_undownload" formatted="false">Preuzimanje je uklonjeno.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Ukloniti iz preuzimanja?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Ovo nećete moći reproducirati offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Ukloni</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Ukloni sva preuzimanja</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Ukloniti sva preuzimanja?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Singl</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Kompilacija</string>+ <string name="assisted_curation_search_playlist" formatted="false">Plejlista</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Najbolji rezultati</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Pjesme</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Izvođači</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albumi</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Plejliste</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Brisanje filtera</string>+ <string name="ad_category_title_music" formatted="false">Muzika</string>+ <string name="made_for_you_hub_title" formatted="false">Napravljeno za vas</string>+ <string name="settings_item_app_language_title" formatted="false">Jezik aplikacije</string>+ <string name="create_menu_item_folder_title" formatted="false">Folder</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Novi folder</string>+ <string name="context_menu_rename_folder" formatted="false">Preimenovanje foldera</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Naziv foldera</string>+ <string name="create_playlist_content_description" formatted="false">Kreiranje plejliste</string>+ <string name="actions_picker_delete" formatted="false">Izbriši</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sortiraj prema</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Abecedno</string>+ <string name="your_library_sort_order_creator" formatted="false">Kreator</string>+ <string name="your_library_sort_order_custom" formatted="false">Prilagođeni redoslijed</string>+ <string name="settings_item_version_title" formatted="false">Verzija</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Odlazak na radio prema pjesmi</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Pronađite u pjesmama označenim sa \"Sviđa mi se\"</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Pronađite na plejlisti</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Pronalaženje stavke \"%1$s\" nije uspjelo</string>+</resources>diff --git a/base/app/src/main/res/values-ca/spotify_plurals.xml b/base/app/src/main/res/values-ca/spotify_plurals.xmlnew file mode 100644index 00000000..7da16692--- /dev/null+++ b/base/app/src/main/res/values-ca/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d cançó</item>+ <item quantity="other">%1$d cançons</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">Desada %1$,d vegada</item>+ <item quantity="other">Desada %1$,d vegades</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s llista</item>+ <item quantity="other">%1$s llistes</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s cançó</item>+ <item quantity="other">%1$s cançons</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ca/spotify_strings.xml b/base/app/src/main/res/values-ca/spotify_strings.xmlnew file mode 100644index 00000000..3a48edce--- /dev/null+++ b/base/app/src/main/res/values-ca/spotify_strings.xml@@ -0,0 +1,157 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Afegeix a Cançons que m\'agraden</string>+ <string name="context_menu_add_to_playlist" formatted="false">Afegeix a una llista</string>+ <string name="context_menu_play_next" formatted="false">Reprodueix a continuació</string>+ <string name="context_menu_add_to_queue" formatted="false">Afegeix a la cua</string>+ <string name="context_menu_go_to_queue" formatted="false">Ves a la cua</string>+ <string name="context_menu_browse_album" formatted="false">Ves a l\'àlbum</string>+ <string name="context_menu_browse_artist" formatted="false">Ves a l\'artista</string>+ <string name="context_menu_share" formatted="false">Comparteix</string>+ <string name="context_menu_sleep_timer" formatted="false">Apagada automàtica</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Final de la cançó</string>+ <string name="snackbar_added_to_queue" formatted="false">S\'ha afegit a la cua.</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">S\'ha afegit a Cançons que m\'agraden.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">S\'ha tret de Cançons que m\'agraden.</string>+ <string name="content_description_context_menu" formatted="false">Més opcions</string>+ <string name="close_button_content_description" formatted="false">Tanca</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Desat a</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nova llista</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Cancel·la</string>+ <string name="create_playlist_create_button" formatted="false">Crea</string>+ <string name="lyrics_card_title" formatted="false">Lletra</string>+ <string name="lyrics_card_title_preview" formatted="false">Previsualització de la lletra</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Mostra la lletra</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Obre la lletra a pantalla completa</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Comparteix les lletres</string>+ <string name="lyrics_credential_note" formatted="false">Lletra proporcionada per %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Comparteix</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Tradueix</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Tancar la lletra</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Tradueix la lletra</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Parar de traduir la lletra</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Vaja, no sabem la lletra d\'aquesta cançó.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Aquesta lletra encara no està sincronitzada.</string>+ <string name="av_switch_to_video" formatted="false">Canvia a vídeo</string>+ <string name="av_switch_to_audio" formatted="false">Canvia a àudio</string>+ <string name="av_content_desc" formatted="false">Canvia entre àudio i vídeo</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Inici</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Cerca</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">La teva biblioteca</string>+ <string name="search_header_field_hint" formatted="false">Què vols escoltar?</string>+ <string name="filter_chip_all_label" formatted="false">Tot</string>+ <string name="recents_content_filter_music" formatted="false">Música</string>+ <string name="ad_category_title_podcasts" formatted="false">Pòdcasts</string>+ <string name="audiobooks_title" formatted="false">Audiollibres</string>+ <string name="artist_popular_tracks" formatted="false">Popular</string>+ <string name="curation_button_follow_state_text" formatted="false">Segueix</string>+ <string name="curation_button_following_state_text" formatted="false">Seguint</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artista</string>+ <string name="connect_phone_is_self" formatted="false">Aquest telèfon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Elements visuals curts i en bucle mentre sona una cançó.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Ara no</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Actualitza</string>+ <string name="context_type_description_play_queue" formatted="false">S\'està reproduint des de la cua</string>+ <string name="context_type_description_collection_your_library" formatted="false">S\'està reproduint des de La teva biblioteca</string>+ <string name="context_type_description_playlist" formatted="false">S\'està reproduint des de la llista</string>+ <string name="context_type_description_album" formatted="false">S\'està reproduint des de l\'àlbum</string>+ <string name="context_type_description_artist" formatted="false">S\'està reproduint des de l\'artista</string>+ <string name="context_type_description_show" formatted="false">S\'està reproduint des del pòdcast</string>+ <string name="context_type_description_search" formatted="false">S\'està reproduint des de la cerca</string>+ <string name="default_notification_channel_name" formatted="false">S\'està reproduint</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Dispositius</string>+ <string name="action_share_label" formatted="false">Comparteix</string>+ <string name="action_queue_label" formatted="false">Cua</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 hora</string>+ <string name="curation_actions_edit_button_title" formatted="false">Edita</string>+ <string name="content_description_pause_button" formatted="false">Posa en pausa</string>+ <string name="content_description_play_button" formatted="false">Reprodueix</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Aleatori</string>+ <string name="np_content_desc_repeat" formatted="false">Repeteix</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Apagada automàtica</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Treu</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Mou</string>+ <string name="bottom_actions_close" formatted="false">Tanca</string>+ <string name="add_to_queue_action_content_description" formatted="false">Afegeix a la cua</string>+ <string name="curation_button_saved_text" formatted="false">Desat</string>+ <string name="np_content_desc_prev" formatted="false">Anterior</string>+ <string name="np_content_desc_next" formatted="false">Següent</string>+ <string name="accessibility_navigate_back" formatted="false">Enrere</string>+ <string name="monthly_listeners_text" formatted="false">%1$s oients mensuals</string>+ <string name="profile_bio_show_less" formatted="false">Mostra\'n menys</string>+ <string name="audiobook_series_see_more_button" formatted="false">Mostra\'n més</string>+ <string name="popular_releases_section_title" formatted="false">Novetats populars</string>+ <string name="creator_biography_section_title" formatted="false">Informació</string>+ <string name="fans_also_like_section_title" formatted="false">Als fans també els agrada</string>+ <string name="appears_on_section_title" formatted="false">Apareix a</string>+ <string name="composer_section_button_show_all" formatted="false">Mostra-ho tot</string>+ <string name="releases_title" formatted="false">Novetats</string>+ <string name="artist_releases_albums" formatted="false">Àlbums</string>+ <string name="artist_releases_singles" formatted="false">Singles i EP</string>+ <string name="latest_release_title" formatted="false">Darrer llançament</string>+ <string name="artist_subtitle" formatted="false">Artista</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Cerques recents</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Esborra</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Pòdcasts</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episodis</string>+ <string name="assisted_curation_search_song" formatted="false">Cançó</string>+ <string name="album" formatted="false">Àlbum</string>+ <string name="album_type_podcast" formatted="false">Pòdcast</string>+ <string name="recently_played_user_profile" formatted="false">Perfil</string>+ <string name="connect_device_menu_logout" formatted="false">Tanca la sessió</string>+ <string name="library_search_text_hint" formatted="false">Cerca a La teva biblioteca</string>+ <string name="account_title" formatted="false">Compte</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Artistes que segueixes</string>+ <string name="settings_item_crossfade_title" formatted="false">Fosa encadenada</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_empty_section_title" formatted="false">Afegeix els teus propis fitxers d\'àudio a La teva biblioteca</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Tens una cançó o un pòdcast personal que no és a Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Els teus fitxers d\'àudio es mostraran aquí</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Permet l\'accés</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Ves a Configuració</string>+ <string name="context_menu_download" formatted="false">Descarrega</string>+ <string name="context_menu_undownload" formatted="false">Treu la descàrrega</string>+ <string name="collection_downloaded" formatted="false">Descarregat</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Descarregat</string>+ <string name="download_badge_downloading_content_description" formatted="false">S\'està descarregant</string>+ <string name="download_badge_error_content_description" formatted="false">Error de descàrrega</string>+ <string name="download_notification_downloading" formatted="false">S\'està descarregant…</string>+ <string name="toast_undownload" formatted="false">S\'ha tret la descàrrega.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Vols treure-ho de Descàrregues?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">No podràs reproduir-la sense connexió.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Treu</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Treu totes les descàrregues</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Vols treure totes les descàrregues?</string>+ <string name="album_type_album" formatted="false">Àlbum</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Recopilatori</string>+ <string name="assisted_curation_search_playlist" formatted="false">Llista</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Top</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Cançons</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artistes</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Àlbums</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Llistes</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Esborra el filtre</string>+ <string name="ad_category_title_music" formatted="false">Música</string>+ <string name="made_for_you_hub_title" formatted="false">Especialment per a tu</string>+ <string name="settings_item_app_language_title" formatted="false">Idioma de l\'aplicació</string>+ <string name="create_menu_item_folder_title" formatted="false">Carpeta</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Carpeta nova</string>+ <string name="context_menu_rename_folder" formatted="false">Canvia el nom de la carpeta</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Nom de la carpeta</string>+ <string name="create_playlist_content_description" formatted="false">Crea una llista</string>+ <string name="actions_picker_delete" formatted="false">Suprimeix</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Ordena per</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Ordre alfabètic</string>+ <string name="your_library_sort_order_creator" formatted="false">Creador</string>+ <string name="your_library_sort_order_custom" formatted="false">Ordre personalitzat</string>+ <string name="settings_item_version_title" formatted="false">Versió</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Ves a la ràdio de la cançó</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Cerca a Cançons que m\'agraden</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Fes una cerca a la llista</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">No s\'ha pogut trobar \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-cs/spotify_plurals.xml b/base/app/src/main/res/values-cs/spotify_plurals.xmlnew file mode 100644index 00000000..48efa8ff--- /dev/null+++ b/base/app/src/main/res/values-cs/spotify_plurals.xml@@ -0,0 +1,24 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d skladba</item>+ <item quantity="few">%1$d skladby</item>+ <item quantity="other">%1$d skladeb</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d uložení</item>+ <item quantity="few">%1$,d uložení</item>+ <item quantity="other">%1$,d uložení</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="few">%1$s playlisty</item>+ <item quantity="other">%1$s playlistů</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s skladba</item>+ <item quantity="few">%1$s skladby</item>+ <item quantity="other">%1$s skladeb</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-cs/spotify_strings.xml b/base/app/src/main/res/values-cs/spotify_strings.xmlnew file mode 100644index 00000000..e4bcde6c--- /dev/null+++ b/base/app/src/main/res/values-cs/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Přidat k oblíbeným skladbám</string>+ <string name="collection_liked_songs_title" formatted="false">Skladby, které se ti líbí</string>+ <string name="context_menu_add_to_playlist" formatted="false">Přidat do playlistu</string>+ <string name="context_menu_play_next" formatted="false">Přehrát jako další</string>+ <string name="context_menu_add_to_queue" formatted="false">Přidat do fronty</string>+ <string name="context_menu_go_to_queue" formatted="false">Přejít do fronty</string>+ <string name="context_menu_browse_album" formatted="false">Přejít na album</string>+ <string name="context_menu_browse_artist" formatted="false">Přejít na umělce</string>+ <string name="context_menu_share" formatted="false">Sdílet</string>+ <string name="context_menu_sleep_timer" formatted="false">Časovač vypnutí</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Vypnout časovač</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Konec nahrávky</string>+ <string name="snackbar_added_to_queue" formatted="false">Přidáno do fronty</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Přidáno ke skladbám, které se ti líbí.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Odstraněno ze sbírky Skladby, které se ti líbí.</string>+ <string name="content_description_context_menu" formatted="false">Více možností</string>+ <string name="close_button_content_description" formatted="false">Zavřít</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Uloženo v </string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nový playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Zrušit</string>+ <string name="create_playlist_create_button" formatted="false">Vytvořit</string>+ <string name="lyrics_card_title" formatted="false">Text skladby</string>+ <string name="lyrics_card_title_preview" formatted="false">Náhled textu</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Zobrazit text</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Otevřít text na celou obrazovku</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Sdílej text skladby</string>+ <string name="lyrics_credential_note" formatted="false">Text ti přináší %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Sdílet</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Přeložit</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Zavřít text</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Překládat texty</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">se texty přestanou překládat</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. K tomu text neznáme.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Tenhle text zatím není synchronizovaný se zvukem.</string>+ <string name="av_switch_to_video" formatted="false">Přepnout na video</string>+ <string name="av_switch_to_audio" formatted="false">Přepnout na zvuk</string>+ <string name="av_content_desc" formatted="false">Přepnout mezi zvukem a videem</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Domů</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Hledat</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Tvoje knihovna</string>+ <string name="search_header_field_hint" formatted="false">Co si chceš poslechnout?</string>+ <string name="filter_chip_all_label" formatted="false">Vše</string>+ <string name="recents_content_filter_music" formatted="false">Hudba</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasty</string>+ <string name="audiobooks_title" formatted="false">Audioknihy</string>+ <string name="artist_popular_tracks" formatted="false">Oblíbené</string>+ <string name="curation_button_follow_state_text" formatted="false">Sledovat</string>+ <string name="curation_button_following_state_text" formatted="false">Sleduješ</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Umělec</string>+ <string name="connect_phone_is_self" formatted="false">Tento telefon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Krátké videosmyčky při přehrávání skladby.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Možná později</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Aktualizovat</string>+ <string name="context_type_description_play_queue" formatted="false">Přehrávání z fronty</string>+ <string name="context_type_description_collection_your_library" formatted="false">Přehrávání ze sbírky Tvoje knihovna</string>+ <string name="context_type_description_playlist" formatted="false">Přehrávání z playlistu</string>+ <string name="context_type_description_album" formatted="false">Přehrávání z alba</string>+ <string name="context_type_description_artist" formatted="false">Přehrávání od umělce</string>+ <string name="context_type_description_show" formatted="false">Přehrávání z podcastu</string>+ <string name="context_type_description_search" formatted="false">Přehrávání z vyhledávání</string>+ <string name="default_notification_channel_name" formatted="false">Přehrává se</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Zařízení</string>+ <string name="action_share_label" formatted="false">Sdílet</string>+ <string name="action_queue_label" formatted="false">Fronta</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 hodina</string>+ <string name="curation_actions_edit_button_title" formatted="false">Upravit</string>+ <string name="content_description_pause_button" formatted="false">Pozastavit</string>+ <string name="content_description_play_button" formatted="false">Přehrát</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Náhodné přehrávání</string>+ <string name="np_content_desc_repeat" formatted="false">Opakovat</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Časovač vypnutí</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Odebrat</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Přesunout</string>+ <string name="bottom_actions_close" formatted="false">Zavřít</string>+ <string name="add_to_queue_action_content_description" formatted="false">Přidat do fronty</string>+ <string name="curation_button_saved_text" formatted="false">Uloženo</string>+ <string name="np_content_desc_prev" formatted="false">Předchozí</string>+ <string name="np_content_desc_next" formatted="false">Další</string>+ <string name="accessibility_navigate_back" formatted="false">Zpět</string>+ <string name="monthly_listeners_text" formatted="false">%1$s posluchačů měsíčně</string>+ <string name="profile_bio_show_less" formatted="false">Zobrazit méně</string>+ <string name="audiobook_series_see_more_button" formatted="false">Zobrazit víc</string>+ <string name="popular_releases_section_title" formatted="false">Populární vydání</string>+ <string name="creator_biography_section_title" formatted="false">Víc informací</string>+ <string name="fans_also_like_section_title" formatted="false">Fanouškům se dál líbí</string>+ <string name="appears_on_section_title" formatted="false">Také na těchto albech</string>+ <string name="composer_section_button_show_all" formatted="false">Zobrazit vše</string>+ <string name="releases_title" formatted="false">Vydání</string>+ <string name="artist_releases_albums" formatted="false">Alba</string>+ <string name="artist_releases_singles" formatted="false">Singly a EP</string>+ <string name="latest_release_title" formatted="false">Poslední vydané</string>+ <string name="artist_subtitle" formatted="false">Umělec</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Nedávná hledání</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Vymazat</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasty</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Epizody</string>+ <string name="assisted_curation_search_song" formatted="false">Skladba</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Odhlásit</string>+ <string name="library_search_text_hint" formatted="false">Hledat ve sbírce Tvoje knihovna</string>+ <string name="account_title" formatted="false">Účet</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Sledovaní umělci</string>+ <string name="settings_item_crossfade_title" formatted="false">Prolínání</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Místní soubory</string>+ <string name="local_files_empty_section_title" formatted="false">Přidej si do sbírky Tvoje knihovna vlastní zvukové soubory</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Máš skladbu nebo osobní podcast, které nejsou ve Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Tvoje zvukové soubory se zobrazí tady</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Povolit přístup</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Přejít do nastavení</string>+ <string name="context_menu_download" formatted="false">Stáhnout</string>+ <string name="context_menu_undownload" formatted="false">Odebrat stažené</string>+ <string name="collection_downloaded" formatted="false">Staženo</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Staženo</string>+ <string name="download_badge_downloading_content_description" formatted="false">Probíhá stahování</string>+ <string name="download_badge_error_content_description" formatted="false">Stahování se nezdařilo</string>+ <string name="download_notification_downloading" formatted="false">Probíhá stahování…</string>+ <string name="toast_undownload" formatted="false">Stažené položky odstraněny.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Odebrat ze složky Stažené?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Tento obsah už nebudeš moct poslouchat offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Odebrat</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Odebrat všechny stažené skladby</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Odebrat všechny stažené skladby?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Singl</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Kompilace</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Nejlepší</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Skladby</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Umělci</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Alba</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlisty</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Vymazat filtr</string>+ <string name="ad_category_title_music" formatted="false">Hudba</string>+ <string name="made_for_you_hub_title" formatted="false">Vytvořeno pro tebe</string>+ <string name="settings_item_app_language_title" formatted="false">Jazyk aplikace</string>+ <string name="create_menu_item_folder_title" formatted="false">Složka</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nová složka</string>+ <string name="context_menu_rename_folder" formatted="false">Přejmenovat složku</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Název složky</string>+ <string name="create_playlist_content_description" formatted="false">Vytvořit playlist</string>+ <string name="actions_picker_delete" formatted="false">Smazat</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Řadit podle</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Podle abecedy</string>+ <string name="your_library_sort_order_creator" formatted="false">Podle tvůrce</string>+ <string name="your_library_sort_order_custom" formatted="false">Vlastní řazení</string>+ <string name="settings_item_version_title" formatted="false">Verze</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Přejít na rádio skladby</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Najít mezi oblíbenými skladbami</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Najít v playlistu</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Bohužel jsme nenašli: „%1$s“</string>+</resources>diff --git a/base/app/src/main/res/values-da/spotify_plurals.xml b/base/app/src/main/res/values-da/spotify_plurals.xmlnew file mode 100644index 00000000..6edf9e35--- /dev/null+++ b/base/app/src/main/res/values-da/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d sang</item>+ <item quantity="other">%1$d sange</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">Gemt %1$,d gang</item>+ <item quantity="other">Gemt %1$,d gange</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playliste</item>+ <item quantity="other">%1$s playlister</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s sang</item>+ <item quantity="other">%1$s sange</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-da/spotify_strings.xml b/base/app/src/main/res/values-da/spotify_strings.xmlnew file mode 100644index 00000000..c1e2aa74--- /dev/null+++ b/base/app/src/main/res/values-da/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Føj til Sange, du synes godt om</string>+ <string name="collection_liked_songs_title" formatted="false">Sange, du synes godt om</string>+ <string name="context_menu_add_to_playlist" formatted="false">Føj til playliste</string>+ <string name="context_menu_play_next" formatted="false">Afspil som næste</string>+ <string name="context_menu_add_to_queue" formatted="false">Føj til kø</string>+ <string name="context_menu_go_to_queue" formatted="false">Gå til kø</string>+ <string name="context_menu_browse_album" formatted="false">Gå til album</string>+ <string name="context_menu_browse_artist" formatted="false">Gå til kunstner</string>+ <string name="context_menu_share" formatted="false">Del</string>+ <string name="context_menu_sleep_timer" formatted="false">Sleep-timer</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Slå timer fra</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Når nummeret er slut</string>+ <string name="snackbar_added_to_queue" formatted="false">Føjet til kø</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Tilføjet til Sange, du synes godt om.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Fjernet fra Sange, du synes godt om.</string>+ <string name="content_description_context_menu" formatted="false">Flere indstillinger</string>+ <string name="close_button_content_description" formatted="false">Luk</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Gemt i</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Ny playliste</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Annuller</string>+ <string name="create_playlist_create_button" formatted="false">Opret</string>+ <string name="lyrics_card_title" formatted="false">Sangtekster</string>+ <string name="lyrics_card_title_preview" formatted="false">Forsmag på sangtekst</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Vis sangteksten</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Åbn sangteksten i fuld skærm</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Del sangtekster</string>+ <string name="lyrics_credential_note" formatted="false">Sangtekster leveret af %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Del</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Oversæt</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">lukke sangteksten</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Oversæt sangtekst</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">stoppe med at oversætte sangteksten</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Vi kender ikke sangteksten til denne her.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Disse sangtekster er ikke blevet synkroniseret endnu.</string>+ <string name="av_switch_to_video" formatted="false">Skift til video</string>+ <string name="av_switch_to_audio" formatted="false">Skift til lyd</string>+ <string name="av_content_desc" formatted="false">Skift mellem lyd og video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Hjem</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Søg</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Dit bibliotek</string>+ <string name="search_header_field_hint" formatted="false">Hvad vil du lytte til?</string>+ <string name="filter_chip_all_label" formatted="false">Alle</string>+ <string name="recents_content_filter_music" formatted="false">Musik</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasts</string>+ <string name="audiobooks_title" formatted="false">Lydbøger</string>+ <string name="artist_popular_tracks" formatted="false">Populær</string>+ <string name="curation_button_follow_state_text" formatted="false">Følg</string>+ <string name="curation_button_following_state_text" formatted="false">Følger</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Kunstner</string>+ <string name="connect_phone_is_self" formatted="false">Denne telefon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Korte, visuelle effekter, der vises, når en sang afspilles.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Ikke nu</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Opdater</string>+ <string name="context_type_description_play_queue" formatted="false">Afspiller fra Afspilningskø</string>+ <string name="context_type_description_collection_your_library" formatted="false">Afspiller fra Dit bibliotek</string>+ <string name="context_type_description_playlist" formatted="false">Afspiller fra Playliste</string>+ <string name="context_type_description_album" formatted="false">Afspiller fra Album</string>+ <string name="context_type_description_artist" formatted="false">Afspiller fra Kunstner</string>+ <string name="context_type_description_show" formatted="false">Afspiller fra podcast</string>+ <string name="context_type_description_search" formatted="false">Afspiller fra Søg</string>+ <string name="default_notification_channel_name" formatted="false">Afspilles nu</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Enheder</string>+ <string name="action_share_label" formatted="false">Del</string>+ <string name="action_queue_label" formatted="false">Føj til kø</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 time</string>+ <string name="curation_actions_edit_button_title" formatted="false">Rediger</string>+ <string name="content_description_pause_button" formatted="false">Pause</string>+ <string name="content_description_play_button" formatted="false">Afspil</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Shuffle</string>+ <string name="np_content_desc_repeat" formatted="false">Gentag</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Sleep-timer</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Fjern</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Flyt</string>+ <string name="bottom_actions_close" formatted="false">Luk</string>+ <string name="add_to_queue_action_content_description" formatted="false">Føj til kø</string>+ <string name="curation_button_saved_text" formatted="false">Gemt</string>+ <string name="np_content_desc_prev" formatted="false">Tilbage</string>+ <string name="np_content_desc_next" formatted="false">Næste</string>+ <string name="accessibility_navigate_back" formatted="false">Tilbage</string>+ <string name="monthly_listeners_text" formatted="false">%1$s månedlige lyttere</string>+ <string name="profile_bio_show_less" formatted="false">Vis mindre</string>+ <string name="audiobook_series_see_more_button" formatted="false">Vis mere</string>+ <string name="popular_releases_section_title" formatted="false">Populære udgivelser</string>+ <string name="creator_biography_section_title" formatted="false">Om</string>+ <string name="fans_also_like_section_title" formatted="false">Fans synes også godt om</string>+ <string name="appears_on_section_title" formatted="false">Optræder på</string>+ <string name="composer_section_button_show_all" formatted="false">Vis alle</string>+ <string name="releases_title" formatted="false">Udgivelser</string>+ <string name="artist_releases_albums" formatted="false">Album</string>+ <string name="artist_releases_singles" formatted="false">Singler og EP\'er</string>+ <string name="latest_release_title" formatted="false">Seneste udgivelse</string>+ <string name="artist_subtitle" formatted="false">Kunstner</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Seneste søgninger</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Ryd</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasts</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episoder</string>+ <string name="assisted_curation_search_song" formatted="false">Sang</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Log af</string>+ <string name="library_search_text_hint" formatted="false">Søg i Dit bibliotek</string>+ <string name="account_title" formatted="false">Konto</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Kunstnere, du følger</string>+ <string name="settings_item_crossfade_title" formatted="false">Crossfade</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d sek.</string>+ <string name="local_files_title" formatted="false">Lokale filer</string>+ <string name="local_files_empty_section_title" formatted="false">Føj dine egne lydfiler til Dit bibliotek</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Har du en sang eller personlig podcast, som ikke er tilgængelig på Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Dine lydfiler vises her</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Giv adgang</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Gå til Indstillinger</string>+ <string name="context_menu_download" formatted="false">Download</string>+ <string name="context_menu_undownload" formatted="false">Fjern download</string>+ <string name="collection_downloaded" formatted="false">Downloadet</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Downloadet</string>+ <string name="download_badge_downloading_content_description" formatted="false">Downloader</string>+ <string name="download_badge_error_content_description" formatted="false">Download mislykkedes</string>+ <string name="download_notification_downloading" formatted="false">Downloader…</string>+ <string name="toast_undownload" formatted="false">Downloadet blev fjernet.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Vil du fjerne dette fra downloads?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Du kan ikke afspille dette offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Fjern</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Fjern alle downloads</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Vil du fjerne alle downloads?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Opsamling</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playliste</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Populært</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Sange</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Kunstnere</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Album</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlister</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Ryd filteret</string>+ <string name="ad_category_title_music" formatted="false">Musik</string>+ <string name="made_for_you_hub_title" formatted="false">Specielt til dig</string>+ <string name="settings_item_app_language_title" formatted="false">Appens sprog</string>+ <string name="create_menu_item_folder_title" formatted="false">Mappe</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Ny mappe</string>+ <string name="context_menu_rename_folder" formatted="false">Omdøb mappe</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Mappenavn</string>+ <string name="create_playlist_content_description" formatted="false">Opret playliste</string>+ <string name="actions_picker_delete" formatted="false">Slet</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sortér efter</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alfabetisk</string>+ <string name="your_library_sort_order_creator" formatted="false">Udgiver</string>+ <string name="your_library_sort_order_custom" formatted="false">Brugerdefineret rækkefølge</string>+ <string name="settings_item_version_title" formatted="false">Version</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Gå til sangradio</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Find i Sange, du synes godt om</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Find på playliste</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Kunne ikke finde \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-de/spotify_plurals.xml b/base/app/src/main/res/values-de/spotify_plurals.xmlnew file mode 100644index 00000000..f710dae8--- /dev/null+++ b/base/app/src/main/res/values-de/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d Song</item>+ <item quantity="other">%1$d Songs</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d Save</item>+ <item quantity="other">%1$,d Saves</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s Playlist</item>+ <item quantity="other">%1$s Playlists</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s Song</item>+ <item quantity="other">%1$s Songs</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-de/spotify_strings.xml b/base/app/src/main/res/values-de/spotify_strings.xmlnew file mode 100644index 00000000..796faa7d--- /dev/null+++ b/base/app/src/main/res/values-de/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Zu Lieblingssongs hinzufügen</string>+ <string name="collection_liked_songs_title" formatted="false">Lieblingssongs</string>+ <string name="context_menu_add_to_playlist" formatted="false">Zu Playlist hinzufügen</string>+ <string name="context_menu_play_next" formatted="false">Als Nächstes spielen</string>+ <string name="context_menu_add_to_queue" formatted="false">In die Warteschlange</string>+ <string name="context_menu_go_to_queue" formatted="false">Zur Warteschlange</string>+ <string name="context_menu_browse_album" formatted="false">Album anzeigen</string>+ <string name="context_menu_browse_artist" formatted="false">Künstler*in aufrufen</string>+ <string name="context_menu_share" formatted="false">Teilen</string>+ <string name="context_menu_sleep_timer" formatted="false">Sleeptimer</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Timer ausschalten</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Nach Ende des Songs</string>+ <string name="snackbar_added_to_queue" formatted="false">Zur Warteschlange hinzugefügt</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Zu „Lieblingssongs“ hinzugefügt</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Aus „Lieblingssongs“ entfernt</string>+ <string name="content_description_context_menu" formatted="false">Weitere Optionen</string>+ <string name="close_button_content_description" formatted="false">Schließen</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Gespeichert in</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Neue Playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Abbrechen</string>+ <string name="create_playlist_create_button" formatted="false">Erstellen</string>+ <string name="lyrics_card_title" formatted="false">Songtexte</string>+ <string name="lyrics_card_title_preview" formatted="false">Vorschau der Lyrics</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Lyrics anzeigen</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Lyrics im Vollbild öffnen</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Lyrics teilen</string>+ <string name="lyrics_credential_note" formatted="false">Songtext bereitgestellt von %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Teilen</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Übersetzen</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Lyrics schließen</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Lyrics übersetzen</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Lyrics nicht mehr übersetzen</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Wir kennen den Text zu diesem Song leider nicht.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Dieser Songtext ist noch nicht auf die Musik abgestimmt.</string>+ <string name="av_switch_to_video" formatted="false">Zu Video wechseln</string>+ <string name="av_switch_to_audio" formatted="false">Zu Audio wechseln</string>+ <string name="av_content_desc" formatted="false">Zwischen Audio und Video umschalten</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Start</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Suchen</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Bibliothek</string>+ <string name="search_header_field_hint" formatted="false">Was möchtest du hören?</string>+ <string name="filter_chip_all_label" formatted="false">Alle</string>+ <string name="recents_content_filter_music" formatted="false">Musik</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasts</string>+ <string name="audiobooks_title" formatted="false">Hörbücher</string>+ <string name="artist_popular_tracks" formatted="false">Beliebt</string>+ <string name="curation_button_follow_state_text" formatted="false">Folgen</string>+ <string name="curation_button_following_state_text" formatted="false">Gefolgt</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Künstler*in</string>+ <string name="connect_phone_is_self" formatted="false">Dieses Smartphone</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Kurzes, sich wiederholendes Bildmaterial während der Songwiedergabe</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Nicht jetzt</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Aktualisieren</string>+ <string name="context_type_description_play_queue" formatted="false">Wiedergabe aus \'Warteschlange\'</string>+ <string name="context_type_description_collection_your_library" formatted="false">Wiedergabe aus deiner Bibliothek</string>+ <string name="context_type_description_playlist" formatted="false">Wiedergabe aus Playlist</string>+ <string name="context_type_description_album" formatted="false">Wiedergabe aus Album</string>+ <string name="context_type_description_artist" formatted="false">Wiedergabe über Künstler*in</string>+ <string name="context_type_description_show" formatted="false">Wiedergabe aus Podcast</string>+ <string name="context_type_description_search" formatted="false">Wiedergabe aus \'Suchen\'</string>+ <string name="default_notification_channel_name" formatted="false">Läuft gerade</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Geräte</string>+ <string name="action_share_label" formatted="false">Teilen</string>+ <string name="action_queue_label" formatted="false">In die Warteschlange</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 Stunde</string>+ <string name="curation_actions_edit_button_title" formatted="false">Bearbeiten</string>+ <string name="content_description_pause_button" formatted="false">Pause</string>+ <string name="content_description_play_button" formatted="false">Play</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Zufällige Wiedergabe</string>+ <string name="np_content_desc_repeat" formatted="false">Wiederholen</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Sleeptimer</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Entfernen</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Verschieben</string>+ <string name="bottom_actions_close" formatted="false">Schließen</string>+ <string name="add_to_queue_action_content_description" formatted="false">Zur Warteschlange hinzufügen</string>+ <string name="curation_button_saved_text" formatted="false">Gespeichert</string>+ <string name="np_content_desc_prev" formatted="false">Zurück</string>+ <string name="np_content_desc_next" formatted="false">Weiter</string>+ <string name="accessibility_navigate_back" formatted="false">Zurück</string>+ <string name="monthly_listeners_text" formatted="false">%1$s monatliche Hörer*innen</string>+ <string name="profile_bio_show_less" formatted="false">Weniger anzeigen</string>+ <string name="audiobook_series_see_more_button" formatted="false">Mehr anzeigen</string>+ <string name="popular_releases_section_title" formatted="false">Beliebte Veröffentlichungen</string>+ <string name="creator_biography_section_title" formatted="false">Infos</string>+ <string name="fans_also_like_section_title" formatted="false">Was anderen Fans gefällt</string>+ <string name="appears_on_section_title" formatted="false">Erscheint auf</string>+ <string name="composer_section_button_show_all" formatted="false">Alle anzeigen</string>+ <string name="releases_title" formatted="false">Releases</string>+ <string name="artist_releases_albums" formatted="false">Alben</string>+ <string name="artist_releases_singles" formatted="false">Singles und EPs</string>+ <string name="latest_release_title" formatted="false">Zuletzt erschienen</string>+ <string name="artist_subtitle" formatted="false">Künstler*in</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Letzte Suchanfragen</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Löschen</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasts</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Folgen</string>+ <string name="assisted_curation_search_song" formatted="false">Song</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Abmelden</string>+ <string name="library_search_text_hint" formatted="false">Bibliothek durchsuchen</string>+ <string name="account_title" formatted="false">Konto</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Künstler*innen, denen du folgst</string>+ <string name="settings_item_crossfade_title" formatted="false">Übergang</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d Sek.</string>+ <string name="local_files_title" formatted="false">Lokale Dateien</string>+ <string name="local_files_empty_section_title" formatted="false">Eigene Audiodateien zur Bibliothek hinzufügen</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Hast du einen Song oder persönlichen Podcast, der nicht auf Spotify ist?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Deine Audiodateien erscheinen hier</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Zugriff erlauben</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Zu den Einstellungen</string>+ <string name="context_menu_download" formatted="false">Herunterladen</string>+ <string name="context_menu_undownload" formatted="false">Download entfernen</string>+ <string name="collection_downloaded" formatted="false">Heruntergeladen</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Heruntergeladen</string>+ <string name="download_badge_downloading_content_description" formatted="false">Wird heruntergeladen</string>+ <string name="download_badge_error_content_description" formatted="false">Download fehlgeschlagen</string>+ <string name="download_notification_downloading" formatted="false">Wird heruntergeladen …</string>+ <string name="toast_undownload" formatted="false">Download wurde entfernt.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Aus Downloads entfernen?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Dann kannst du das nicht mehr ohne Internetverbindung abspielen.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Entfernen</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Alle Downloads entfernen</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Alle Downloads entfernen?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Compilation</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Beste Ergebnisse</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Songs</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Künstler*innen</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Alben</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlists</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Filter löschen</string>+ <string name="ad_category_title_music" formatted="false">Musik</string>+ <string name="made_for_you_hub_title" formatted="false">Für dich erstellt</string>+ <string name="settings_item_app_language_title" formatted="false">Sprache der App</string>+ <string name="create_menu_item_folder_title" formatted="false">Ordner</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Neuer Ordner</string>+ <string name="context_menu_rename_folder" formatted="false">Ordner umbenennen</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Ordnername</string>+ <string name="create_playlist_content_description" formatted="false">Playlist erstellen</string>+ <string name="actions_picker_delete" formatted="false">Löschen</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sortieren nach</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alphabetisch</string>+ <string name="your_library_sort_order_creator" formatted="false">Nach Creator*in</string>+ <string name="your_library_sort_order_custom" formatted="false">Benutzerdefinierte Reihenfolge</string>+ <string name="settings_item_version_title" formatted="false">Version</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Zum Song-Radio</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">In Lieblingssongs suchen</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">In Playlist suchen</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Keine Suchergebnisse für „%1$s“</string>+</resources>diff --git a/base/app/src/main/res/values-de/strings.xml b/base/app/src/main/res/values-de/strings.xmlnew file mode 100644index 00000000..27135fbb--- /dev/null+++ b/base/app/src/main/res/values-de/strings.xml@@ -0,0 +1,35 @@+<?xml version="1.0" encoding="utf-8"?>+<resources>+ <string name="app_name">Myspoti</string>+ <string name="aa_playlists">Playlists</string>+ <string name="aa_albums">Alben</string>+ <string name="aa_artists">Künstler</string>+ <string name="aa_podcasts">Podcasts</string>+ <string name="settings_amoled_theme">AMOLED-Design</string>+ <string name="settings_amoled_theme_subtitle">Rein schwarzer Hintergrund zum Akkusparen</string>+ <string name="settings_lyrics_style_spotify_default">Spotify-Standard</string>+ <string name="settings_lyrics_style_fullscreen">Vollbild (Albumfarben)</string>+ <string name="settings_lyrics_style_compact">Kompakt</string>+ <string name="settings_lyrics_style_karaoke">Karaoke</string>+ <string name="settings_lyrics_style_bold">Groß und fett</string>+ <string name="main_update_available">Ein neues Update ist verfügbar</string>+ <string name="notif_channel_media_name">Medienwiedergabe</string>+ <string name="notif_channel_media_description">Steuerung der Medienwiedergabe von Myspoti</string>+ <string name="notif_action_previous">Vorheriger</string>+ <string name="notif_action_next">Nächster</string>+ <string name="notif_action_play">Abspielen</string>+ <string name="notif_action_pause">Pausieren</string>+ <string name="notif_shuffle_enable">Zufallswiedergabe aktivieren</string>+ <string name="notif_shuffle_disable">Zufallswiedergabe deaktivieren</string>+ <string name="notif_shuffle_disable_smart">Smart-Shuffle deaktivieren</string>+ <string name="notif_action_like">Gefällt mir</string>+ <string name="notif_action_unlike">Gefällt mir nicht mehr</string>+ <string name="notif_unknown_name">Unbekannt</string>+ <string name="notif_by_artist">von %1$s</string>+ <string name="notif_repeat_disable">Wiederholen deaktivieren</string>+ <string name="notif_repeat_disable_one">Titel-Wiederholung deaktivieren</string>+ <string name="notif_repeat_enable">Wiederholen aktivieren</string>+ <string name="bridge_player_unlocked">Player entsperrt</string>+ <string name="bridge_reloading">Wird neu geladen…</string>+ <string name="service_disabled_message">Der Dienst ist nicht aktiviert</string>+</resources>diff --git a/base/app/src/main/res/values-el/spotify_plurals.xml b/base/app/src/main/res/values-el/spotify_plurals.xmlnew file mode 100644index 00000000..c877cc88--- /dev/null+++ b/base/app/src/main/res/values-el/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d τραγούδι</item>+ <item quantity="other">%1$d τραγούδια</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d αποθήκευση</item>+ <item quantity="other">%1$,d αποθηκεύσεις</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="other">%1$s playlist</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s τραγούδι</item>+ <item quantity="other">%1$s τραγούδια</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-el/spotify_strings.xml b/base/app/src/main/res/values-el/spotify_strings.xmlnew file mode 100644index 00000000..4f178174--- /dev/null+++ b/base/app/src/main/res/values-el/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Προσθήκη στα τραγούδια που σου αρέσουν</string>+ <string name="collection_liked_songs_title" formatted="false">Τραγούδια που σου αρέσουν</string>+ <string name="context_menu_add_to_playlist" formatted="false">Προσθήκη σε playlist</string>+ <string name="context_menu_play_next" formatted="false">Αναπαραγωγή στη συνέχεια</string>+ <string name="context_menu_add_to_queue" formatted="false">Προσθήκη σε ουρά</string>+ <string name="context_menu_go_to_queue" formatted="false">Μετάβαση στην ουρά</string>+ <string name="context_menu_browse_album" formatted="false">Μετάβαση στο άλμπουμ</string>+ <string name="context_menu_browse_artist" formatted="false">Μετάβαση στον καλλιτέχνη</string>+ <string name="context_menu_share" formatted="false">Κοινοποίηση</string>+ <string name="context_menu_sleep_timer" formatted="false">Χρονόμετρο ύπνου</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Απενεργοποίηση του χρονομέτρου</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Τέλος κομματιού</string>+ <string name="snackbar_added_to_queue" formatted="false">Προστέθηκε στη λίστα αναπαραγωγής</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Προστέθηκε στα τραγούδια που σου αρέσουν.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Καταργήθηκε από τα τραγούδια που σου αρέσουν.</string>+ <string name="content_description_context_menu" formatted="false">Περισσότερες επιλογές</string>+ <string name="close_button_content_description" formatted="false">Κλείσιμο</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Αποθηκευμένο σε</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Δημιουργία νέας playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Ακύρωση</string>+ <string name="create_playlist_create_button" formatted="false">Δημιουργία</string>+ <string name="lyrics_card_title" formatted="false">Στίχοι</string>+ <string name="lyrics_card_title_preview" formatted="false">Προεπισκόπηση στίχων</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Εμφάνιση στίχων</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Προβολή στίχων σε πλήρη οθόνη</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Κοινοποίηση στίχων</string>+ <string name="lyrics_credential_note" formatted="false">Οι στίχοι παρέχονται από %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Κοινοποίηση</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Μετάφραση</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Κλείσιμο στίχων</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Μετάφραση στίχων</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Να σταματήσει η μετάφραση των στίχων</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Χμ… Δεν ξέρουμε τους στίχους του.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Αυτοί οι στίχοι δεν είναι συγχρονισμένοι ακόμα.</string>+ <string name="av_switch_to_video" formatted="false">Αλλαγή σε βίντεο</string>+ <string name="av_switch_to_audio" formatted="false">Αλλαγή σε ήχο</string>+ <string name="av_content_desc" formatted="false">Εναλλαγή μεταξύ ήχου και βίντεο</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Αρχική</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Αναζήτηση</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Βιβλιοθήκη</string>+ <string name="search_header_field_hint" formatted="false">Τι θέλεις να ακούσεις;</string>+ <string name="filter_chip_all_label" formatted="false">Όλα</string>+ <string name="recents_content_filter_music" formatted="false">Μουσική</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcast</string>+ <string name="audiobooks_title" formatted="false">Ηχητικά βιβλία</string>+ <string name="artist_popular_tracks" formatted="false">Δημοφιλή</string>+ <string name="curation_button_follow_state_text" formatted="false">Ακολούθησε</string>+ <string name="curation_button_following_state_text" formatted="false">Ακολουθείς</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Καλλιτέχνης</string>+ <string name="connect_phone_is_self" formatted="false">Αυτό το τηλέφωνο</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Σύντομα, επαναλαμβανόμενα οπτικά στοιχεία κατά την αναπαραγωγή ενός τραγουδιού.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Όχι τώρα</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Κάνε ενημέρωση</string>+ <string name="context_type_description_play_queue" formatted="false">Αναπαραγωγή από τη λίστα αναπαραγωγής</string>+ <string name="context_type_description_collection_your_library" formatted="false">Αναπαραγωγή από τη Βιβλιοθήκη</string>+ <string name="context_type_description_playlist" formatted="false">Αναπαραγωγή από την playlist</string>+ <string name="context_type_description_album" formatted="false">Αναπαραγωγή από άλμπουμ</string>+ <string name="context_type_description_artist" formatted="false">Αναπαραγωγή από Καλλιτέχνη</string>+ <string name="context_type_description_show" formatted="false">Αναπαραγωγή από Podcast</string>+ <string name="context_type_description_search" formatted="false">Αναπαραγωγή από την Αναζήτηση</string>+ <string name="default_notification_channel_name" formatted="false">Ακούγεται τώρα</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Συσκευές</string>+ <string name="action_share_label" formatted="false">Κοινοποίηση</string>+ <string name="action_queue_label" formatted="false">Λίστα αναπαραγωγής</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 ώρα</string>+ <string name="curation_actions_edit_button_title" formatted="false">Επεξεργασία</string>+ <string name="content_description_pause_button" formatted="false">Παύση</string>+ <string name="content_description_play_button" formatted="false">Αναπαραγωγή</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Τυχαία σειρά</string>+ <string name="np_content_desc_repeat" formatted="false">Επανάληψη</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Χρονοδιακόπτης ύπνου</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Κατάργηση</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Μετακίνηση</string>+ <string name="bottom_actions_close" formatted="false">Κλείσιμο</string>+ <string name="add_to_queue_action_content_description" formatted="false">Προσθήκη σε λίστα αναπαραγωγής</string>+ <string name="curation_button_saved_text" formatted="false">Αποθηκεύτηκε</string>+ <string name="np_content_desc_prev" formatted="false">Προηγούμενο</string>+ <string name="np_content_desc_next" formatted="false">Επόμενο</string>+ <string name="accessibility_navigate_back" formatted="false">Πίσω</string>+ <string name="monthly_listeners_text" formatted="false">%1$s μηνιαίοι ακροατές</string>+ <string name="profile_bio_show_less" formatted="false">Εμφάνιση λιγότερων</string>+ <string name="audiobook_series_see_more_button" formatted="false">Εμφάνιση περισσότερων</string>+ <string name="popular_releases_section_title" formatted="false">Δημοφιλείς κυκλοφορίες</string>+ <string name="creator_biography_section_title" formatted="false">Πληροφορίες</string>+ <string name="fans_also_like_section_title" formatted="false">Οι θαυμαστές ακούν επίσης</string>+ <string name="appears_on_section_title" formatted="false">Εμφανίζεται στο</string>+ <string name="composer_section_button_show_all" formatted="false">Εμφάνιση όλων</string>+ <string name="releases_title" formatted="false">Κυκλοφορίες</string>+ <string name="artist_releases_albums" formatted="false">Άλμπουμ</string>+ <string name="artist_releases_singles" formatted="false">Single και EP</string>+ <string name="latest_release_title" formatted="false">Τελευταία κυκλοφορία</string>+ <string name="artist_subtitle" formatted="false">Καλλιτέχνης</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Πρόσφατες αναζητήσεις</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Απαλοιφή</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcast</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Επεισόδια</string>+ <string name="assisted_curation_search_song" formatted="false">Τραγούδι</string>+ <string name="album" formatted="false">Άλμπουμ</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Προφίλ</string>+ <string name="connect_device_menu_logout" formatted="false">Αποσύνδεση</string>+ <string name="library_search_text_hint" formatted="false">Αναζήτηση στη Βιβλιοθήκη σου</string>+ <string name="account_title" formatted="false">Λογαριασμός</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Καλλιτέχνες που ακολουθείς</string>+ <string name="settings_item_crossfade_title" formatted="false">Crossfade</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d δευτ.</string>+ <string name="local_files_title" formatted="false">Τοπικά αρχεία</string>+ <string name="local_files_empty_section_title" formatted="false">Πρόσθεσε τα δικά σου αρχεία ήχου στη Βιβλιοθήκη σου</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Έχεις ένα τραγούδι ή ένα προσωπικό podcast που δεν υπάρχει στο Spotify;</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Τα αρχεία ήχου σου θα εμφανιστούν εδώ</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Παροχή πρόσβασης</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Μετάβαση στις Ρυθμίσεις</string>+ <string name="context_menu_download" formatted="false">Λήψη</string>+ <string name="context_menu_undownload" formatted="false">Κατάργηση λήψης</string>+ <string name="collection_downloaded" formatted="false">Έγινε λήψη</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Έγινε λήψη</string>+ <string name="download_badge_downloading_content_description" formatted="false">Γίνεται λήψη</string>+ <string name="download_badge_error_content_description" formatted="false">Η λήψη απέτυχε</string>+ <string name="download_notification_downloading" formatted="false">Γίνεται λήψη…</string>+ <string name="toast_undownload" formatted="false">Η λήψη αφαιρέθηκε.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Κατάργηση από τις λήψεις;</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Δεν θα μπορείς να το ακούσεις εκτός σύνδεσης.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Κατάργηση</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Κατάργηση όλων των λήψεων</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Κατάργηση όλων των λήψεων;</string>+ <string name="album_type_album" formatted="false">Άλμπουμ</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Συλλογή</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Καλύτερα αποτελέσματα</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Τραγούδια</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Καλλιτέχνες</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Άλμπουμ</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Διάγραψε το φίλτρο</string>+ <string name="ad_category_title_music" formatted="false">Μουσική</string>+ <string name="made_for_you_hub_title" formatted="false">Δημιουργήθηκε για εσένα</string>+ <string name="settings_item_app_language_title" formatted="false">Γλώσσα εφαρμογής</string>+ <string name="create_menu_item_folder_title" formatted="false">Φάκελος</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Νέος φάκελος</string>+ <string name="context_menu_rename_folder" formatted="false">Μετονομασία φακέλου</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Όνομα φακέλου</string>+ <string name="create_playlist_content_description" formatted="false">Δημιουργία playlist</string>+ <string name="actions_picker_delete" formatted="false">Διαγραφή</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Ταξινόμηση κατά</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Αλφαβητικά</string>+ <string name="your_library_sort_order_creator" formatted="false">Δημιουργός</string>+ <string name="your_library_sort_order_custom" formatted="false">Προσαρμοσμένη σειρά</string>+ <string name="settings_item_version_title" formatted="false">Έκδοση</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Μετάβαση στο Ραδιόφωνο βάσει τραγουδιού</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Βρες τραγούδια που σου αρέσουν</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Εύρεση στην playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Δεν βρήκαμε αποτελέσματα για \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-en-rGB/spotify_plurals.xml b/base/app/src/main/res/values-en-rGB/spotify_plurals.xmlnew file mode 100644index 00000000..15df1014--- /dev/null+++ b/base/app/src/main/res/values-en-rGB/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d song</item>+ <item quantity="other">%1$d songs</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d save</item>+ <item quantity="other">%1$,d saves</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="other">%1$s playlists</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s song</item>+ <item quantity="other">%1$s songs</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-en-rGB/spotify_strings.xml b/base/app/src/main/res/values-en-rGB/spotify_strings.xmlnew file mode 100644index 00000000..f5d7e020--- /dev/null+++ b/base/app/src/main/res/values-en-rGB/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Add to Liked Songs</string>+ <string name="collection_liked_songs_title" formatted="false">Liked Songs</string>+ <string name="context_menu_add_to_playlist" formatted="false">Add to playlist</string>+ <string name="context_menu_play_next" formatted="false">Play next</string>+ <string name="context_menu_add_to_queue" formatted="false">Add to Queue</string>+ <string name="context_menu_go_to_queue" formatted="false">Go to Queue</string>+ <string name="context_menu_browse_album" formatted="false">Go to album</string>+ <string name="context_menu_browse_artist" formatted="false">Go to artist</string>+ <string name="context_menu_share" formatted="false">Share</string>+ <string name="context_menu_sleep_timer" formatted="false">Sleep timer</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Turn off timer</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">End of track</string>+ <string name="snackbar_added_to_queue" formatted="false">Added to Queue</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Added to Liked Songs.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Removed from Liked Songs.</string>+ <string name="content_description_context_menu" formatted="false">More options</string>+ <string name="close_button_content_description" formatted="false">Close</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Saved in</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">New playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Cancel</string>+ <string name="create_playlist_create_button" formatted="false">Create</string>+ <string name="lyrics_card_title" formatted="false">Lyrics</string>+ <string name="lyrics_card_title_preview" formatted="false">Lyrics preview</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Show lyrics</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Open full screen lyrics</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Share lyrics</string>+ <string name="lyrics_credential_note" formatted="false">Lyrics provided by %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Share</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Translate</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Close lyrics</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Translate lyrics</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Stop translating lyrics</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. We don’t know the lyrics for this one.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">These lyrics aren’t time-synced yet.</string>+ <string name="av_switch_to_video" formatted="false">Switch to video</string>+ <string name="av_switch_to_audio" formatted="false">Switch to audio</string>+ <string name="av_content_desc" formatted="false">Toggle between audio and video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Home</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Search</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Your Library</string>+ <string name="search_header_field_hint" formatted="false">What do you want to listen to?</string>+ <string name="filter_chip_all_label" formatted="false">All</string>+ <string name="recents_content_filter_music" formatted="false">Music</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasts</string>+ <string name="audiobooks_title" formatted="false">Audiobooks</string>+ <string name="artist_popular_tracks" formatted="false">Popular</string>+ <string name="curation_button_follow_state_text" formatted="false">Follow</string>+ <string name="curation_button_following_state_text" formatted="false">Following</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artist</string>+ <string name="connect_phone_is_self" formatted="false">This phone</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Short, looping visuals when a song is playing.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Not now</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Update</string>+ <string name="context_type_description_play_queue" formatted="false">Playing from Play Queue</string>+ <string name="context_type_description_collection_your_library" formatted="false">Playing from Your Library</string>+ <string name="context_type_description_playlist" formatted="false">Playing from Playlist</string>+ <string name="context_type_description_album" formatted="false">Playing from Album</string>+ <string name="context_type_description_artist" formatted="false">Playing from Artist</string>+ <string name="context_type_description_show" formatted="false">Playing from Podcast</string>+ <string name="context_type_description_search" formatted="false">Playing from Search</string>+ <string name="default_notification_channel_name" formatted="false">Now playing</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Devices</string>+ <string name="action_share_label" formatted="false">Share</string>+ <string name="action_queue_label" formatted="false">Queue</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 hour</string>+ <string name="curation_actions_edit_button_title" formatted="false">Edit</string>+ <string name="content_description_pause_button" formatted="false">Pause</string>+ <string name="content_description_play_button" formatted="false">Play</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Shuffle</string>+ <string name="np_content_desc_repeat" formatted="false">Repeat</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Sleep timer</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Remove</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Move</string>+ <string name="bottom_actions_close" formatted="false">Close</string>+ <string name="add_to_queue_action_content_description" formatted="false">Add to queue</string>+ <string name="curation_button_saved_text" formatted="false">Saved</string>+ <string name="np_content_desc_prev" formatted="false">Previous</string>+ <string name="np_content_desc_next" formatted="false">Next</string>+ <string name="accessibility_navigate_back" formatted="false">Back</string>+ <string name="monthly_listeners_text" formatted="false">%1$s monthly listeners</string>+ <string name="profile_bio_show_less" formatted="false">Show less</string>+ <string name="audiobook_series_see_more_button" formatted="false">Show more</string>+ <string name="popular_releases_section_title" formatted="false">Popular releases</string>+ <string name="creator_biography_section_title" formatted="false">About</string>+ <string name="fans_also_like_section_title" formatted="false">Fans also like</string>+ <string name="appears_on_section_title" formatted="false">Appears on</string>+ <string name="composer_section_button_show_all" formatted="false">Show all</string>+ <string name="releases_title" formatted="false">Releases</string>+ <string name="artist_releases_albums" formatted="false">Albums</string>+ <string name="artist_releases_singles" formatted="false">Singles and EPs</string>+ <string name="latest_release_title" formatted="false">Latest release</string>+ <string name="artist_subtitle" formatted="false">Artist</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Recent searches</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Clear</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasts</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episodes</string>+ <string name="assisted_curation_search_song" formatted="false">Song</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profile</string>+ <string name="connect_device_menu_logout" formatted="false">Log out</string>+ <string name="library_search_text_hint" formatted="false">Search Your Library</string>+ <string name="account_title" formatted="false">Account</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Followed artists</string>+ <string name="settings_item_crossfade_title" formatted="false">Crossfade</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Local Files</string>+ <string name="local_files_empty_section_title" formatted="false">Add your own audio files to Your Library</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Got a song or personal podcast that’s not on Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Your audio files will appear here</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Give access</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Go to Settings</string>+ <string name="context_menu_download" formatted="false">Download</string>+ <string name="context_menu_undownload" formatted="false">Remove download</string>+ <string name="collection_downloaded" formatted="false">Downloaded</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Downloaded</string>+ <string name="download_badge_downloading_content_description" formatted="false">Downloading</string>+ <string name="download_badge_error_content_description" formatted="false">Download failed</string>+ <string name="download_notification_downloading" formatted="false">Downloading…</string>+ <string name="toast_undownload" formatted="false">Download removed.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Remove from downloads?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">You won’t be able to play this offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Remove</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Remove all downloads</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Remove all downloads?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Compilation</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Top</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Songs</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artists</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albums</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlists</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Clear filter</string>+ <string name="ad_category_title_music" formatted="false">Music</string>+ <string name="made_for_you_hub_title" formatted="false">Made for You</string>+ <string name="settings_item_app_language_title" formatted="false">App language</string>+ <string name="create_menu_item_folder_title" formatted="false">Folder</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">New folder</string>+ <string name="context_menu_rename_folder" formatted="false">Rename folder</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Folder name</string>+ <string name="create_playlist_content_description" formatted="false">Create playlist</string>+ <string name="actions_picker_delete" formatted="false">Delete</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sort by</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alphabetical</string>+ <string name="your_library_sort_order_creator" formatted="false">Creator</string>+ <string name="your_library_sort_order_custom" formatted="false">Custom order</string>+ <string name="settings_item_version_title" formatted="false">Version</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Go to song radio</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Find in Liked Songs</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Find in playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Couldn’t find ‘%1$s’</string>+</resources>diff --git a/base/app/src/main/res/values-es-rAR/spotify_plurals.xml b/base/app/src/main/res/values-es-rAR/spotify_plurals.xmlnew file mode 100644index 00000000..81f84100--- /dev/null+++ b/base/app/src/main/res/values-es-rAR/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d canción</item>+ <item quantity="other">%1$d canciones</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d vez guardada</item>+ <item quantity="other">%1$,d veces guardada</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="other">%1$s playlists</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s canción</item>+ <item quantity="other">%1$s canciones</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-es-rAR/spotify_strings.xml b/base/app/src/main/res/values-es-rAR/spotify_strings.xmlnew file mode 100644index 00000000..636d3c1e--- /dev/null+++ b/base/app/src/main/res/values-es-rAR/spotify_strings.xml@@ -0,0 +1,147 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Agregar a Tus me gusta</string>+ <string name="context_menu_add_to_playlist" formatted="false">Agregar a playlist</string>+ <string name="context_menu_play_next" formatted="false">Reproducir siguiente</string>+ <string name="context_menu_add_to_queue" formatted="false">Agregar a la fila</string>+ <string name="context_menu_go_to_queue" formatted="false">Ir a fila</string>+ <string name="context_menu_browse_album" formatted="false">Ir al álbum</string>+ <string name="context_menu_browse_artist" formatted="false">Ir al artista</string>+ <string name="context_menu_share" formatted="false">Compartir</string>+ <string name="snackbar_added_to_queue" formatted="false">Se agregó a la fila de reproducción</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Se agregó a Tus me gusta.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Se eliminó de Tus me gusta.</string>+ <string name="content_description_context_menu" formatted="false">Más opciones</string>+ <string name="close_button_content_description" formatted="false">Cerrar</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Guardado en</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nueva playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Cancelar</string>+ <string name="create_playlist_create_button" formatted="false">Crear</string>+ <string name="lyrics_card_title" formatted="false">Letras</string>+ <string name="lyrics_card_title_preview" formatted="false">Vista previa de la letra</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Mostrar la letra</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Abrir la letra en pantalla completa</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Compartí la letra</string>+ <string name="lyrics_credential_note" formatted="false">Letras proporcionadas por %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Compartir</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Traducir</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Cerrar la letra</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Traducir la letra</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Dejar de traducir la letra</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Mmm… No nos sabemos esta letra.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Esta letra todavía no está sincronizada con la música.</string>+ <string name="av_switch_to_video" formatted="false">Cambiar a video</string>+ <string name="av_switch_to_audio" formatted="false">Cambiar a audio</string>+ <string name="av_content_desc" formatted="false">Alternar entre audio y video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Inicio</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Buscar</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Tu biblioteca</string>+ <string name="search_header_field_hint" formatted="false">¿Qué querés escuchar?</string>+ <string name="filter_chip_all_label" formatted="false">Todo</string>+ <string name="recents_content_filter_music" formatted="false">Música</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasts</string>+ <string name="audiobooks_title" formatted="false">Audiolibros</string>+ <string name="artist_popular_tracks" formatted="false">Populares</string>+ <string name="curation_button_follow_state_text" formatted="false">Seguir</string>+ <string name="curation_button_following_state_text" formatted="false">Siguiendo</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artista</string>+ <string name="connect_phone_is_self" formatted="false">Este teléfono</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Efectos visuales breves y en repetición cuando se reproduce una canción.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Ahora no</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Actualizar</string>+ <string name="default_notification_channel_name" formatted="false">Spotify</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="action_share_label" formatted="false">Compartir</string>+ <string name="action_queue_label" formatted="false">Agregar a la fila</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 hora</string>+ <string name="curation_actions_edit_button_title" formatted="false">Editar</string>+ <string name="content_description_pause_button" formatted="false">Pausar</string>+ <string name="content_description_play_button" formatted="false">Reproducir</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Modo aleatorio</string>+ <string name="np_content_desc_repeat" formatted="false">Repetir</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Apagado automático</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Eliminar</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Mover</string>+ <string name="bottom_actions_close" formatted="false">Cerrar</string>+ <string name="add_to_queue_action_content_description" formatted="false">Agregar a la fila</string>+ <string name="curation_button_saved_text" formatted="false">Guardado</string>+ <string name="np_content_desc_prev" formatted="false">Anterior</string>+ <string name="np_content_desc_next" formatted="false">Siguiente</string>+ <string name="accessibility_navigate_back" formatted="false">Atrás</string>+ <string name="monthly_listeners_text" formatted="false">%1$s oyentes mensuales</string>+ <string name="profile_bio_show_less" formatted="false">Mostrar menos</string>+ <string name="audiobook_series_see_more_button" formatted="false">Mostrar más</string>+ <string name="popular_releases_section_title" formatted="false">Lanzamientos populares</string>+ <string name="creator_biography_section_title" formatted="false">Acerca de</string>+ <string name="fans_also_like_section_title" formatted="false">A los fans también les gusta</string>+ <string name="appears_on_section_title" formatted="false">Aparece en</string>+ <string name="composer_section_button_show_all" formatted="false">Mostrar todo</string>+ <string name="releases_title" formatted="false">Lanzamientos</string>+ <string name="artist_releases_albums" formatted="false">Álbumes</string>+ <string name="artist_releases_singles" formatted="false">Sencillos y EP</string>+ <string name="latest_release_title" formatted="false">Último lanzamiento</string>+ <string name="artist_subtitle" formatted="false">Artista</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Búsquedas recientes</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Borrar</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasts</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episodios</string>+ <string name="assisted_curation_search_song" formatted="false">Canción</string>+ <string name="album" formatted="false">Álbum</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Perfil</string>+ <string name="connect_device_menu_logout" formatted="false">Cerrar sesión</string>+ <string name="library_search_text_hint" formatted="false">Buscá en Tu biblioteca</string>+ <string name="account_title" formatted="false">Cuenta</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Artistas que seguís</string>+ <string name="settings_item_crossfade_title" formatted="false">Crossfade</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_empty_section_title" formatted="false">Agregá tus propios archivos de audio a Tu biblioteca</string>+ <string name="local_files_empty_section_subtitle" formatted="false">¿Tenés una canción o un podcast personal que no está en Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Tus archivos de audio van a aparecer acá</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Permitir acceso</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Ir a la configuración</string>+ <string name="context_menu_download" formatted="false">Descargar</string>+ <string name="context_menu_undownload" formatted="false">Eliminar descarga</string>+ <string name="collection_downloaded" formatted="false">Descargados</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Descargado</string>+ <string name="download_badge_downloading_content_description" formatted="false">Descargando</string>+ <string name="download_badge_error_content_description" formatted="false">Error en la descarga</string>+ <string name="download_notification_downloading" formatted="false">Descargando…</string>+ <string name="toast_undownload" formatted="false">Se eliminó la descarga.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">¿Eliminar de tus descargas?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">No vas a poder escuchar este contenido sin conexión.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Eliminar</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Eliminar todas las descargas</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">¿Querés eliminar todas las descargas?</string>+ <string name="album_type_album" formatted="false">Álbum</string>+ <string name="album_type_single" formatted="false">Sencillo</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Compilación</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Mejores resultados</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Canciones</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artistas</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Álbumes</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlists</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Eliminar filtro</string>+ <string name="ad_category_title_music" formatted="false">Música</string>+ <string name="made_for_you_hub_title" formatted="false">Creado para vos</string>+ <string name="settings_item_app_language_title" formatted="false">Idioma de la aplicación</string>+ <string name="create_menu_item_folder_title" formatted="false">Carpeta</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nueva carpeta</string>+ <string name="context_menu_rename_folder" formatted="false">Renombrar la carpeta</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Nombre de la carpeta</string>+ <string name="create_playlist_content_description" formatted="false">Crear una playlist</string>+ <string name="actions_picker_delete" formatted="false">Eliminar</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Ordenar por</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alfabéticamente</string>+ <string name="your_library_sort_order_creator" formatted="false">Por creador</string>+ <string name="your_library_sort_order_custom" formatted="false">Orden personalizado</string>+ <string name="settings_item_version_title" formatted="false">Versión</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Ir a radio de la canción</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Buscar en Tus me gusta</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Buscar en la playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">No se pudo encontrar \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-es-rMX/spotify_plurals.xml b/base/app/src/main/res/values-es-rMX/spotify_plurals.xmlnew file mode 100644index 00000000..92226905--- /dev/null+++ b/base/app/src/main/res/values-es-rMX/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d canción</item>+ <item quantity="other">%1$d canciones</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">Se guardó %1$,d vez</item>+ <item quantity="other">Se guardó %1$,d veces</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="other">%1$s playlists</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s canción</item>+ <item quantity="other">%1$s canciones</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-es-rMX/spotify_strings.xml b/base/app/src/main/res/values-es-rMX/spotify_strings.xmlnew file mode 100644index 00000000..b28c0386--- /dev/null+++ b/base/app/src/main/res/values-es-rMX/spotify_strings.xml@@ -0,0 +1,147 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Agregar a Tus me gusta</string>+ <string name="context_menu_add_to_playlist" formatted="false">Agregar a playlist</string>+ <string name="context_menu_play_next" formatted="false">Reproducir a continuación</string>+ <string name="context_menu_add_to_queue" formatted="false">Agregar a la fila de reproducción</string>+ <string name="context_menu_go_to_queue" formatted="false">Ir a la fila de reproducción</string>+ <string name="context_menu_browse_album" formatted="false">Ir al álbum</string>+ <string name="context_menu_browse_artist" formatted="false">Ir al artista</string>+ <string name="context_menu_share" formatted="false">Compartir</string>+ <string name="snackbar_added_to_queue" formatted="false">Se agregó a la fila de reproducción</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Se agregó a Tus me gusta.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Se eliminó de Tus me gusta.</string>+ <string name="content_description_context_menu" formatted="false">Más opciones</string>+ <string name="close_button_content_description" formatted="false">Cerrar</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Guardado en</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nueva playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Cancelar</string>+ <string name="create_playlist_create_button" formatted="false">Crear</string>+ <string name="lyrics_card_title" formatted="false">Letra</string>+ <string name="lyrics_card_title_preview" formatted="false">Muestra de la letra</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Mostrar la letra</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Abrir la letra en pantalla completa</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Compartir la letra</string>+ <string name="lyrics_credential_note" formatted="false">Letras proporcionadas por %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Compartir</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Traducir</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Cerrar la letra</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Traducir la letra</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Dejar de traducir la letra</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Mmm… No nos sabemos esta letra.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Esta letra todavía no está sincronizada con la música.</string>+ <string name="av_switch_to_video" formatted="false">Cambiar a video</string>+ <string name="av_switch_to_audio" formatted="false">Cambiar a audio</string>+ <string name="av_content_desc" formatted="false">Alternar entre audio y video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Inicio</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Buscar</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Tu biblioteca</string>+ <string name="search_header_field_hint" formatted="false">¿Qué quieres escuchar?</string>+ <string name="filter_chip_all_label" formatted="false">Todo</string>+ <string name="recents_content_filter_music" formatted="false">Música</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasts</string>+ <string name="audiobooks_title" formatted="false">Audiolibros</string>+ <string name="artist_popular_tracks" formatted="false">Populares</string>+ <string name="curation_button_follow_state_text" formatted="false">Seguir</string>+ <string name="curation_button_following_state_text" formatted="false">Siguiendo</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artista</string>+ <string name="connect_phone_is_self" formatted="false">Este teléfono</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Efectos visuales breves y en repetición cuando se reproduce una canción.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Ahora no</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Actualizar</string>+ <string name="default_notification_channel_name" formatted="false">Spotify</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="action_share_label" formatted="false">Compartir</string>+ <string name="action_queue_label" formatted="false">Agregar a la fila</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 hora</string>+ <string name="curation_actions_edit_button_title" formatted="false">Editar</string>+ <string name="content_description_pause_button" formatted="false">Pausar</string>+ <string name="content_description_play_button" formatted="false">Reproducir</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Reproducción aleatoria</string>+ <string name="np_content_desc_repeat" formatted="false">Repetir</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Apagado automático</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Eliminar</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Mover</string>+ <string name="bottom_actions_close" formatted="false">Cerrar</string>+ <string name="add_to_queue_action_content_description" formatted="false">Agregar a la fila</string>+ <string name="curation_button_saved_text" formatted="false">Guardado</string>+ <string name="np_content_desc_prev" formatted="false">Anterior</string>+ <string name="np_content_desc_next" formatted="false">Siguiente</string>+ <string name="accessibility_navigate_back" formatted="false">Atrás</string>+ <string name="monthly_listeners_text" formatted="false">%1$s oyentes mensuales</string>+ <string name="profile_bio_show_less" formatted="false">Mostrar menos</string>+ <string name="audiobook_series_see_more_button" formatted="false">Mostrar más</string>+ <string name="popular_releases_section_title" formatted="false">Lanzamientos populares</string>+ <string name="creator_biography_section_title" formatted="false">Información</string>+ <string name="fans_also_like_section_title" formatted="false">A los fans también les gusta</string>+ <string name="appears_on_section_title" formatted="false">Aparece en</string>+ <string name="composer_section_button_show_all" formatted="false">Mostrar todo</string>+ <string name="releases_title" formatted="false">Lanzamientos</string>+ <string name="artist_releases_albums" formatted="false">Álbumes</string>+ <string name="artist_releases_singles" formatted="false">Sencillos y EP</string>+ <string name="latest_release_title" formatted="false">Último lanzamiento</string>+ <string name="artist_subtitle" formatted="false">Artista</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Búsquedas recientes</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Borrar</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasts</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episodios</string>+ <string name="assisted_curation_search_song" formatted="false">Canción</string>+ <string name="album" formatted="false">Álbum</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Perfil</string>+ <string name="connect_device_menu_logout" formatted="false">Cerrar sesión</string>+ <string name="library_search_text_hint" formatted="false">Busca en Tu biblioteca</string>+ <string name="account_title" formatted="false">Cuenta</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Artistas seguidos</string>+ <string name="settings_item_crossfade_title" formatted="false">Crossfade</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_empty_section_title" formatted="false">Agrega tus propios archivos de audio a Tu biblioteca</string>+ <string name="local_files_empty_section_subtitle" formatted="false">¿Tienes una canción o un podcast personal que no está en Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Tus archivos de audio aparecerán aquí</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Permitir acceso</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Ir a la configuración</string>+ <string name="context_menu_download" formatted="false">Descargar</string>+ <string name="context_menu_undownload" formatted="false">Eliminar descarga</string>+ <string name="collection_downloaded" formatted="false">Descargados</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Descargados</string>+ <string name="download_badge_downloading_content_description" formatted="false">Descargando</string>+ <string name="download_badge_error_content_description" formatted="false">Error en la descarga</string>+ <string name="download_notification_downloading" formatted="false">Descargando…</string>+ <string name="toast_undownload" formatted="false">Se eliminó la descarga.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">¿Eliminar de tus descargas?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">No podrás escuchar este contenido sin conexión.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Eliminar</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Eliminar todas las descargas</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">¿Quieres eliminar todas las descargas?</string>+ <string name="album_type_album" formatted="false">Álbum</string>+ <string name="album_type_single" formatted="false">Sencillo</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Compilación</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Top</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Canciones</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artistas</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Álbumes</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlists</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Eliminar filtro</string>+ <string name="ad_category_title_music" formatted="false">Música</string>+ <string name="made_for_you_hub_title" formatted="false">Creado para ti</string>+ <string name="settings_item_app_language_title" formatted="false">Idioma de la aplicación</string>+ <string name="create_menu_item_folder_title" formatted="false">Carpeta</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nueva carpeta</string>+ <string name="context_menu_rename_folder" formatted="false">Renombrar la carpeta</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Nombre de la carpeta</string>+ <string name="create_playlist_content_description" formatted="false">Crear una playlist</string>+ <string name="actions_picker_delete" formatted="false">Eliminar</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Ordenar por</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alfabéticamente</string>+ <string name="your_library_sort_order_creator" formatted="false">Por creador</string>+ <string name="your_library_sort_order_custom" formatted="false">Orden personalizado</string>+ <string name="settings_item_version_title" formatted="false">Versión</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Ir a radio de la canción</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Buscar en Tus me gusta</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Buscar en la playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">No se pudo encontrar \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-es/spotify_plurals.xml b/base/app/src/main/res/values-es/spotify_plurals.xmlnew file mode 100644index 00000000..9d73530d--- /dev/null+++ b/base/app/src/main/res/values-es/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d canción</item>+ <item quantity="other">%1$d canciones</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">Guardada %1$,d vez</item>+ <item quantity="other">Guardada %1$,d veces</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s lista</item>+ <item quantity="other">%1$s listas</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s canción</item>+ <item quantity="other">%1$s canciones</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-es/spotify_strings.xml b/base/app/src/main/res/values-es/spotify_strings.xmlnew file mode 100644index 00000000..732d1c25--- /dev/null+++ b/base/app/src/main/res/values-es/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Añadir a Canciones que te gustan</string>+ <string name="collection_liked_songs_title" formatted="false">Canciones que te gustan</string>+ <string name="context_menu_add_to_playlist" formatted="false">Añadir a lista</string>+ <string name="context_menu_play_next" formatted="false">Reproducir a continuación</string>+ <string name="context_menu_add_to_queue" formatted="false">Añadir a la cola</string>+ <string name="context_menu_go_to_queue" formatted="false">Ir a la cola</string>+ <string name="context_menu_browse_album" formatted="false">Ir al álbum</string>+ <string name="context_menu_browse_artist" formatted="false">Ir al artista</string>+ <string name="context_menu_share" formatted="false">Compartir</string>+ <string name="context_menu_sleep_timer" formatted="false">Temporizador</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Desactivar el temporizador</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Fin de la canción</string>+ <string name="snackbar_added_to_queue" formatted="false">Se ha añadido a la cola</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Añadida a Canciones que te gustan.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Quitada de Canciones que te gustan.</string>+ <string name="content_description_context_menu" formatted="false">Más opciones</string>+ <string name="close_button_content_description" formatted="false">Cerrar</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Se ha guardado en</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nueva lista</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Cancelar</string>+ <string name="create_playlist_create_button" formatted="false">Crear</string>+ <string name="lyrics_card_title" formatted="false">Letra</string>+ <string name="lyrics_card_title_preview" formatted="false">Vista previa de la letra</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Mostrar letra</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Abrir letra a pantalla completa</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Compartir letra</string>+ <string name="lyrics_credential_note" formatted="false">Letra remitida por %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Compartir</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Traducir</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Cerrar letra</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Traducir letra</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Dejar de traducir la letra</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Vaya. La verdad es que no nos sabemos la letra de esta.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Aún no hemos sincronizado esta letra con la canción.</string>+ <string name="av_switch_to_video" formatted="false">Cambiar a vídeo</string>+ <string name="av_switch_to_audio" formatted="false">Cambiar a audio</string>+ <string name="av_content_desc" formatted="false">Cambiar entre audio y vídeo</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Inicio</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Buscar</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Tu biblioteca</string>+ <string name="search_header_field_hint" formatted="false">¿Qué te apetece escuchar?</string>+ <string name="filter_chip_all_label" formatted="false">Todo</string>+ <string name="recents_content_filter_music" formatted="false">Música</string>+ <string name="ad_category_title_podcasts" formatted="false">Pódcasts</string>+ <string name="audiobooks_title" formatted="false">Audiolibros</string>+ <string name="artist_popular_tracks" formatted="false">Populares</string>+ <string name="curation_button_follow_state_text" formatted="false">Seguir</string>+ <string name="curation_button_following_state_text" formatted="false">Siguiendo</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artista</string>+ <string name="connect_phone_is_self" formatted="false">Este teléfono</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Imágenes breves y en bucle mientras suena una canción.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Más tarde</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Actualizar</string>+ <string name="context_type_description_play_queue" formatted="false">Reproduciendo desde la cola de reproducción</string>+ <string name="context_type_description_collection_your_library" formatted="false">Reproduciendo desde Tu biblioteca</string>+ <string name="context_type_description_playlist" formatted="false">Reproduciendo desde lista</string>+ <string name="context_type_description_album" formatted="false">Reproduciendo desde el álbum</string>+ <string name="context_type_description_artist" formatted="false">Reproduciendo desde artista</string>+ <string name="context_type_description_show" formatted="false">Reproduciendo desde pódcast</string>+ <string name="context_type_description_search" formatted="false">Reproduciendo desde búsqueda</string>+ <string name="default_notification_channel_name" formatted="false">Está sonando</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Dispositivos</string>+ <string name="action_share_label" formatted="false">Compartir</string>+ <string name="action_queue_label" formatted="false">Añadir a la cola</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 hora</string>+ <string name="curation_actions_edit_button_title" formatted="false">Editar</string>+ <string name="content_description_pause_button" formatted="false">Pausa</string>+ <string name="content_description_play_button" formatted="false">Reproducir</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Aleatorio</string>+ <string name="np_content_desc_repeat" formatted="false">Repetir</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Temporizador de apagado</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">eliminar</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Mover</string>+ <string name="bottom_actions_close" formatted="false">Cerrar</string>+ <string name="add_to_queue_action_content_description" formatted="false">Añadir a la cola</string>+ <string name="curation_button_saved_text" formatted="false">Guardado</string>+ <string name="np_content_desc_prev" formatted="false">Anterior</string>+ <string name="np_content_desc_next" formatted="false">Siguiente</string>+ <string name="accessibility_navigate_back" formatted="false">Atrás</string>+ <string name="monthly_listeners_text" formatted="false">%1$s oyentes mensuales</string>+ <string name="profile_bio_show_less" formatted="false">Mostrar menos</string>+ <string name="audiobook_series_see_more_button" formatted="false">Mostrar más</string>+ <string name="popular_releases_section_title" formatted="false">Títulos populares</string>+ <string name="creator_biography_section_title" formatted="false">Información</string>+ <string name="fans_also_like_section_title" formatted="false">Sus fans también escuchan</string>+ <string name="appears_on_section_title" formatted="false">Aparece en</string>+ <string name="composer_section_button_show_all" formatted="false">Mostrar todo</string>+ <string name="releases_title" formatted="false">Publicaciones</string>+ <string name="artist_releases_albums" formatted="false">Álbumes</string>+ <string name="artist_releases_singles" formatted="false">Sencillos y EP</string>+ <string name="latest_release_title" formatted="false">Última publicación</string>+ <string name="artist_subtitle" formatted="false">Artista</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Búsquedas recientes</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Borrar</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Pódcasts</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episodios</string>+ <string name="assisted_curation_search_song" formatted="false">Canción</string>+ <string name="album" formatted="false">Álbum</string>+ <string name="album_type_podcast" formatted="false">Pódcast</string>+ <string name="recently_played_user_profile" formatted="false">Perfil</string>+ <string name="connect_device_menu_logout" formatted="false">Cerrar sesión</string>+ <string name="library_search_text_hint" formatted="false">Busca en Tu biblioteca</string>+ <string name="account_title" formatted="false">Cuenta</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Artistas que sigues</string>+ <string name="settings_item_crossfade_title" formatted="false">Crossfade</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Archivos locales</string>+ <string name="local_files_empty_section_title" formatted="false">Añade tus propios archivos de audio a Tu biblioteca</string>+ <string name="local_files_empty_section_subtitle" formatted="false">¿Tienes una canción o un pódcast personal que no está en Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Tus archivos de audio se mostrarán aquí</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Dar acceso</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Ir a Configuración</string>+ <string name="context_menu_download" formatted="false">Descargar</string>+ <string name="context_menu_undownload" formatted="false">Eliminar descarga</string>+ <string name="collection_downloaded" formatted="false">Descargas</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Descarga completada</string>+ <string name="download_badge_downloading_content_description" formatted="false">Descargando</string>+ <string name="download_badge_error_content_description" formatted="false">Error al descargar</string>+ <string name="download_notification_downloading" formatted="false">Descargando…</string>+ <string name="toast_undownload" formatted="false">Descarga retirada.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">¿Eliminar de descargas?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">No podrás escuchar este contenido sin conexión.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">eliminar</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Eliminar todas las descargas</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">¿Quieres eliminar todas las descargas?</string>+ <string name="album_type_album" formatted="false">Álbum</string>+ <string name="album_type_single" formatted="false">Sencillo</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Recopilatorio</string>+ <string name="assisted_curation_search_playlist" formatted="false">Lista</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Mejores resultados</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Canciones</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artistas</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Álbumes</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Listas</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Borrar filtro</string>+ <string name="ad_category_title_music" formatted="false">Música</string>+ <string name="made_for_you_hub_title" formatted="false">Especialmente para ti</string>+ <string name="settings_item_app_language_title" formatted="false">Idioma de la aplicación</string>+ <string name="create_menu_item_folder_title" formatted="false">Carpeta</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nueva carpeta</string>+ <string name="context_menu_rename_folder" formatted="false">Cambiar nombre de carpeta</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Nombre de la carpeta</string>+ <string name="create_playlist_content_description" formatted="false">Crear lista</string>+ <string name="actions_picker_delete" formatted="false">Eliminar</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Ordenar por</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Orden alfabético</string>+ <string name="your_library_sort_order_creator" formatted="false">Creador</string>+ <string name="your_library_sort_order_custom" formatted="false">Orden personalizado</string>+ <string name="settings_item_version_title" formatted="false">Versión</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Ir a radio de la canción</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Buscar en Canciones que te gustan</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Buscar en la lista</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">No hemos podido encontrar \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-es/strings.xml b/base/app/src/main/res/values-es/strings.xmlnew file mode 100644index 00000000..7313ecb0--- /dev/null+++ b/base/app/src/main/res/values-es/strings.xml@@ -0,0 +1,35 @@+<?xml version="1.0" encoding="utf-8"?>+<resources>+ <string name="app_name">Myspoti</string>+ <string name="aa_playlists">Playlists</string>+ <string name="aa_albums">Álbumes</string>+ <string name="aa_artists">Artistas</string>+ <string name="aa_podcasts">Podcasts</string>+ <string name="settings_amoled_theme">Tema AMOLED</string>+ <string name="settings_amoled_theme_subtitle">Fondo negro puro para ahorrar batería</string>+ <string name="settings_lyrics_style_spotify_default">Spotify predeterminado</string>+ <string name="settings_lyrics_style_fullscreen">Pantalla completa (colores del álbum)</string>+ <string name="settings_lyrics_style_compact">Compacto</string>+ <string name="settings_lyrics_style_karaoke">Karaoke</string>+ <string name="settings_lyrics_style_bold">Grande y en negrita</string>+ <string name="main_update_available">Hay una nueva actualización disponible</string>+ <string name="notif_channel_media_name">Reproducción multimedia</string>+ <string name="notif_channel_media_description">Controles de reproducción multimedia de Myspoti</string>+ <string name="notif_action_previous">Anterior</string>+ <string name="notif_action_next">Siguiente</string>+ <string name="notif_action_play">Reproducir</string>+ <string name="notif_action_pause">Pausar</string>+ <string name="notif_shuffle_enable">Activar reproducción aleatoria</string>+ <string name="notif_shuffle_disable">Desactivar reproducción aleatoria</string>+ <string name="notif_shuffle_disable_smart">Desactivar la reproducción aleatoria inteligente</string>+ <string name="notif_action_like">Me gusta</string>+ <string name="notif_action_unlike">Quitar \'Me gusta\'</string>+ <string name="notif_unknown_name">Desconocido</string>+ <string name="notif_by_artist">por %1$s</string>+ <string name="notif_repeat_disable">Desactivar repetición</string>+ <string name="notif_repeat_disable_one">Desactivar repetir canción</string>+ <string name="notif_repeat_enable">Activar repetición</string>+ <string name="bridge_player_unlocked">Reproductor desbloqueado</string>+ <string name="bridge_reloading">Recargando…</string>+ <string name="service_disabled_message">El servicio no está activado</string>+</resources>diff --git a/base/app/src/main/res/values-et/spotify_plurals.xml b/base/app/src/main/res/values-et/spotify_plurals.xmlnew file mode 100644index 00000000..73f20759--- /dev/null+++ b/base/app/src/main/res/values-et/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d laul</item>+ <item quantity="other">%1$d laulu</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d salvestamine</item>+ <item quantity="other">%1$,d salvestamist</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s esitusloend</item>+ <item quantity="other">%1$s esitusloendit</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s laul</item>+ <item quantity="other">%1$s laulu</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-et/spotify_strings.xml b/base/app/src/main/res/values-et/spotify_strings.xmlnew file mode 100644index 00000000..8ca8eacf--- /dev/null+++ b/base/app/src/main/res/values-et/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Lisa meeldivaks märgitud laulude hulka</string>+ <string name="collection_liked_songs_title" formatted="false">Meeldivaks märgitud laulud</string>+ <string name="context_menu_add_to_playlist" formatted="false">Lisa esitusloendisse</string>+ <string name="context_menu_play_next" formatted="false">Esita järgmisena</string>+ <string name="context_menu_add_to_queue" formatted="false">Lisa järjekorda</string>+ <string name="context_menu_go_to_queue" formatted="false">Ava järjekord</string>+ <string name="context_menu_browse_album" formatted="false">Ava album</string>+ <string name="context_menu_browse_artist" formatted="false">Ava artisti leht</string>+ <string name="context_menu_share" formatted="false">Jaga</string>+ <string name="context_menu_sleep_timer" formatted="false">Unetaimer</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Lülita taimer välja</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Pala lõpus</string>+ <string name="snackbar_added_to_queue" formatted="false">Lisati järjekorda</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Lisatud meeldivaks märgitud laulude hulka.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Eemaldatud meeldivaks märgitud laulude hulgast.</string>+ <string name="content_description_context_menu" formatted="false">Rohkem valikuid</string>+ <string name="close_button_content_description" formatted="false">Sulge</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Salvestuskoht</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Uus esitusloend</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Tühista</string>+ <string name="create_playlist_create_button" formatted="false">Loo</string>+ <string name="lyrics_card_title" formatted="false">Laulusõnad</string>+ <string name="lyrics_card_title_preview" formatted="false">Laulusõnade eelvaade</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Kuva laulusõnad</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Ava laulusõnad täisekraanrežiimis</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Laulusõnade jagamine</string>+ <string name="lyrics_credential_note" formatted="false">Laulusõnade ametlik levitaja: %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Jaga</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Tõlgi</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Sulge laulusõnad</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Tõlgi laulusõnad</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Peata laulusõnade tõlkimine</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Me ei tea selle laulu sõnu.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Neid laulusõnu ei saa veel sünkroonselt kuvada.</string>+ <string name="av_switch_to_video" formatted="false">Lülitu videole</string>+ <string name="av_switch_to_audio" formatted="false">Lülitu helile</string>+ <string name="av_content_desc" formatted="false">Lülita heli ja video vahel</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Avaleht</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Otsing</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Sinu teek</string>+ <string name="search_header_field_hint" formatted="false">Mida soovid kuulata?</string>+ <string name="filter_chip_all_label" formatted="false">Kõik</string>+ <string name="recents_content_filter_music" formatted="false">Muusika</string>+ <string name="ad_category_title_podcasts" formatted="false">Netisaated</string>+ <string name="audiobooks_title" formatted="false">Audioraamatud</string>+ <string name="artist_popular_tracks" formatted="false">Populaarsed</string>+ <string name="curation_button_follow_state_text" formatted="false">Jälgi</string>+ <string name="curation_button_following_state_text" formatted="false">Jälgin</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artist</string>+ <string name="connect_phone_is_self" formatted="false">See telefon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Lühikesed korduvad visuaalid laulu esitamise ajal.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Mitte praegu</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Uuenda</string>+ <string name="context_type_description_play_queue" formatted="false">Esitatakse esitusjärjekorrast</string>+ <string name="context_type_description_collection_your_library" formatted="false">Esitatakse sinu teegist</string>+ <string name="context_type_description_playlist" formatted="false">Esitatakse esitusloendist</string>+ <string name="context_type_description_album" formatted="false">Esitatakse albumilt</string>+ <string name="context_type_description_artist" formatted="false">Esitatakse artistilt</string>+ <string name="context_type_description_show" formatted="false">Esitatakse netisaates</string>+ <string name="context_type_description_search" formatted="false">Esitatakse otsingust</string>+ <string name="default_notification_channel_name" formatted="false">Hetkel mängimas</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Seadmed</string>+ <string name="action_share_label" formatted="false">Jaga</string>+ <string name="action_queue_label" formatted="false">Järjekord</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 tund</string>+ <string name="curation_actions_edit_button_title" formatted="false">Muuda</string>+ <string name="content_description_pause_button" formatted="false">Peata</string>+ <string name="content_description_play_button" formatted="false">Esita</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Juhuesitus</string>+ <string name="np_content_desc_repeat" formatted="false">Korda</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Unetaimer</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Eemalda</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Teisalda</string>+ <string name="bottom_actions_close" formatted="false">Sulge</string>+ <string name="add_to_queue_action_content_description" formatted="false">Lisa järjekorda</string>+ <string name="curation_button_saved_text" formatted="false">Salvestatud</string>+ <string name="np_content_desc_prev" formatted="false">Eelmine</string>+ <string name="np_content_desc_next" formatted="false">Edasi</string>+ <string name="accessibility_navigate_back" formatted="false">Tagasi</string>+ <string name="monthly_listeners_text" formatted="false">%1$s kuulajat kuus</string>+ <string name="profile_bio_show_less" formatted="false">Kuva vähem</string>+ <string name="audiobook_series_see_more_button" formatted="false">Kuva rohkem</string>+ <string name="popular_releases_section_title" formatted="false">Populaarsed salvestised</string>+ <string name="creator_biography_section_title" formatted="false">Teave</string>+ <string name="fans_also_like_section_title" formatted="false">Fännide teised lemmikud</string>+ <string name="appears_on_section_title" formatted="false">Lööb kaasa albumitel</string>+ <string name="composer_section_button_show_all" formatted="false">Kuva kõik</string>+ <string name="releases_title" formatted="false">Välja antud muusika</string>+ <string name="artist_releases_albums" formatted="false">Albumid</string>+ <string name="artist_releases_singles" formatted="false">Singlid ja EP-d</string>+ <string name="latest_release_title" formatted="false">Uusim salvestis</string>+ <string name="artist_subtitle" formatted="false">Artist</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Hiljutised otsingud</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Tühjenda</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Netisaated</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Jaod</string>+ <string name="assisted_curation_search_song" formatted="false">Laul</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Netisaade</string>+ <string name="recently_played_user_profile" formatted="false">Profiil</string>+ <string name="connect_device_menu_logout" formatted="false">Logi välja</string>+ <string name="library_search_text_hint" formatted="false">Otsi oma teegist</string>+ <string name="account_title" formatted="false">Konto</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Jälgiti artiste</string>+ <string name="settings_item_crossfade_title" formatted="false">Üleminek</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Kohalikud failid</string>+ <string name="local_files_empty_section_title" formatted="false">Lisa enda helifailid oma teeki</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Kas sul on mõni laul või isiklik netisaade, mida Spotifys pole?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Sinu helifailid kuvatakse siin</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Anna juurdepääs</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Ava sätted</string>+ <string name="context_menu_download" formatted="false">Laadi alla</string>+ <string name="context_menu_undownload" formatted="false">Eemalda allalaaditud fail</string>+ <string name="collection_downloaded" formatted="false">Allalaaditud</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Allalaaditud</string>+ <string name="download_badge_downloading_content_description" formatted="false">Allalaadimine</string>+ <string name="download_badge_error_content_description" formatted="false">Allalaadimine nurjus</string>+ <string name="download_notification_downloading" formatted="false">Allalaadimine…</string>+ <string name="toast_undownload" formatted="false">Allalaaditud fail on eemaldatud.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Kas eemaldada allalaaditud failide seast?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Seda ei saa võrguühenduseta esitada.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Eemalda</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Eemalda kõik allalaadimised</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Kas eemaldada kõik allalaadimised?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Singel</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Kogumik</string>+ <string name="assisted_curation_search_playlist" formatted="false">Esitusloend</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Parim tulemus</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Laulud</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artistid</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albumid</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Esitusloendid</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Tühjenda filter</string>+ <string name="ad_category_title_music" formatted="false">Muusika</string>+ <string name="made_for_you_hub_title" formatted="false">Sulle koostatud</string>+ <string name="settings_item_app_language_title" formatted="false">Rakenduse keel</string>+ <string name="create_menu_item_folder_title" formatted="false">Kaust</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Uus kaust</string>+ <string name="context_menu_rename_folder" formatted="false">Nimeta kaust ümber</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Kausta nimi</string>+ <string name="create_playlist_content_description" formatted="false">Loo esitusloend</string>+ <string name="actions_picker_delete" formatted="false">Kustuta</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Järjestamisalus</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Tähestikuline järjestus</string>+ <string name="your_library_sort_order_creator" formatted="false">Looja</string>+ <string name="your_library_sort_order_custom" formatted="false">Kohandatud järjestus</string>+ <string name="settings_item_version_title" formatted="false">Versioon</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Ava laulupõhine raadio</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Otsi meeldivaks märgitud laulude seast</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Otsi esitusloendist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Ei leitud: %1$s</string>+</resources>diff --git a/base/app/src/main/res/values-eu/spotify_plurals.xml b/base/app/src/main/res/values-eu/spotify_plurals.xmlnew file mode 100644index 00000000..f6155f7b--- /dev/null+++ b/base/app/src/main/res/values-eu/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d abesti</item>+ <item quantity="other">%1$d abesti</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d pertsonak gorde du</item>+ <item quantity="other">%1$,d pertsonak gorde dute</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s zerrenda</item>+ <item quantity="other">%1$s zerrenda</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s abesti</item>+ <item quantity="other">%1$s abesti</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-eu/spotify_strings.xml b/base/app/src/main/res/values-eu/spotify_strings.xmlnew file mode 100644index 00000000..bd585e1c--- /dev/null+++ b/base/app/src/main/res/values-eu/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Gehitu Gustatu zaizkizun abestietan</string>+ <string name="collection_liked_songs_title" formatted="false">Gustatu zaizkizun abestiak</string>+ <string name="context_menu_add_to_playlist" formatted="false">Gehitu zerrendan</string>+ <string name="context_menu_play_next" formatted="false">Erreproduzitu hurrengoa</string>+ <string name="context_menu_add_to_queue" formatted="false">Gehitu ilaran</string>+ <string name="context_menu_go_to_queue" formatted="false">Joan ilarara</string>+ <string name="context_menu_browse_album" formatted="false">Joan albumera</string>+ <string name="context_menu_browse_artist" formatted="false">Joan artistaren orrira</string>+ <string name="context_menu_share" formatted="false">Partekatu</string>+ <string name="context_menu_sleep_timer" formatted="false">Lotarako tenporizadorea</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Desaktibatu tenporizadorea</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Abestiaren amaiera</string>+ <string name="snackbar_added_to_queue" formatted="false">Gehitu da ilaran</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Gehitu da Gustatu zaizkizun abestietan.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Kendu da Gustatu zaizkizun abestietatik.</string>+ <string name="content_description_context_menu" formatted="false">Aukera gehiago</string>+ <string name="close_button_content_description" formatted="false">Itxi</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Hemen dago gordeta:</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Zerrenda berria</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Utzi</string>+ <string name="create_playlist_create_button" formatted="false">Sortu</string>+ <string name="lyrics_card_title" formatted="false">Hitzak</string>+ <string name="lyrics_card_title_preview" formatted="false">Hitzen aurrebista</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Erakutsi hitzak</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Ireki hitzak pantaila osoan</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Partekatu hitzak</string>+ <string name="lyrics_credential_note" formatted="false">Honek eskainitako hitzak: %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Partekatu</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Itzuli</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Hitzak ixteko</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Itzuli hitzak</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Letrak itzultzeari uzteko</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Mmm. Ez dakigu zer dioen abesti honek.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Hitz hauek ez daude sinkronizatuta oraindik.</string>+ <string name="av_switch_to_video" formatted="false">Aldatu bideora</string>+ <string name="av_switch_to_audio" formatted="false">Aldatu audiora</string>+ <string name="av_content_desc" formatted="false">Aldatu audioaren eta bideoaren artean</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Hasiera</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Bilatu</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Liburutegia</string>+ <string name="search_header_field_hint" formatted="false">Zer entzun nahi duzu?</string>+ <string name="filter_chip_all_label" formatted="false">Guztiak</string>+ <string name="recents_content_filter_music" formatted="false">Musika</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcastak</string>+ <string name="audiobooks_title" formatted="false">Audio-liburuak</string>+ <string name="artist_popular_tracks" formatted="false">Ezagunak</string>+ <string name="curation_button_follow_state_text" formatted="false">Jarraitu</string>+ <string name="curation_button_following_state_text" formatted="false">Jarraitzen</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artista</string>+ <string name="connect_phone_is_self" formatted="false">Telefono hau</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Irudi labur eta errepikakorrak abesti bat erreproduzitu bitartean.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Orain ez</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Eguneratu</string>+ <string name="context_type_description_play_queue" formatted="false">Erreprodukzio-ilaratik erreproduzitzen</string>+ <string name="context_type_description_collection_your_library" formatted="false">Liburutegitik erreproduzitzen</string>+ <string name="context_type_description_playlist" formatted="false">Zerrenda honetatik erreproduzitzen:</string>+ <string name="context_type_description_album" formatted="false">Albumetik erreproduzitzen</string>+ <string name="context_type_description_artist" formatted="false">Artistatik erreproduzitzen</string>+ <string name="context_type_description_show" formatted="false">Podcast honetatik erreproduzitzen:</string>+ <string name="context_type_description_search" formatted="false">Bilaketatik erreproduzitzen</string>+ <string name="default_notification_channel_name" formatted="false">Orain erreproduzitzen</string>+ <string name="label_bluetooth" formatted="false">Bluetootha</string>+ <string name="mr_user_route_category_name" formatted="false">Gailuak</string>+ <string name="action_share_label" formatted="false">Partekatu</string>+ <string name="action_queue_label" formatted="false">Ilara</string>+ <string name="mute_chat_duration_one_hour" formatted="false">Ordubetez</string>+ <string name="curation_actions_edit_button_title" formatted="false">Editatu</string>+ <string name="content_description_pause_button" formatted="false">Pausatu</string>+ <string name="content_description_play_button" formatted="false">Erreproduzitu</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Ausazko erreprodukzioa</string>+ <string name="np_content_desc_repeat" formatted="false">Errepikatu</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Lotarako tenporizadorea</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Kendu</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Mugitu</string>+ <string name="bottom_actions_close" formatted="false">Itxi</string>+ <string name="add_to_queue_action_content_description" formatted="false">Gehitu ilaran</string>+ <string name="curation_button_saved_text" formatted="false">Gordeta</string>+ <string name="np_content_desc_prev" formatted="false">Aurrekoa</string>+ <string name="np_content_desc_next" formatted="false">Egin aurrera</string>+ <string name="accessibility_navigate_back" formatted="false">Itzuli</string>+ <string name="monthly_listeners_text" formatted="false">%1$s entzule hilero</string>+ <string name="profile_bio_show_less" formatted="false">Erakutsi gutxiago</string>+ <string name="audiobook_series_see_more_button" formatted="false">Erakutsi gehiago</string>+ <string name="popular_releases_section_title" formatted="false">Kaleratze ezagunak</string>+ <string name="creator_biography_section_title" formatted="false">Honi buruz</string>+ <string name="fans_also_like_section_title" formatted="false">Zaleei hauek ere gustatzen zaizkie</string>+ <string name="appears_on_section_title" formatted="false">Hemen agertzen da</string>+ <string name="composer_section_button_show_all" formatted="false">Erakutsi guztiak</string>+ <string name="releases_title" formatted="false">Kaleratze berriak</string>+ <string name="artist_releases_albums" formatted="false">Albumak</string>+ <string name="artist_releases_singles" formatted="false">Singleak eta EPak</string>+ <string name="latest_release_title" formatted="false">Azken kaleratzea</string>+ <string name="artist_subtitle" formatted="false">Artista</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Azken bilaketak</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Garbitu</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcastak</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Atalak</string>+ <string name="assisted_curation_search_song" formatted="false">Abestia</string>+ <string name="album" formatted="false">Albuma</string>+ <string name="album_type_podcast" formatted="false">Podcasta</string>+ <string name="recently_played_user_profile" formatted="false">Profila</string>+ <string name="connect_device_menu_logout" formatted="false">Amaitu saioa</string>+ <string name="library_search_text_hint" formatted="false">Bilatu Liburutegian</string>+ <string name="account_title" formatted="false">Kontua</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Jarraitutako artistak</string>+ <string name="settings_item_crossfade_title" formatted="false">Gainjartze gurutzatua</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Fitxategi lokalak</string>+ <string name="local_files_empty_section_title" formatted="false">Gehitu gailuko audio-fitxategiak Liburutegian</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Spotify-n ez dauden abesti edo podcast pertsonalak dauzkazu?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Gailuko audio-fitxategiak hemen agertuko dira</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Eman sarbidea</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Joan ezarpenetara</string>+ <string name="context_menu_download" formatted="false">Deskargatu</string>+ <string name="context_menu_undownload" formatted="false">Kendu deskarga</string>+ <string name="collection_downloaded" formatted="false">Deskargatutakoak</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Deskargatutakoak</string>+ <string name="download_badge_downloading_content_description" formatted="false">Deskargatzen</string>+ <string name="download_badge_error_content_description" formatted="false">Ezin izan da deskargatu</string>+ <string name="download_notification_downloading" formatted="false">Deskargatzen…</string>+ <string name="toast_undownload" formatted="false">Kendu da deskargetatik.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Deskargetatik kendu nahi duzu?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Ezin izango duzu konexiorik gabe erreproduzitu.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Kendu</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Kendu deskarga guztiak</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Deskarga guztiak kendu nahi dituzu?</string>+ <string name="album_type_album" formatted="false">Albuma</string>+ <string name="album_type_single" formatted="false">Singlea</string>+ <string name="album_type_ep" formatted="false">EPa</string>+ <string name="album_type_compilation" formatted="false">Bilduma</string>+ <string name="assisted_curation_search_playlist" formatted="false">Zerrenda</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Nagusiak</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Abestiak</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artistak</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albumak</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Zerrendak</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Garbitu iragazkia</string>+ <string name="ad_category_title_music" formatted="false">Musika</string>+ <string name="made_for_you_hub_title" formatted="false">Zuretzat eginak</string>+ <string name="settings_item_app_language_title" formatted="false">Aplikazioaren hizkuntza</string>+ <string name="create_menu_item_folder_title" formatted="false">Karpeta</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Karpeta berria</string>+ <string name="context_menu_rename_folder" formatted="false">Aldatu karpetaren izena</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Karpetaren izena</string>+ <string name="create_playlist_content_description" formatted="false">Sortu zerrenda bat</string>+ <string name="actions_picker_delete" formatted="false">Ezabatu</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Ordenatzeko irizpidea</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alfabetikoki</string>+ <string name="your_library_sort_order_creator" formatted="false">Sortzailea</string>+ <string name="your_library_sort_order_custom" formatted="false">Ordena pertsonalizatua</string>+ <string name="settings_item_version_title" formatted="false">Bertsioa</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Joan abestiaren irratira</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Bilatu Gustatu zaizkizun abestietan</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Bilatu zerrendan</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Ezin izan da aurkitu \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-fa/spotify_plurals.xml b/base/app/src/main/res/values-fa/spotify_plurals.xmlnew file mode 100644index 00000000..031eebee--- /dev/null+++ b/base/app/src/main/res/values-fa/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d آهنگ</item>+ <item quantity="other">%1$d آهنگ</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d ذخیره</item>+ <item quantity="other">%1$,d ذخیره</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s فهرست پخش</item>+ <item quantity="other">%1$s فهرست پخش</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s آهنگ</item>+ <item quantity="other">%1$s آهنگ</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-fa/spotify_strings.xml b/base/app/src/main/res/values-fa/spotify_strings.xmlnew file mode 100644index 00000000..e805632e--- /dev/null+++ b/base/app/src/main/res/values-fa/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">افزودن به «آهنگهای پسندیدهشده»</string>+ <string name="collection_liked_songs_title" formatted="false">آهنگهایی که پسندیدهاید</string>+ <string name="context_menu_add_to_playlist" formatted="false">افزودن به فهرست پخش</string>+ <string name="context_menu_play_next" formatted="false">پخش بعدی</string>+ <string name="context_menu_add_to_queue" formatted="false">افزودن به صف پخش</string>+ <string name="context_menu_go_to_queue" formatted="false">رفتن به صف پخش</string>+ <string name="context_menu_browse_album" formatted="false">رفتن به آلبوم</string>+ <string name="context_menu_browse_artist" formatted="false">رفتن به هنرمند</string>+ <string name="context_menu_share" formatted="false">همرسانی</string>+ <string name="context_menu_sleep_timer" formatted="false">تایمر خواب</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">خاموش کردن تایمر</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">پایان قطعه</string>+ <string name="snackbar_added_to_queue" formatted="false">به صف پخش اضافه شد</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">به آهنگهای پسندیده اضافه شد.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">از آهنگهای پسندیده حذف شد.</string>+ <string name="content_description_context_menu" formatted="false">گزینههای بیشتر</string>+ <string name="close_button_content_description" formatted="false">بستن</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">ذخیرهشده در</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">فهرست پخش جدید</string>+ <string name="add_to_playlist_button_cancel" formatted="false">لغو</string>+ <string name="create_playlist_create_button" formatted="false">ایجاد کردن</string>+ <string name="lyrics_card_title" formatted="false">متن ترانهها</string>+ <string name="lyrics_card_title_preview" formatted="false">پیشنمایش متن ترانه</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">نمایش متن ترانه</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">باز کردن تمامصفحه متن ترانه</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">همرسانی متن ترانه</string>+ <string name="lyrics_credential_note" formatted="false">متن ترانه از %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">همرسانی</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">ترجمه</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">بستن متن ترانه</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">ترجمه متن ترانه</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">توقف ترجمه متن ترانه</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">اووم. متن ترانه این آهنگ را نمیدانیم.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">این متن ترانهها هنوز همگامسازی زمانی نشدهاند.</string>+ <string name="av_switch_to_video" formatted="false">تغییر دادن به پخش تصویری</string>+ <string name="av_switch_to_audio" formatted="false">تغییر دادن به پخش صوتی</string>+ <string name="av_content_desc" formatted="false">جابهجایی بین صدا و تصویر</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">صفحه اصلی</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">جستجو</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">کتابخانه شما</string>+ <string name="search_header_field_hint" formatted="false">میخواهید به چه گوش کنید؟</string>+ <string name="filter_chip_all_label" formatted="false">همه</string>+ <string name="recents_content_filter_music" formatted="false">موسیقی</string>+ <string name="ad_category_title_podcasts" formatted="false">پادکستها</string>+ <string name="audiobooks_title" formatted="false">کتابهای صوتی</string>+ <string name="artist_popular_tracks" formatted="false">پرطرفدار</string>+ <string name="curation_button_follow_state_text" formatted="false">دنبال کردن</string>+ <string name="curation_button_following_state_text" formatted="false">دنبال میکنید</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">هنرمند</string>+ <string name="connect_phone_is_self" formatted="false">این تلفن</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">تصاویر کوتاه و تکرارشونده هنگام پخش آهنگ.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">حالا نه</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">بهروزرسانی</string>+ <string name="context_type_description_play_queue" formatted="false">درحال پخش از صف پخش</string>+ <string name="context_type_description_collection_your_library" formatted="false">پخش از «کتابخانه شما»</string>+ <string name="context_type_description_playlist" formatted="false">درحال پخش از فهرست پخش</string>+ <string name="context_type_description_album" formatted="false">درحال پخش از آلبوم</string>+ <string name="context_type_description_artist" formatted="false">درحال پخش از هنرمند</string>+ <string name="context_type_description_show" formatted="false">پخش از پادکست</string>+ <string name="context_type_description_search" formatted="false">درحال پخش از جستجو</string>+ <string name="default_notification_channel_name" formatted="false">درحال پخش</string>+ <string name="label_bluetooth" formatted="false">بلوتوث</string>+ <string name="mr_user_route_category_name" formatted="false">دستگاهها</string>+ <string name="action_share_label" formatted="false">همرسانی</string>+ <string name="action_queue_label" formatted="false">صف پخش</string>+ <string name="mute_chat_duration_one_hour" formatted="false">۱ ساعت</string>+ <string name="curation_actions_edit_button_title" formatted="false">ویرایش</string>+ <string name="content_description_pause_button" formatted="false">مکث</string>+ <string name="content_description_play_button" formatted="false">پخش</string>+ <string name="play_mode_item_shuffle_title" formatted="false">پخش درهم</string>+ <string name="np_content_desc_repeat" formatted="false">تکرار</string>+ <string name="np_content_desc_sleep_timer" formatted="false">تایمر خواب</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">برداشتن</string>+ <string name="edit_playlist_items_move_chip" formatted="false">انتقال</string>+ <string name="bottom_actions_close" formatted="false">بستن</string>+ <string name="add_to_queue_action_content_description" formatted="false">افزودن به صف پخش</string>+ <string name="curation_button_saved_text" formatted="false">ذخیره شده</string>+ <string name="np_content_desc_prev" formatted="false">قبلی</string>+ <string name="np_content_desc_next" formatted="false">بعدی</string>+ <string name="accessibility_navigate_back" formatted="false">برگشتن</string>+ <string name="monthly_listeners_text" formatted="false">%1$s شنونده ماهانه</string>+ <string name="profile_bio_show_less" formatted="false">نمایش کمتر</string>+ <string name="audiobook_series_see_more_button" formatted="false">نمایش بیشتر</string>+ <string name="popular_releases_section_title" formatted="false">تولیدات محبوب</string>+ <string name="creator_biography_section_title" formatted="false">درباره</string>+ <string name="fans_also_like_section_title" formatted="false">طرفداران اینها را هم دوست دارند</string>+ <string name="appears_on_section_title" formatted="false">با حضور هنرمند</string>+ <string name="composer_section_button_show_all" formatted="false">نمایش همه</string>+ <string name="releases_title" formatted="false">تولیدات</string>+ <string name="artist_releases_albums" formatted="false">آلبومها</string>+ <string name="artist_releases_singles" formatted="false">تکآهنگها و آلبومهای کوچک</string>+ <string name="latest_release_title" formatted="false">آخرین تولید</string>+ <string name="artist_subtitle" formatted="false">هنرمند</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">جستجوهای اخیر</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">پاک کردن</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">پادکستها</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">قسمتها</string>+ <string name="assisted_curation_search_song" formatted="false">آهنگ</string>+ <string name="album" formatted="false">آلبوم</string>+ <string name="album_type_podcast" formatted="false">پادکست</string>+ <string name="recently_played_user_profile" formatted="false">نمایه</string>+ <string name="connect_device_menu_logout" formatted="false">خروج از سیستم</string>+ <string name="library_search_text_hint" formatted="false">جستجو در «کتابخانه شما»</string>+ <string name="account_title" formatted="false">حساب</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">هنرمند دنبالشده</string>+ <string name="settings_item_crossfade_title" formatted="false">پخش محوشدنی</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d ثانیه</string>+ <string name="local_files_title" formatted="false">فایلهای محلی</string>+ <string name="local_files_empty_section_title" formatted="false">فایلهای صوتی را به «کتابخانه شما» اضافه کنید</string>+ <string name="local_files_empty_section_subtitle" formatted="false">آهنگ یا پادکستی شخصی دارید که در اسپاتیفای نیست؟</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">فایلهای صوتی اینجا ظاهر میشوند</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">دسترسی مجاز است</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">رفتن به «تنظیمات»</string>+ <string name="context_menu_download" formatted="false">بارگیری</string>+ <string name="context_menu_undownload" formatted="false">حذف مورد بارگیریشده</string>+ <string name="collection_downloaded" formatted="false">بارگیریشدهها</string>+ <string name="download_badge_downloaded_content_description" formatted="false">بارگیریشد</string>+ <string name="download_badge_downloading_content_description" formatted="false">درحال بارگیری</string>+ <string name="download_badge_error_content_description" formatted="false">بارگیری ناموفق بود</string>+ <string name="download_notification_downloading" formatted="false">در حال بارگیری…</string>+ <string name="toast_undownload" formatted="false">مورد بارگیریشده حذف شد.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">از بارگیریشدهها حذف شود؟</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">دیگر نمیتوانید این مورد را آفلاین پخش کنید.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">حذف کردن</string>+ <string name="settings_item_remove_downloads_title" formatted="false">حذف همه محتوای بارگیریشده</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">همه محتوای بارگیریشده حذف شود؟</string>+ <string name="album_type_album" formatted="false">آلبوم</string>+ <string name="album_type_single" formatted="false">تکآهنگ</string>+ <string name="album_type_ep" formatted="false">آلبوم کوچک</string>+ <string name="album_type_compilation" formatted="false">گردآوریشده</string>+ <string name="assisted_curation_search_playlist" formatted="false">فهرست پخش</string>+ <string name="assisted_curation_search_filter_top" formatted="false">برترینها</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">آهنگها</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">هنرمندان</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">آلبومها</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">فهرستهای پخش</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">پاک کردن فیلترها</string>+ <string name="ad_category_title_music" formatted="false">موسیقی</string>+ <string name="made_for_you_hub_title" formatted="false">سفارشی برای شما</string>+ <string name="settings_item_app_language_title" formatted="false">زبان برنامه</string>+ <string name="create_menu_item_folder_title" formatted="false">پوشه</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">پوشه جدید</string>+ <string name="context_menu_rename_folder" formatted="false">تغییر نام پوشه</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">نام پوشه</string>+ <string name="create_playlist_content_description" formatted="false">ایجاد فهرست پخش</string>+ <string name="actions_picker_delete" formatted="false">حذف کردن</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">بهترتیب</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">بهترتیب حروف الفبا</string>+ <string name="your_library_sort_order_creator" formatted="false">محتواساز</string>+ <string name="your_library_sort_order_custom" formatted="false">ترتیب سفارشی</string>+ <string name="settings_item_version_title" formatted="false">نسخه</string>+ <string name="context_menu_go_to_song_radio" formatted="false">رفتن به رادیوی آهنگ</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">یافتن در آهنگهای پسندیدهشده</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">یافتن در فهرست پخش</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">«%1$s» پیدا نشد</string>+</resources>diff --git a/base/app/src/main/res/values-fi/spotify_plurals.xml b/base/app/src/main/res/values-fi/spotify_plurals.xmlnew file mode 100644index 00000000..79dd3a22--- /dev/null+++ b/base/app/src/main/res/values-fi/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d kappale</item>+ <item quantity="other">%1$d kappaletta</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d tallennus</item>+ <item quantity="other">%1$,d tallennusta</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s soittolista</item>+ <item quantity="other">%1$s soittolistaa</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s kappale</item>+ <item quantity="other">%1$s kappaletta</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-fi/spotify_strings.xml b/base/app/src/main/res/values-fi/spotify_strings.xmlnew file mode 100644index 00000000..1c89b4cc--- /dev/null+++ b/base/app/src/main/res/values-fi/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Lisää tykättyihin kappaleisiin</string>+ <string name="collection_liked_songs_title" formatted="false">Tykätyt kappaleet</string>+ <string name="context_menu_add_to_playlist" formatted="false">Lisää soittolistaan</string>+ <string name="context_menu_play_next" formatted="false">Toista seuraavaksi</string>+ <string name="context_menu_add_to_queue" formatted="false">Lisää jonoon</string>+ <string name="context_menu_go_to_queue" formatted="false">Siirry jonoon</string>+ <string name="context_menu_browse_album" formatted="false">Siirry albumiin</string>+ <string name="context_menu_browse_artist" formatted="false">Siirry artistiin</string>+ <string name="context_menu_share" formatted="false">Jaa</string>+ <string name="context_menu_sleep_timer" formatted="false">Uniajastin</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Kytke ajastin pois käytöstä</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Kappaleen loppu</string>+ <string name="snackbar_added_to_queue" formatted="false">Lisätty jonoon</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Lisätty tykättyihin kappaleisiin.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Poistettu tykätyistä kappaleista.</string>+ <string name="content_description_context_menu" formatted="false">Lisää vaihtoehtoja</string>+ <string name="close_button_content_description" formatted="false">Sulje</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Tallennuspaikka</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Uusi soittolista</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Peruuta</string>+ <string name="create_playlist_create_button" formatted="false">Luo</string>+ <string name="lyrics_card_title" formatted="false">Sanat</string>+ <string name="lyrics_card_title_preview" formatted="false">Sanojen esikatselu</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Näytä sanat</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Avaa sanat koko näytön tilassa</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Jaa sanat</string>+ <string name="lyrics_credential_note" formatted="false">Sanat tarjoaa %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Jaa</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Käännä</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Sulje sanat</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Käännä sanat</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Lopeta sanojen kääntäminen</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Emme tiedä tämän sanoja.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Näitä sanoja ei ole vielä synkronoitu.</string>+ <string name="av_switch_to_video" formatted="false">Vaihda videoon</string>+ <string name="av_switch_to_audio" formatted="false">Vaihda ääneen</string>+ <string name="av_content_desc" formatted="false">Vaihda äänen ja videon välillä</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Koti</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Haku</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Oma kirjasto</string>+ <string name="search_header_field_hint" formatted="false">Mitä haluaisit kuunnella?</string>+ <string name="filter_chip_all_label" formatted="false">Kaikki</string>+ <string name="recents_content_filter_music" formatted="false">Musiikki</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcastit</string>+ <string name="audiobooks_title" formatted="false">Äänikirjat</string>+ <string name="artist_popular_tracks" formatted="false">Suositut</string>+ <string name="curation_button_follow_state_text" formatted="false">Seuraa</string>+ <string name="curation_button_following_state_text" formatted="false">Seurataan</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artisti</string>+ <string name="connect_phone_is_self" formatted="false">Tämä puhelin</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Lyhyet videosilmukat kappaleen soidessa.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Ei nyt</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Päivitä</string>+ <string name="context_type_description_play_queue" formatted="false">Toistetaan toistojonosta</string>+ <string name="context_type_description_collection_your_library" formatted="false">Toistetaan kirjastosta</string>+ <string name="context_type_description_playlist" formatted="false">Toistetaan soittolistasta</string>+ <string name="context_type_description_album" formatted="false">Toistetaan albumilta</string>+ <string name="context_type_description_artist" formatted="false">Kuunnellaan artistia</string>+ <string name="context_type_description_show" formatted="false">Toistetaan podcastista</string>+ <string name="context_type_description_search" formatted="false">Toistetaan hakutuloksista</string>+ <string name="default_notification_channel_name" formatted="false">Nyt toistetaan</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Laitteet</string>+ <string name="action_share_label" formatted="false">Jaa</string>+ <string name="action_queue_label" formatted="false">Jono</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 tunti</string>+ <string name="curation_actions_edit_button_title" formatted="false">Muokkaa</string>+ <string name="content_description_pause_button" formatted="false">Tauko</string>+ <string name="content_description_play_button" formatted="false">Toisto</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Satunnaistoisto</string>+ <string name="np_content_desc_repeat" formatted="false">Toista uudelleen</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Nukahtamisajastin</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Poista</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Siirrä</string>+ <string name="bottom_actions_close" formatted="false">Sulje</string>+ <string name="add_to_queue_action_content_description" formatted="false">Lisää jonoon</string>+ <string name="curation_button_saved_text" formatted="false">Tallennettu</string>+ <string name="np_content_desc_prev" formatted="false">Edellinen</string>+ <string name="np_content_desc_next" formatted="false">Seuraava</string>+ <string name="accessibility_navigate_back" formatted="false">Takaisin</string>+ <string name="monthly_listeners_text" formatted="false">%1$s kuuntelijaa kuukaudessa</string>+ <string name="profile_bio_show_less" formatted="false">Näytä vähemmän</string>+ <string name="audiobook_series_see_more_button" formatted="false">Näytä enemmän</string>+ <string name="popular_releases_section_title" formatted="false">Suositut julkaisut</string>+ <string name="creator_biography_section_title" formatted="false">Tietoja</string>+ <string name="fans_also_like_section_title" formatted="false">Fanien kuuntelulistalla</string>+ <string name="appears_on_section_title" formatted="false">Mukana näissä</string>+ <string name="composer_section_button_show_all" formatted="false">Näytä kaikki</string>+ <string name="releases_title" formatted="false">Julkaisut</string>+ <string name="artist_releases_albums" formatted="false">Albumit</string>+ <string name="artist_releases_singles" formatted="false">Singlet ja EP:t</string>+ <string name="latest_release_title" formatted="false">Uusin julkaisu</string>+ <string name="artist_subtitle" formatted="false">Artisti</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Viimeisimmät haut</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Tyhjennä</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcastit</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Jaksot</string>+ <string name="assisted_curation_search_song" formatted="false">Kappale</string>+ <string name="album" formatted="false">Albumi</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profiili</string>+ <string name="connect_device_menu_logout" formatted="false">Kirjaudu ulos</string>+ <string name="library_search_text_hint" formatted="false">Hae omasta kirjastosta</string>+ <string name="account_title" formatted="false">Tili</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Seuratut artistit</string>+ <string name="settings_item_crossfade_title" formatted="false">Ristihäivytys</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Paikalliset tiedostot</string>+ <string name="local_files_empty_section_title" formatted="false">Lisää omia äänitiedostoja Omaan kirjastoon</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Onko sinulla kappale tai henkilökohtainen podcast, jota ei ole Spotifyssa?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Äänitiedostosi näkyvät tässä</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Anna lupa</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Siirry asetuksiin</string>+ <string name="context_menu_download" formatted="false">Lataa</string>+ <string name="context_menu_undownload" formatted="false">Poista lataus</string>+ <string name="collection_downloaded" formatted="false">Ladattu</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Ladattu</string>+ <string name="download_badge_downloading_content_description" formatted="false">Ladataan</string>+ <string name="download_badge_error_content_description" formatted="false">Lataus epäonnistui</string>+ <string name="download_notification_downloading" formatted="false">Ladataan…</string>+ <string name="toast_undownload" formatted="false">Ladattu sisältö on poistettu.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Poistetaanko latauksista?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Et voi jatkossa kuunnella sitä offline-tilassa.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Poista</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Poista kaikki lataukset</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Poistetaanko kaikki lataukset?</string>+ <string name="album_type_album" formatted="false">Albumi</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Kokoelma</string>+ <string name="assisted_curation_search_playlist" formatted="false">Soittolista</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Suosituimmat</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Kappaleet</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artistit</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albumit</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Soittolistat</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Poista suodatin</string>+ <string name="ad_category_title_music" formatted="false">Musiikki</string>+ <string name="made_for_you_hub_title" formatted="false">Luotu sinulle</string>+ <string name="settings_item_app_language_title" formatted="false">Sovelluksen kieli</string>+ <string name="create_menu_item_folder_title" formatted="false">Kansio</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Uusi kansio</string>+ <string name="context_menu_rename_folder" formatted="false">Nimeä kansio uudelleen</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Kansion nimi</string>+ <string name="create_playlist_content_description" formatted="false">Luo soittolista</string>+ <string name="actions_picker_delete" formatted="false">Poista</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Lajitteluperuste:</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Aakkosjärjestys</string>+ <string name="your_library_sort_order_creator" formatted="false">Tekijä</string>+ <string name="your_library_sort_order_custom" formatted="false">Mukautettu järjestys</string>+ <string name="settings_item_version_title" formatted="false">Versio</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Siirry kappaleradioon</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Hae tykätyistä kappaleista</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Hae soittolistasta</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Emme löytäneet tuloksia haulle %1$s</string>+</resources>diff --git a/base/app/src/main/res/values-fr-rCA/spotify_plurals.xml b/base/app/src/main/res/values-fr-rCA/spotify_plurals.xmlnew file mode 100644index 00000000..b0e86d8d--- /dev/null+++ b/base/app/src/main/res/values-fr-rCA/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d chanson</item>+ <item quantity="other">%1$d chansons</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d sauvegarde</item>+ <item quantity="other">%1$,d enregistrements</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s liste de lecture</item>+ <item quantity="other">%1$s listes de lecture</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s chanson</item>+ <item quantity="other">%1$s chansons</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-fr-rCA/spotify_strings.xml b/base/app/src/main/res/values-fr-rCA/spotify_strings.xmlnew file mode 100644index 00000000..2f8dab97--- /dev/null+++ b/base/app/src/main/res/values-fr-rCA/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Ajouter aux chansons aimées</string>+ <string name="collection_liked_songs_title" formatted="false">Chansons aimées</string>+ <string name="context_menu_add_to_playlist" formatted="false">Ajouter à une liste de lecture</string>+ <string name="context_menu_play_next" formatted="false">Faire jouer ensuite</string>+ <string name="context_menu_add_to_queue" formatted="false">Ajouter à la file d\'attente</string>+ <string name="context_menu_go_to_queue" formatted="false">Accéder à la file d\'attente</string>+ <string name="context_menu_browse_album" formatted="false">Accéder à l\'album</string>+ <string name="context_menu_browse_artist" formatted="false">Voir l\'artiste</string>+ <string name="context_menu_share" formatted="false">Partager</string>+ <string name="context_menu_sleep_timer" formatted="false">Minuterie du mode veille</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Désactiver la minuterie</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Fin de la chanson</string>+ <string name="snackbar_added_to_queue" formatted="false">Contenu ajouté à la file d\'attente</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Ajoutée aux Chansons aimées.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Supprimée des Chansons aimées.</string>+ <string name="content_description_context_menu" formatted="false">Plus d\'options</string>+ <string name="close_button_content_description" formatted="false">Fermer</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Enregistrées dans</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nouvelle liste de lecture</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Annuler</string>+ <string name="create_playlist_create_button" formatted="false">Créer</string>+ <string name="lyrics_card_title" formatted="false">Paroles</string>+ <string name="lyrics_card_title_preview" formatted="false">Aperçu des paroles</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Afficher les paroles</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Afficher les paroles en plein écran</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Partager les paroles</string>+ <string name="lyrics_credential_note" formatted="false">Paroles fournies par %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Partager</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Traduire</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Fermer les paroles</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Traduire les paroles</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Arrêter de traduire les paroles</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hum. Nous ne connaissons pas les paroles de cette chanson.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Ces paroles ne sont pas encore synchronisées.</string>+ <string name="av_switch_to_video" formatted="false">Passer à la vidéo</string>+ <string name="av_switch_to_audio" formatted="false">Passer à l\'audio</string>+ <string name="av_content_desc" formatted="false">Basculer entre l\'audio et la vidéo</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Accueil</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Rechercher</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Votre Bibliothèque</string>+ <string name="search_header_field_hint" formatted="false">Que voulez-vous écouter?</string>+ <string name="filter_chip_all_label" formatted="false">Tout</string>+ <string name="recents_content_filter_music" formatted="false">Musique</string>+ <string name="ad_category_title_podcasts" formatted="false">Balados</string>+ <string name="audiobooks_title" formatted="false">Livres audio</string>+ <string name="artist_popular_tracks" formatted="false">Populaire</string>+ <string name="curation_button_follow_state_text" formatted="false">Suivre</string>+ <string name="curation_button_following_state_text" formatted="false">Suivi</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artiste</string>+ <string name="connect_phone_is_self" formatted="false">Ce téléphone</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Courts contenus visuels en boucle pendant la lecture d\'une chanson.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Pas maintenant</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Mettre à jour</string>+ <string name="context_type_description_play_queue" formatted="false">Lecture à partir de la file d\'attente</string>+ <string name="context_type_description_collection_your_library" formatted="false">Lecture à partir de la Bibliothèque</string>+ <string name="context_type_description_playlist" formatted="false">Lecture à partir de Liste de lecture</string>+ <string name="context_type_description_album" formatted="false">Lecture à partir de l\'album</string>+ <string name="context_type_description_artist" formatted="false">Lecture à partir de l\'artiste</string>+ <string name="context_type_description_show" formatted="false">Lecture à partir du balado</string>+ <string name="context_type_description_search" formatted="false">Lecture à partir des résultats de recherche</string>+ <string name="default_notification_channel_name" formatted="false">En cours de lecture</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Appareils</string>+ <string name="action_share_label" formatted="false">Partager</string>+ <string name="action_queue_label" formatted="false">File d\'attente</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 heure</string>+ <string name="curation_actions_edit_button_title" formatted="false">Modifier</string>+ <string name="content_description_pause_button" formatted="false">Pause</string>+ <string name="content_description_play_button" formatted="false">Lecture</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Lecture aléatoire</string>+ <string name="np_content_desc_repeat" formatted="false">Répéter</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Minuteur de veille</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Supprimer</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Déplacer</string>+ <string name="bottom_actions_close" formatted="false">Fermer</string>+ <string name="add_to_queue_action_content_description" formatted="false">Ajouter à la file d\'attente</string>+ <string name="curation_button_saved_text" formatted="false">Enregistré</string>+ <string name="np_content_desc_prev" formatted="false">Précédent</string>+ <string name="np_content_desc_next" formatted="false">Suivant</string>+ <string name="accessibility_navigate_back" formatted="false">Précédent</string>+ <string name="monthly_listeners_text" formatted="false">%1$s auditeurs mensuels</string>+ <string name="profile_bio_show_less" formatted="false">Afficher moins</string>+ <string name="audiobook_series_see_more_button" formatted="false">Afficher plus</string>+ <string name="popular_releases_section_title" formatted="false">Sorties populaires</string>+ <string name="creator_biography_section_title" formatted="false">À propos</string>+ <string name="fans_also_like_section_title" formatted="false">Les adeptes aiment aussi</string>+ <string name="appears_on_section_title" formatted="false">Figure sur</string>+ <string name="composer_section_button_show_all" formatted="false">Tout afficher</string>+ <string name="releases_title" formatted="false">Sorties</string>+ <string name="artist_releases_albums" formatted="false">Albums</string>+ <string name="artist_releases_singles" formatted="false">Chansons et microalbums</string>+ <string name="latest_release_title" formatted="false">Sortie récente</string>+ <string name="artist_subtitle" formatted="false">Artiste</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Recherches récentes</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Effacer</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Balados</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Épisodes</string>+ <string name="assisted_curation_search_song" formatted="false">Chanson</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Balado</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Se déconnecter</string>+ <string name="library_search_text_hint" formatted="false">Recherche dans votre bibliothèque</string>+ <string name="account_title" formatted="false">Compte</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Artistes suivis</string>+ <string name="settings_item_crossfade_title" formatted="false">Fondu enchaîné</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Fichiers locaux</string>+ <string name="local_files_empty_section_title" formatted="false">Ajoutez vos propres fichiers audio à votre Bibliothèque</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Vous avez une chanson ou un balado personnel qui n\'est pas sur Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Vos fichiers audio seront affichés ici</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Donner accès</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Accéder aux paramètres</string>+ <string name="context_menu_download" formatted="false">Télécharger</string>+ <string name="context_menu_undownload" formatted="false">Supprimer le téléchargement</string>+ <string name="collection_downloaded" formatted="false">Téléchargés</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Téléchargé</string>+ <string name="download_badge_downloading_content_description" formatted="false">Téléchargement en cours</string>+ <string name="download_badge_error_content_description" formatted="false">Échec du téléchargement</string>+ <string name="download_notification_downloading" formatted="false">Téléchargement en cours…</string>+ <string name="toast_undownload" formatted="false">Téléchargement supprimé.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Voulez-vous supprimer cet élément des téléchargements?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Vous ne serez pas en mesure de faire jouer ce contenu en mode hors connexion.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Supprimer</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Supprimer les téléchargements</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Supprimer tous les téléchargements?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Simple</string>+ <string name="album_type_ep" formatted="false">Microalbum</string>+ <string name="album_type_compilation" formatted="false">Compilation</string>+ <string name="assisted_curation_search_playlist" formatted="false">Liste de lecture</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Meilleurs résultats</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Chansons</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artistes</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albums</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Listes de lecture</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Effacer le filtre</string>+ <string name="ad_category_title_music" formatted="false">Musique</string>+ <string name="made_for_you_hub_title" formatted="false">Juste pour vous</string>+ <string name="settings_item_app_language_title" formatted="false">Langue de l\'appli</string>+ <string name="create_menu_item_folder_title" formatted="false">Dossier</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nouveau dossier</string>+ <string name="context_menu_rename_folder" formatted="false">Renommer le dossier</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Nom du dossier</string>+ <string name="create_playlist_content_description" formatted="false">Créer une liste de lecture</string>+ <string name="actions_picker_delete" formatted="false">Supprimer</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Trier par</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alphabétique</string>+ <string name="your_library_sort_order_creator" formatted="false">Créateur</string>+ <string name="your_library_sort_order_custom" formatted="false">Ordre personnalisé</string>+ <string name="settings_item_version_title" formatted="false">Version</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Aller à la radio liée à la chanson</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Rechercher dans les chansons aimées</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Trouver dans la liste de lecture</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Impossible de trouver « %1$s »</string>+</resources>diff --git a/base/app/src/main/res/values-fr/myspoti_strings.xml b/base/app/src/main/res/values-fr/myspoti_strings.xmlnew file mode 100644index 00000000..4a9e81e0--- /dev/null+++ b/base/app/src/main/res/values-fr/myspoti_strings.xml@@ -0,0 +1,173 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Myspoti's own texts (English default, French). -->+<resources>+ <string name="welcome_tagline">Ta musique, avec les paroles synchronisées et les clips officiels.</string>+ <string name="welcome_login">Se connecter avec Spotify</string>+ <string name="welcome_privacy">Tu te connectes sur la page officielle de Spotify. Myspoti ne voit jamais ton mot de passe.</string>+ <string name="crash_heading">Myspoti s\'est arrêté</string>+ <string name="crash_explanation">Un problème est survenu. Relance l\'app ; si ça recommence, copie le rapport et partage-le dans une issue GitHub.</string>+ <string name="crash_restart_app">Relancer Myspoti</string>+ <string name="crash_copy_report">Copier le rapport</string>+ <string name="crash_report_copied">Rapport copié</string>+ <string name="remove_from_liked">Retirer des Titres likés</string>+ <string name="repeat_on">Répéter : activé</string>+ <string name="repeat_one">Répéter le titre</string>+ <string name="repeat_off">Répéter : désactivé</string>+ <string name="headphones">Écouteurs</string>+ <string name="listen_on">Écouter sur</string>+ <string name="no_devices">Aucun appareil trouvé</string>+ <string name="sleep_minutes">%1$d minutes</string>+ <string name="playing_on">Lecture en cours :\u0020</string>+ <string name="next_in_queue">Prochains titres dans la file d\'attente</string>+ <string name="next_from">Suivants de : %1$s</string>+ <string name="next_up">Suivants</string>+ <string name="clear_queue">Effacer la file</string>+ <string name="my_playlist">Ma playlist</string>+ <string name="playlist_name">Nom de la playlist</string>+ <string name="loading_playlists">Chargement des playlists…</string>+ <string name="couldnt_load">Impossible de charger %1$s</string>+ <string name="nothing_here">Rien ici pour l\'instant</string>+ <string name="album_not_found">Album introuvable</string>+ <string name="liked_song">Titre liké</string>+ <string name="verified_artist">Artiste vérifié</string>+ <string name="lyrics_share">Partager des paroles</string>+ <string name="lyrics_extra_title">Plus de sources de paroles</string>+ <string name="lyrics_extra_summary">Apple Music (mot à mot), NetEase et Genius, quand Spotify n\'a pas les paroles</string>+ <string name="lyrics_reload">Recharger les paroles</string>+ <string name="lyrics_fullscreen">Ouvrir les paroles en plein écran</string>+ <string name="browse_all">Parcourir tout</string>+ <string name="home_error">Impossible de charger l\'accueil.\nVérifie ta connexion et réessaie.</string>+ <string name="home_empty">Rien à afficher pour le moment.</string>+ <string name="spotify_account">Compte Spotify</string>+ <string name="spotify_user">Utilisateur Spotify</string>+ <string name="list_view">Afficher en liste</string>+ <string name="grid_view">Afficher en grille</string>+ <string name="library_error">Impossible de charger votre bibliothèque</string>+ <string name="library_empty">Votre bibliothèque est vide</string>+ <string name="background_playback_title">Lecture en arrière-plan</string>+ <string name="background_playback_on">L\'optimisation de la batterie est désactivée : la musique et Spotify Connect continuent écran éteint.</string>+ <string name="background_playback_off">Désactive l\'optimisation de la batterie pour qu\'Android ne mette pas l\'app en pause en arrière-plan.</string>+ <string name="crossfade_summary">Fondu en fin de titre puis en début du suivant (sans superposition). Sur ce téléphone uniquement.</string>+ <plurals name="local_files_count">+ <item quantity="one">%d titre</item>+ <item quantity="other">%d titres</item>+ </plurals>+ <string name="local_files_none_subtitle">Aucun fichier audio lisible n\'a été trouvé sur cet appareil. Ils apparaîtront ici dès qu\'il y en aura.</string>+ <string name="downloads_empty_title">Téléchargez pour écouter hors connexion</string>+ <string name="downloads_empty_subtitle">Touchez Télécharger dans le menu d\'un titre, ou le bouton de téléchargement d\'un album ou d\'une playlist.</string>+ <string name="downloads_source">Audio de YouTube Music, vérifié sur l\'enregistrement original. Gardé uniquement dans Myspoti.</string>+ <string name="downloads_size">%1$s sur ce téléphone</string>+ <string name="download_unavailable">Aucun enregistrement correspondant trouvé</string>+ <string name="download_retry">Réessayer</string>+ <string name="download_cancel">Annuler le téléchargement</string>+ <string name="not_signed_in">Vous êtes déconnecté de Spotify. Reconnectez-vous pour voir ceci.</string>+ <string name="artist_not_found">Artiste introuvable</string>+ <string name="playlist_not_found">Playlist introuvable</string>+ <string name="browse_new_releases">Nouveautés</string>+ <string name="browse_charts">Classements</string>+ <string name="browse_workout">Sport</string>+ <string name="browse_dance_electronic">Dance/Électro</string>+ <string name="language_auto">Automatique</string>+ <string name="language_auto_detail">Français si le téléphone est en français, sinon anglais</string>+ <string name="language_partial_note">Autres langues : les libellés de Spotify sont traduits, les textes de Myspoti restent en anglais.</string>+ <string name="restart_player_title">Redémarrer le lecteur</string>+ <string name="restart_player_detail">Si la musique ne répond plus : recharge le lecteur Spotify</string>+ <string name="local_playlist_subtitle">Sur cet appareil</string>+ <string name="local_playlist_new">Playlist sur cet appareil</string>+ <string name="local_added_section">Ajoutés sur cet appareil</string>+ <string name="local_add_note">Les fichiers du téléphone restent sur ce téléphone : Spotify ne peut pas les recevoir.</string>+ <string name="local_rename">Renommer</string>+ <string name="local_delete_playlist">Supprimer la playlist</string>+ <string name="local_added_to">Ajouté à %1$s</string>+ <string name="folder_create_failed">Impossible de créer le dossier</string>+ <string name="local_playlist_empty">Ajoutez des titres depuis Fichiers locaux avec leur bouton +.</string>+ <string name="playlist_change_refused">Spotify a refusé la modification de cette playlist</string>+ <string name="download_kept_by_list">Reste téléchargé : une playlist téléchargée le contient</string>+ <string name="support_title">Soutenir Myspoti</string>+ <string name="support_body">Myspoti est gratuit, sans publicité, et développé sur mon temps libre. Si vous l\'appréciez, un petit don aide à le faire avancer.</string>+ <string name="support_action">Soutenir sur Ko-fi</string>+ <string name="support_decline">Non merci</string>+ <string name="support_row_detail">Un petit don sur Ko-fi aide l\'app à avancer</string>+ <string name="supporter_perks_title">Avantages Soutien</string>+ <string name="supporter_perks_detail">Couleur d\'accent, icône de l\'app et badge, pour dire merci</string>+ <string name="supporter_perks_locked">Débloqués en soutenant Myspoti. C\'est sur l\'honneur : rien n\'est vérifié.</string>+ <string name="supporter_i_supported">J\'ai soutenu Myspoti</string>+ <string name="supporter_how">Comment avez-vous soutenu ?</string>+ <string name="supporter_once">Un don</string>+ <string name="supporter_monthly">Chaque mois</string>+ <string name="supporter_badge">Soutien</string>+ <string name="supporter_thanks_title">Merci pour votre soutien !</string>+ <string name="supporter_thanks_body">Si Myspoti vous sert toujours, un nouveau petit don aide à continuer.</string>+ <string name="support_again">Soutenir à nouveau</string>+ <string name="supporter_accent">Couleur d\'accent</string>+ <string name="supporter_icon">Icône de l\'app</string>+ <string name="supporter_icon_note">Au changement d\'icône, le raccourci de l\'écran d\'accueil peut disparaître : l\'app reste dans la liste des applications.</string>+ <string name="supporter_monthly_switch">Je soutiens chaque mois (plus de rappels)</string>+ <string name="color_green">Vert</string>+ <string name="color_blue">Bleu</string>+ <string name="color_purple">Violet</string>+ <string name="color_pink">Rose</string>+ <string name="color_orange">Orange</string>+ <string name="about_detail">Version, communauté Discord, code source</string>+ <string name="about_discord">Discord</string>+ <string name="about_discord_detail">Nouveautés, aide et idées : rejoignez la communauté</string>+ <string name="about_github">Code source</string>+ <string name="about_github_detail">Versions, signalements et code sur GitHub</string>+ <string name="about_free">Gratuit, open source et sans pub. Non affilié à Spotify.</string>+ <string name="library_reorder_hint">Maintenez une playlist, puis faites-la glisser pour la déplacer</string>+ <string name="library_reorder_reset">Revenir à l\'ordre de Spotify</string>+ <string name="song_radio_failed">Impossible d\'ouvrir la radio de ce titre</string>+ <string name="local_files_find_hint">Rechercher dans les fichiers locaux</string>+ <string name="data_saver_title">Économiseur de données</string>+ <string name="data_saver_summary">En données mobiles, Myspoti n\'utilise aucune donnée : seuls les sons téléchargés et les fichiers locaux sont lus</string>+ <string name="data_saver_blocked">Économiseur de données : en données mobiles, seuls les sons téléchargés et les fichiers locaux sont lus</string>+ <string name="new_releases_followed">Des artistes que vous suivez</string>+ <string name="new_releases_latest">Dernières sorties</string>+ <string name="your_episodes_title">Vos épisodes</string>+ <string name="your_episodes_empty">Les épisodes que vous enregistrez apparaissent ici.</string>+ <string name="recap_title">Votre récap</string>+ <string name="recap_month">30 jours</string>+ <string name="recap_year">12 mois</string>+ <string name="recap_all">Depuis le début</string>+ <string name="recap_minutes">%1$d minutes</string>+ <string name="recap_listens">%1$d écoutes</string>+ <string name="recap_sources">Spotify %1$d min • Téléchargements %2$d min • Fichiers locaux %3$d min</string>+ <string name="recap_empty">Écoutez un peu : vos titres et artistes préférés apparaîtront ici.</string>+ <string name="recap_plays">%1$d écoutes</string>+ <string name="recap_top_tracks">Titres les plus écoutés</string>+ <string name="recap_top_artists">Artistes les plus écoutés</string>+ <string name="recap_top_albums">Albums les plus écoutés</string>+ <string name="recap_private_note">Compte tout ce qui est joué dans Myspoti (Spotify, téléchargements, fichiers locaux). Reste sur ce téléphone et n\'est jamais envoyé à Spotify.</string>+ <string name="recap_detail">Vos écoutes, téléchargements et fichiers locaux compris</string>+ <string name="track_credits">Crédits</string>+ <string name="exclude_taste">Exclure de votre profil d\'écoute</string>+ <string name="include_taste">Inclure dans votre profil d\'écoute</string>+ <string name="playback_speed">Vitesse de lecture</string>+ <string name="recommended_songs">Titres recommandés</string>+ <string name="jam_title">Jam</string>+ <string name="jam_restricted">Spotify réserve le lancement d\'une Jam aux comptes Premium. Vous pouvez quand même en rejoindre une avec un lien.</string>+ <string name="jam_join">Rejoindre une Jam</string>+ <string name="jam_join_hint">Collez le lien d\'invitation</string>+ <string name="jam_leave">Quitter la Jam</string>+ <string name="jam_members">%1$d personnes écoutent</string>+ <string name="pin">Épingler</string>+ <string name="unpin">Désépingler</string>+ <string name="jam_start">Lancer une Jam</string>+ <string name="jam_invite">Partager le lien d\'invitation</string>+ <string name="jam_failed">Spotify a refusé cette Jam</string>+ <string name="jam_scan">Scanner le QR code d\'une Jam</string>+ <string name="beta_logs_title">Logs des %1$d dernières minutes</string>+ <string name="beta_logs_copy">Copier</string>+ <string name="beta_logs_copied">Logs copiés</string>+ <string name="beta_logs_share">Partager</string>+ <string name="beta_logs_close">Fermer</string>+ <string name="widget_description">Lecture en cours, avec lecture et morceau suivant</string>+ <string name="widget_previous">Précédent</string>+ <string name="widget_next">Suivant</string>+ <string name="widget_play_pause">Lecture ou pause</string>+ <string name="offline_only_downloaded">Hors ligne : seuls les %1$d morceaux téléchargés sur %2$d sont lus</string>+ <string name="track_sort_title">Titre</string>+ <string name="track_sort_artist">Artiste</string>+ <string name="track_sort_album">Album</string>+ <string name="track_sort_duration">Durée</string>+</resources>diff --git a/base/app/src/main/res/values-fr/spotify_plurals.xml b/base/app/src/main/res/values-fr/spotify_plurals.xmlnew file mode 100644index 00000000..1e8927e2--- /dev/null+++ b/base/app/src/main/res/values-fr/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d titre</item>+ <item quantity="other">%1$d titres</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d sauvegarde</item>+ <item quantity="other">%1$,d sauvegardes</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="other">%1$s playlists</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s titre</item>+ <item quantity="other">%1$s titres</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-fr/spotify_strings.xml b/base/app/src/main/res/values-fr/spotify_strings.xmlnew file mode 100644index 00000000..376ce73d--- /dev/null+++ b/base/app/src/main/res/values-fr/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Ajouter aux Titres likés</string>+ <string name="collection_liked_songs_title" formatted="false">Titres likés</string>+ <string name="context_menu_add_to_playlist" formatted="false">Ajouter à la playlist</string>+ <string name="context_menu_play_next" formatted="false">Lire ensuite</string>+ <string name="context_menu_add_to_queue" formatted="false">Ajouter à la file d\'attente</string>+ <string name="context_menu_go_to_queue" formatted="false">Accéder à la file d\'attente</string>+ <string name="context_menu_browse_album" formatted="false">Accéder à l\'album</string>+ <string name="context_menu_browse_artist" formatted="false">Accéder à l\'artiste</string>+ <string name="context_menu_share" formatted="false">Partager</string>+ <string name="context_menu_sleep_timer" formatted="false">Minuteur de veille</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Désactiver le minuteur</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Fin du titre</string>+ <string name="snackbar_added_to_queue" formatted="false">Contenu ajouté à la file d\'attente</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Ajouté aux Titres likés.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Supprimé de Titres likés.</string>+ <string name="content_description_context_menu" formatted="false">Plus d\'options</string>+ <string name="close_button_content_description" formatted="false">Fermer</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Enregistrée dans</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nouvelle playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Annuler</string>+ <string name="create_playlist_create_button" formatted="false">Créer</string>+ <string name="lyrics_card_title" formatted="false">Paroles</string>+ <string name="lyrics_card_title_preview" formatted="false">Aperçu des paroles</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Afficher les paroles</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Ouvrir les paroles en plein écran</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Partager des paroles</string>+ <string name="lyrics_credential_note" formatted="false">Paroles fournies par %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Partager</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Traduire</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Fermer les paroles</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Traduire les paroles</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Arrêter de traduire les paroles</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hum, nous ne connaissons pas les paroles de ce titre.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Ces paroles n’ont pas encore été synchronisées avec la musique.</string>+ <string name="av_switch_to_video" formatted="false">Passer à la vidéo</string>+ <string name="av_switch_to_audio" formatted="false">Passer à l\'audio</string>+ <string name="av_content_desc" formatted="false">Basculer entre l\'audio et la vidéo</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Accueil</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Rechercher</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Bibliothèque</string>+ <string name="search_header_field_hint" formatted="false">Que souhaitez-vous écouter ?</string>+ <string name="filter_chip_all_label" formatted="false">Tout</string>+ <string name="recents_content_filter_music" formatted="false">Musique</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasts</string>+ <string name="audiobooks_title" formatted="false">Livres audio</string>+ <string name="artist_popular_tracks" formatted="false">Populaires</string>+ <string name="curation_button_follow_state_text" formatted="false">S\'abonner</string>+ <string name="curation_button_following_state_text" formatted="false">Abonné</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artiste</string>+ <string name="connect_phone_is_self" formatted="false">Ce téléphone</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">De courts visuels diffusés en boucle pendant la lecture d\'un titre.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Plus tard</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Mettre à jour</string>+ <string name="context_type_description_play_queue" formatted="false">Lecture à partir de la File d\'attente de lecture</string>+ <string name="context_type_description_collection_your_library" formatted="false">Lecture à partir de Bibliothèque</string>+ <string name="context_type_description_playlist" formatted="false">Lecture à partir de Playlist</string>+ <string name="context_type_description_album" formatted="false">Lecture à partir de l\'album</string>+ <string name="context_type_description_artist" formatted="false">Lecture à partir de l\'artiste</string>+ <string name="context_type_description_show" formatted="false">Lecture à partir du podcast</string>+ <string name="context_type_description_search" formatted="false">Lecture à partir des résultats de recherche</string>+ <string name="default_notification_channel_name" formatted="false">En cours de lecture</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Appareils</string>+ <string name="action_share_label" formatted="false">Partager</string>+ <string name="action_queue_label" formatted="false">File d\'attente</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 heure</string>+ <string name="curation_actions_edit_button_title" formatted="false">Modifier</string>+ <string name="content_description_pause_button" formatted="false">Pause</string>+ <string name="content_description_play_button" formatted="false">Lire</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Lecture aléatoire</string>+ <string name="np_content_desc_repeat" formatted="false">Répéter</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Minuteur de veille</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Supprimer</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Déplacer</string>+ <string name="bottom_actions_close" formatted="false">Fermer</string>+ <string name="add_to_queue_action_content_description" formatted="false">Ajouter à la file d\'attente</string>+ <string name="curation_button_saved_text" formatted="false">Sauvegardé</string>+ <string name="np_content_desc_prev" formatted="false">Précédent</string>+ <string name="np_content_desc_next" formatted="false">Suivant</string>+ <string name="accessibility_navigate_back" formatted="false">Retour</string>+ <string name="monthly_listeners_text" formatted="false">%1$s auditeurs et auditrices par mois</string>+ <string name="profile_bio_show_less" formatted="false">Afficher moins</string>+ <string name="audiobook_series_see_more_button" formatted="false">Afficher plus</string>+ <string name="popular_releases_section_title" formatted="false">Sorties populaires</string>+ <string name="creator_biography_section_title" formatted="false">À propos</string>+ <string name="fans_also_like_section_title" formatted="false">Les fans aiment aussi</string>+ <string name="appears_on_section_title" formatted="false">Apparaît sur</string>+ <string name="composer_section_button_show_all" formatted="false">Tout afficher</string>+ <string name="releases_title" formatted="false">Sorties</string>+ <string name="artist_releases_albums" formatted="false">Albums</string>+ <string name="artist_releases_singles" formatted="false">Singles et EP</string>+ <string name="latest_release_title" formatted="false">Dernière sortie</string>+ <string name="artist_subtitle" formatted="false">Artiste</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Recherches récentes</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Effacer</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasts</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Épisodes</string>+ <string name="assisted_curation_search_song" formatted="false">Titre</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Déconnexion</string>+ <string name="library_search_text_hint" formatted="false">Rechercher dans la Bibliothèque</string>+ <string name="account_title" formatted="false">Compte</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Artistes suivi·e·s</string>+ <string name="settings_item_crossfade_title" formatted="false">Fondu enchaîné</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Fichiers locaux</string>+ <string name="local_files_empty_section_title" formatted="false">Ajoutez vos propres fichiers audio à la Bibliothèque</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Vous avez un titre ou un podcast personnel qui n\'est pas disponible sur Spotify ?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Vos fichiers audio apparaîtront ici</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Autoriser l\'accès</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Accéder aux Préférences</string>+ <string name="context_menu_download" formatted="false">Télécharger</string>+ <string name="context_menu_undownload" formatted="false">Supprimer le téléchargement</string>+ <string name="collection_downloaded" formatted="false">Téléchargés</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Téléchargé</string>+ <string name="download_badge_downloading_content_description" formatted="false">Téléchargement en cours</string>+ <string name="download_badge_error_content_description" formatted="false">Échec du téléchargement</string>+ <string name="download_notification_downloading" formatted="false">Téléchargement en cours…</string>+ <string name="toast_undownload" formatted="false">Téléchargement supprimé.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Supprimer des téléchargements ?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Ce contenu ne sera plus disponible hors connexion.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Supprimer</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Supprimer tous les téléchargements</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Supprimer tous les téléchargements ?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Compilation</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Top</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Titres</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artistes</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albums</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlists</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Effacer le filtre</string>+ <string name="ad_category_title_music" formatted="false">Musique</string>+ <string name="made_for_you_hub_title" formatted="false">Suggestions personnalisées</string>+ <string name="settings_item_app_language_title" formatted="false">Langue de l\'appli</string>+ <string name="create_menu_item_folder_title" formatted="false">Dossier</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nouveau dossier</string>+ <string name="context_menu_rename_folder" formatted="false">Renommer le dossier</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Nom du dossier</string>+ <string name="create_playlist_content_description" formatted="false">Créer une playlist</string>+ <string name="actions_picker_delete" formatted="false">Supprimer</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Trier par</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alphabétique</string>+ <string name="your_library_sort_order_creator" formatted="false">Créateur</string>+ <string name="your_library_sort_order_custom" formatted="false">Tri personnalisé</string>+ <string name="settings_item_version_title" formatted="false">Version</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Accéder à la radio liée au titre</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Rechercher dans les Titres likés</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Rechercher dans la playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Impossible de trouver « %1$s »</string>+</resources>diff --git a/base/app/src/main/res/values-fr/strings.xml b/base/app/src/main/res/values-fr/strings.xmlnew file mode 100644index 00000000..050abe03--- /dev/null+++ b/base/app/src/main/res/values-fr/strings.xml@@ -0,0 +1,45 @@+<?xml version="1.0" encoding="utf-8"?>+<resources xmlns:tools="http://schemas.android.com/tools">+ <string name="app_name">Myspoti</string>+ <string name="aa_playlists">Playlists</string>+ <string name="aa_albums">Albums</string>+ <string name="aa_artists">Artistes</string>+ <string name="aa_podcasts">Podcasts</string>+ <string name="settings_amoled_theme">Thème AMOLED</string>+ <string name="settings_amoled_theme_subtitle">Arrière-plan noir pur pour économiser la batterie</string>+ <string name="settings_lyrics_style_spotify_default">Spotify par défaut</string>+ <string name="settings_lyrics_style_fullscreen">Plein écran (Couleurs de l\'album)</string>+ <string name="settings_lyrics_style_compact">Compact</string>+ <string name="settings_lyrics_style_karaoke">Karaoké</string>+ <string name="settings_lyrics_style_bold">Grand texte en gras</string>+ <string name="main_update_available">Une nouvelle mise à jour est disponible</string>++ <string name="notif_channel_media_name">Lecture média</string>+ <string name="notif_channel_media_description">Commandes de lecture média Myspoti</string>+ <string name="notif_action_previous">Précédent</string>+ <string name="notif_action_next">Suivant</string>+ <string name="notif_action_play">Lecture</string>+ <string name="notif_action_pause">Pause</string>+ <string name="notif_shuffle_enable">Activer la lecture aléatoire</string>+ <string name="notif_shuffle_disable">Désactiver la lecture aléatoire</string>+ <string name="notif_shuffle_disable_smart">Désactiver la lecture aléatoire intelligente</string>+ <string name="notif_action_like">J\'aime</string>+ <string name="notif_action_unlike">Je n\'aime plus</string>+ <string name="notif_unknown_name">Inconnu</string>+ <string name="notif_by_artist">par %1$s</string>+ <string name="notif_repeat_disable">Désactiver la répétition</string>+ <string name="notif_repeat_disable_one">Désactiver la répétition du titre</string>+ <string name="notif_repeat_enable">Activer la répétition</string>++ <string name="bridge_player_unlocked">Lecteur déverrouillé</string>+ <string name="bridge_reloading">Rechargement…</string>++ <string name="service_disabled_message">Le service n\'est pas activé</string>+ <string name="energy_saver_title" tools:ignore="MissingTranslation">Économie d’énergie</string>+ <string name="energy_saver_summary" tools:ignore="MissingTranslation">Canvas désactivés, vidéos et animations allégées</string>+ <string name="video_fullscreen_enter" tools:ignore="MissingTranslation">Plein écran</string>+ <string name="video_fullscreen_exit" tools:ignore="MissingTranslation">Quitter le plein écran</string>+ <string name="playback_seek_description" tools:ignore="MissingTranslation">Position de lecture</string>+ <string name="account_page_title">Compte Spotify</string>+ <string name="account_page_detail">Abonnement, confidentialité et appareils, sur spotify.com</string>+</resources>diff --git a/base/app/src/main/res/values-gl/spotify_plurals.xml b/base/app/src/main/res/values-gl/spotify_plurals.xmlnew file mode 100644index 00000000..de78947c--- /dev/null+++ b/base/app/src/main/res/values-gl/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d canción</item>+ <item quantity="other">%1$d cancións</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">Gardouse %1$,d vez</item>+ <item quantity="other">Gardouse %1$,d veces</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s lista de reprodución</item>+ <item quantity="other">%1$s listas de reprodución</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s canción</item>+ <item quantity="other">%1$s cancións</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-gl/spotify_strings.xml b/base/app/src/main/res/values-gl/spotify_strings.xmlnew file mode 100644index 00000000..500a2b8f--- /dev/null+++ b/base/app/src/main/res/values-gl/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Engadir ás cancións que che gustan</string>+ <string name="collection_liked_songs_title" formatted="false">Cancións que che gustan</string>+ <string name="context_menu_add_to_playlist" formatted="false">Engadir á lista de reprodución</string>+ <string name="context_menu_play_next" formatted="false">Reproducir a continuación</string>+ <string name="context_menu_add_to_queue" formatted="false">Engadir á cola</string>+ <string name="context_menu_go_to_queue" formatted="false">Ir á cola</string>+ <string name="context_menu_browse_album" formatted="false">Ir ao álbum</string>+ <string name="context_menu_browse_artist" formatted="false">Ir ao artista</string>+ <string name="context_menu_share" formatted="false">Compartir</string>+ <string name="context_menu_sleep_timer" formatted="false">Temporizador de inactividade</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Desactivar o temporizador</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Fin da pista</string>+ <string name="snackbar_added_to_queue" formatted="false">Engadiuse á cola</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Engadiuse a Cancións que che gustan.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Quitouse de Cancións que che gustan.</string>+ <string name="content_description_context_menu" formatted="false">Máis opcións</string>+ <string name="close_button_content_description" formatted="false">Pechar</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Gardouse en</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nova lista</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Cancelar</string>+ <string name="create_playlist_create_button" formatted="false">Crear</string>+ <string name="lyrics_card_title" formatted="false">Letra</string>+ <string name="lyrics_card_title_preview" formatted="false">Vista previa da letra</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Mostrar letra</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Abrir a letra en pantalla completa</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Compartir letra</string>+ <string name="lyrics_credential_note" formatted="false">Letra proporcionada por %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Compartir</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Traducir</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Pechar a letra</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Traducir letra</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Deixar de traducir a letra</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Mmm… Nós tampouco che sabemos a letra desta.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Esta letra aínda non está sincronizada.</string>+ <string name="av_switch_to_video" formatted="false">Cambiar a vídeo</string>+ <string name="av_switch_to_audio" formatted="false">Cambiar a audio</string>+ <string name="av_content_desc" formatted="false">Alternar entre audio e vídeo</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Inicio</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Fai unha busca</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">A túa mediateca</string>+ <string name="search_header_field_hint" formatted="false">Que queres escoitar?</string>+ <string name="filter_chip_all_label" formatted="false">Todo</string>+ <string name="recents_content_filter_music" formatted="false">Música</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasts</string>+ <string name="audiobooks_title" formatted="false">Audiolibros</string>+ <string name="artist_popular_tracks" formatted="false">Popular</string>+ <string name="curation_button_follow_state_text" formatted="false">Seguir</string>+ <string name="curation_button_following_state_text" formatted="false">Seguindo</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artista</string>+ <string name="connect_phone_is_self" formatted="false">Este teléfono</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Elementos visuais breves e en bucle mentres se reproduce unha canción.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Agora non</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Actualización</string>+ <string name="context_type_description_play_queue" formatted="false">Reproducindo desde a cola de reprodución</string>+ <string name="context_type_description_collection_your_library" formatted="false">Reproducindo desde A túa mediateca</string>+ <string name="context_type_description_playlist" formatted="false">Reproducindo desde a lista</string>+ <string name="context_type_description_album" formatted="false">Reproducindo desde o álbum</string>+ <string name="context_type_description_artist" formatted="false">Reproducindo desde o artista</string>+ <string name="context_type_description_show" formatted="false">Reproducindo desde o podcast</string>+ <string name="context_type_description_search" formatted="false">Reproducindo desde Buscar</string>+ <string name="default_notification_channel_name" formatted="false">Reproducindo</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Dispositivos</string>+ <string name="action_share_label" formatted="false">Compartir</string>+ <string name="action_queue_label" formatted="false">Engadir á cola</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 hora</string>+ <string name="curation_actions_edit_button_title" formatted="false">Editar</string>+ <string name="content_description_pause_button" formatted="false">Pausar</string>+ <string name="content_description_play_button" formatted="false">Reproducir</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Modo aleatorio</string>+ <string name="np_content_desc_repeat" formatted="false">Repetir</string>+ <string name="np_content_desc_sleep_timer" formatted="false">temporizador de inactividade</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Quitar</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Mover</string>+ <string name="bottom_actions_close" formatted="false">Pechar</string>+ <string name="add_to_queue_action_content_description" formatted="false">Engadir á cola</string>+ <string name="curation_button_saved_text" formatted="false">Gardado</string>+ <string name="np_content_desc_prev" formatted="false">Anterior</string>+ <string name="np_content_desc_next" formatted="false">Seguinte</string>+ <string name="accessibility_navigate_back" formatted="false">Volver</string>+ <string name="monthly_listeners_text" formatted="false">%1$s oíntes mensuais</string>+ <string name="profile_bio_show_less" formatted="false">Mostrar menos</string>+ <string name="audiobook_series_see_more_button" formatted="false">Mostrar máis</string>+ <string name="popular_releases_section_title" formatted="false">Lanzamentos populares</string>+ <string name="creator_biography_section_title" formatted="false">Máis información</string>+ <string name="fans_also_like_section_title" formatted="false">Os seus fans tamén escoitan</string>+ <string name="appears_on_section_title" formatted="false">Aparece en</string>+ <string name="composer_section_button_show_all" formatted="false">Mostrar todo</string>+ <string name="releases_title" formatted="false">Lanzamentos</string>+ <string name="artist_releases_albums" formatted="false">Álbums</string>+ <string name="artist_releases_singles" formatted="false">Singles e EP</string>+ <string name="latest_release_title" formatted="false">Últimas novidades</string>+ <string name="artist_subtitle" formatted="false">Artista</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Buscas recentes</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Borrar</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasts</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episodios</string>+ <string name="assisted_curation_search_song" formatted="false">Canción</string>+ <string name="album" formatted="false">Álbum</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Perfil</string>+ <string name="connect_device_menu_logout" formatted="false">Pechar sesión</string>+ <string name="library_search_text_hint" formatted="false">Fai buscas na túa mediateca</string>+ <string name="account_title" formatted="false">Conta</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Artistas que segues</string>+ <string name="settings_item_crossfade_title" formatted="false">Transición gradual</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Ficheiros locais</string>+ <string name="local_files_empty_section_title" formatted="false">Engade os teus propios ficheiros de audio á túa mediateca</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Tes unha canción ou un podcast persoal que non estea en Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Os teus ficheiros de audio aparecerán aquí</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Dar acceso</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Ir a Configuración</string>+ <string name="context_menu_download" formatted="false">Descargar</string>+ <string name="context_menu_undownload" formatted="false">Quitar a descarga</string>+ <string name="collection_downloaded" formatted="false">Descargado</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Descargado</string>+ <string name="download_badge_downloading_content_description" formatted="false">Descargando</string>+ <string name="download_badge_error_content_description" formatted="false">Non se puido descargar</string>+ <string name="download_notification_downloading" formatted="false">Descargando…</string>+ <string name="toast_undownload" formatted="false">Quitouse a descarga.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Queres quitala das descargas?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Non poderás reproducir isto sen conexión.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Quitar</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Quitar todas as descargas</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Queres quitar todas as descargas?</string>+ <string name="album_type_album" formatted="false">Álbum</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Recompilación</string>+ <string name="assisted_curation_search_playlist" formatted="false">Lista</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Os principais</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Cancións</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artistas</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Álbums</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Listas</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Borrar o filtro</string>+ <string name="ad_category_title_music" formatted="false">Música</string>+ <string name="made_for_you_hub_title" formatted="false">Especialmente para ti</string>+ <string name="settings_item_app_language_title" formatted="false">Idioma da aplicación</string>+ <string name="create_menu_item_folder_title" formatted="false">Cartafol</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Novo cartafol</string>+ <string name="context_menu_rename_folder" formatted="false">Cambiar nome do cartafol</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Nome do cartafol</string>+ <string name="create_playlist_content_description" formatted="false">Crear a lista</string>+ <string name="actions_picker_delete" formatted="false">Eliminar</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Ordenar por</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Orde alfabética</string>+ <string name="your_library_sort_order_creator" formatted="false">Creador</string>+ <string name="your_library_sort_order_custom" formatted="false">Orde personalizada</string>+ <string name="settings_item_version_title" formatted="false">Versión</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Ir á radio da canción</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Busca en Cancións que che gustan</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Busca na lista</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Non se atopou \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-gu/spotify_plurals.xml b/base/app/src/main/res/values-gu/spotify_plurals.xmlnew file mode 100644index 00000000..33191378--- /dev/null+++ b/base/app/src/main/res/values-gu/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d ગીત</item>+ <item quantity="other">%1$d ગીત</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d સેવ થયા</item>+ <item quantity="other">%1$,d સેવ થયા</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s પ્લેલિસ્ટ</item>+ <item quantity="other">%1$s પ્લેલિસ્ટ</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s ગીત</item>+ <item quantity="other">%1$s ગીત</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-gu/spotify_strings.xml b/base/app/src/main/res/values-gu/spotify_strings.xmlnew file mode 100644index 00000000..d446893b--- /dev/null+++ b/base/app/src/main/res/values-gu/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">લાઇક કરેલા ગીતો પર ઉમેરો</string>+ <string name="collection_liked_songs_title" formatted="false">પસંદ કરેલા ગીતો</string>+ <string name="context_menu_add_to_playlist" formatted="false">પ્લેલિસ્ટમાં ઉમેરો</string>+ <string name="context_menu_play_next" formatted="false">આગળનું વગાડો</string>+ <string name="context_menu_add_to_queue" formatted="false">કતારમાં ઉમેરો</string>+ <string name="context_menu_go_to_queue" formatted="false">કતારમાં જાઓ</string>+ <string name="context_menu_browse_album" formatted="false">આલ્બમ પર જાઓ</string>+ <string name="context_menu_browse_artist" formatted="false">આર્ટિસ્ટ પર જાઓ</string>+ <string name="context_menu_share" formatted="false">શેર કરો</string>+ <string name="context_menu_sleep_timer" formatted="false">સ્લીપ ટાઇમર</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">ટાઇમર બંધ કરો</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">ટ્રેક પૂરો</string>+ <string name="snackbar_added_to_queue" formatted="false">કતારમાં ઉમેર્યું</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">પસંદ કરેલા ગીતોમાં ઉમેર્યું.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">પસંદ કરેલા ગીતોમાંથી દૂર કર્યું.</string>+ <string name="content_description_context_menu" formatted="false">વધુ વિકલ્પો</string>+ <string name="close_button_content_description" formatted="false">બંધ કરો</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">આમાં સેવ કર્યું</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">નવું પ્લેલિસ્ટ</string>+ <string name="add_to_playlist_button_cancel" formatted="false">રદ કરો</string>+ <string name="create_playlist_create_button" formatted="false">બનાવો</string>+ <string name="lyrics_card_title" formatted="false">ગીતના બોલ</string>+ <string name="lyrics_card_title_preview" formatted="false">ગીતના બોલનું પ્રિવ્યૂ</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">ગીતના બોલ બતાવો</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">ગીતના બોલ સંપૂર્ણ સ્ક્રીનમાં ખોલો</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">ગીતનાં બોલ શેર કરો</string>+ <string name="lyrics_credential_note" formatted="false">%1$s દ્વારા પ્રદાન કરાયેલ ગીતના બોલ</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">શેર કરો</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">અનુવાદ કરો</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">ગીતના બોલ બંધ કરો</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">ગીતના બોલનો અનુવાદ કરો</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">ગીતના બોલનો અનુવાદ કરવાનું બંધ કરો</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">હમમ. અમે આ ગીતના બોલ જાણતાં નથી.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">ગીતના આ બોલમાં હજુ ટાઇમસ્ટેમ્પ આપેલા નથી.</string>+ <string name="av_switch_to_video" formatted="false">વીડિયો પર સ્વિચ કરો</string>+ <string name="av_switch_to_audio" formatted="false">ઓડિયો પર સ્વિચ કરો</string>+ <string name="av_content_desc" formatted="false">ઓડિયો અને વીડિયો વચ્ચે ટોગલ કરો</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">હોમ</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">શોધો</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">તમારી લાઇબ્રેરી</string>+ <string name="search_header_field_hint" formatted="false">તમે શું સાંભળવા માગો છો?</string>+ <string name="filter_chip_all_label" formatted="false">બધું</string>+ <string name="recents_content_filter_music" formatted="false">સંગીત</string>+ <string name="ad_category_title_podcasts" formatted="false">પોડકાસ્ટ</string>+ <string name="audiobooks_title" formatted="false">ઓડિયોબુક</string>+ <string name="artist_popular_tracks" formatted="false">લોકપ્રિય</string>+ <string name="curation_button_follow_state_text" formatted="false">ફોલો કરો</string>+ <string name="curation_button_following_state_text" formatted="false">ફોલો કરો છો</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">આર્ટિસ્ટ</string>+ <string name="connect_phone_is_self" formatted="false">આ ફોન</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">જ્યારે ગીત વાગી રહ્યું હોય ત્યારે ટૂંકા, લૂપિંગ વિઝ્યુઅલ.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">હમણાં નહીં</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">અપડેટ કરો</string>+ <string name="context_type_description_play_queue" formatted="false">પ્લે ક્યુમાંથી વગાડવા</string>+ <string name="context_type_description_collection_your_library" formatted="false">તમારી લાઇબ્રેરીમાંથી વગાડવા</string>+ <string name="context_type_description_playlist" formatted="false">પ્લેલિસ્ટમાંથી વગાડવા</string>+ <string name="context_type_description_album" formatted="false">આલ્બમમાંથી વગાડવા</string>+ <string name="context_type_description_artist" formatted="false">આર્ટિસ્ટમાંથી વગાડવા</string>+ <string name="context_type_description_show" formatted="false">પોડકાસ્ટ પરથી વાગી રહ્યુ છે</string>+ <string name="context_type_description_search" formatted="false">શોધમાંથી વગાડવા</string>+ <string name="default_notification_channel_name" formatted="false">હાલમાં ચાલી રહી છે</string>+ <string name="label_bluetooth" formatted="false">બ્લુટૂથ</string>+ <string name="mr_user_route_category_name" formatted="false">ઉપકરણો</string>+ <string name="action_share_label" formatted="false">શેર કરો</string>+ <string name="action_queue_label" formatted="false">કતાર</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 કલાક</string>+ <string name="curation_actions_edit_button_title" formatted="false">ફેરફાર કરો</string>+ <string name="content_description_pause_button" formatted="false">થોભાવો</string>+ <string name="content_description_play_button" formatted="false">વગાડો</string>+ <string name="play_mode_item_shuffle_title" formatted="false">શફલ કરો</string>+ <string name="np_content_desc_repeat" formatted="false">રિપીટ કરો</string>+ <string name="np_content_desc_sleep_timer" formatted="false">સ્લીપ ટાઇમર</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">દૂર કરો</string>+ <string name="edit_playlist_items_move_chip" formatted="false">ખસેડો</string>+ <string name="bottom_actions_close" formatted="false">બંધ કરો</string>+ <string name="add_to_queue_action_content_description" formatted="false">કતારમાં ઉમેરો</string>+ <string name="curation_button_saved_text" formatted="false">સેવ કરી</string>+ <string name="np_content_desc_prev" formatted="false">પાછળ</string>+ <string name="np_content_desc_next" formatted="false">આગામી</string>+ <string name="accessibility_navigate_back" formatted="false">પાછળ</string>+ <string name="monthly_listeners_text" formatted="false">%1$s માસિક સાંભળનારા</string>+ <string name="profile_bio_show_less" formatted="false">ઓછું બતાવો</string>+ <string name="audiobook_series_see_more_button" formatted="false">વધુ બતાવો</string>+ <string name="popular_releases_section_title" formatted="false">લોકપ્રિય રિલીઝ</string>+ <string name="creator_biography_section_title" formatted="false">પરિચય</string>+ <string name="fans_also_like_section_title" formatted="false">ચાહકોને આ પણ ગમે છે</string>+ <string name="appears_on_section_title" formatted="false">આમાં દેખાશે</string>+ <string name="composer_section_button_show_all" formatted="false">બધું બતાવો</string>+ <string name="releases_title" formatted="false">રિલીઝ</string>+ <string name="artist_releases_albums" formatted="false">આલ્બમ</string>+ <string name="artist_releases_singles" formatted="false">સિંગલ્સ અને EPs</string>+ <string name="latest_release_title" formatted="false">નવીનતમ રિલીઝ</string>+ <string name="artist_subtitle" formatted="false">આર્ટિસ્ટ</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">તાજેતરની શોધો</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">સાફ કરો</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">પોડકાસ્ટ</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">એપિસોડ</string>+ <string name="assisted_curation_search_song" formatted="false">ગીત</string>+ <string name="album" formatted="false">આલ્બમ</string>+ <string name="album_type_podcast" formatted="false">પોડકાસ્ટ</string>+ <string name="recently_played_user_profile" formatted="false">પ્રોફાઇલ</string>+ <string name="connect_device_menu_logout" formatted="false">લૉગ આઉટ કરો</string>+ <string name="library_search_text_hint" formatted="false">તમારી લાઇબ્રેરી શોધો</string>+ <string name="account_title" formatted="false">એકાઉન્ટ</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">આર્ટિસ્ટને ફોલો કર્યું</string>+ <string name="settings_item_crossfade_title" formatted="false">ક્રોસફેડ</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d સે</string>+ <string name="local_files_title" formatted="false">સ્થાનિક ફાઇલો</string>+ <string name="local_files_empty_section_title" formatted="false">તમારી પોતાની ઓડિયો ફાઇલ તમારી લાઇબ્રેરીમાં ઉમેરો</string>+ <string name="local_files_empty_section_subtitle" formatted="false">એવું કોઈ ગીત કે પર્સનલ પોડકાસ્ટ મળ્યું છે જે Spotify પર ન હોય?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">તમારી બધી ઓડિયો ફાઇલ અહીં દેખાશે</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">એક્સેસ આપો</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">સેટિંગ પર જાઓ</string>+ <string name="context_menu_download" formatted="false">ડાઉનલોડ કરો</string>+ <string name="context_menu_undownload" formatted="false">ડાઉનલોડ દૂર કરો</string>+ <string name="collection_downloaded" formatted="false">ડાઉનલોડ કરેલા</string>+ <string name="download_badge_downloaded_content_description" formatted="false">ડાઉનલોડ કરેલ</string>+ <string name="download_badge_downloading_content_description" formatted="false">ડાઉનલોડ થઈ રહ્યું છે</string>+ <string name="download_badge_error_content_description" formatted="false">ડાઉનલોડ નિષ્ફળ થયું</string>+ <string name="download_notification_downloading" formatted="false">ડાઉનલોડ થઈ રહ્યું છે…</string>+ <string name="toast_undownload" formatted="false">ડાઉનલોડ દૂર કર્યું.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">ડાઉનલોડમાંથી દૂર કરીએ?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">તમે આ ઓફલાઇન વગાડી શકશો નહીં.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">દૂર કરો</string>+ <string name="settings_item_remove_downloads_title" formatted="false">બધા ડાઉનલોડને દૂર કરો</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">બધા ડાઉનલોડ દૂર કરીએ?</string>+ <string name="album_type_album" formatted="false">આલ્બમ</string>+ <string name="album_type_single" formatted="false">સિંગલ</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">સંકલન</string>+ <string name="assisted_curation_search_playlist" formatted="false">પ્લેલિસ્ટ</string>+ <string name="assisted_curation_search_filter_top" formatted="false">ટોપ</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">ગીતો</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">આર્ટિસ્ટ</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">આલ્બમ</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">પ્લેલિસ્ટ</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">ફિલ્ટર દૂર કરો</string>+ <string name="ad_category_title_music" formatted="false">મ્યુઝિક</string>+ <string name="made_for_you_hub_title" formatted="false">ખાસ તમારા માટે</string>+ <string name="settings_item_app_language_title" formatted="false">ઍપની ભાષા</string>+ <string name="create_menu_item_folder_title" formatted="false">ફોલ્ડર</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">નવું ફોલ્ડર</string>+ <string name="context_menu_rename_folder" formatted="false">ફોલ્ડરનું નામ બદલો</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">ફોલ્ડરનું નામ</string>+ <string name="create_playlist_content_description" formatted="false">પ્લેલિસ્ટ બનાવો</string>+ <string name="actions_picker_delete" formatted="false">ડિલીટ કરો</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">આ મુજબ ગોઠવો</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">આલ્ફાબેટિકલ</string>+ <string name="your_library_sort_order_creator" formatted="false">નિર્માતા</string>+ <string name="your_library_sort_order_custom" formatted="false">પસંદ મુજબ ક્રમ</string>+ <string name="settings_item_version_title" formatted="false">વર્ઝન</string>+ <string name="context_menu_go_to_song_radio" formatted="false">સોંગ રેડિયો પર જાઓ</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">પસંદ કરેલા ગીતોમાં શોધો</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">પ્લેલિસ્ટમાં શોધો</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\" શોધી શક્યા નહીં</string>+</resources>diff --git a/base/app/src/main/res/values-hi/spotify_plurals.xml b/base/app/src/main/res/values-hi/spotify_plurals.xmlnew file mode 100644index 00000000..15740438--- /dev/null+++ b/base/app/src/main/res/values-hi/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d गाना</item>+ <item quantity="other">%1$d गाने</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d बार सेव किया गया</item>+ <item quantity="other">%1$,d बार सेव किया गया</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s प्लेलिस्ट</item>+ <item quantity="other">%1$s प्लेलिस्ट</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s गाना</item>+ <item quantity="other">%1$s गाने</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-hi/spotify_strings.xml b/base/app/src/main/res/values-hi/spotify_strings.xmlnew file mode 100644index 00000000..86936a2d--- /dev/null+++ b/base/app/src/main/res/values-hi/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">अपने लाइक किए गए गानों में जोड़ें</string>+ <string name="collection_liked_songs_title" formatted="false">लाइक किए गए गाने</string>+ <string name="context_menu_add_to_playlist" formatted="false">प्लेलिस्ट में जोड़ें</string>+ <string name="context_menu_play_next" formatted="false">अगला चलाएँ</string>+ <string name="context_menu_add_to_queue" formatted="false">कतार में जोड़ें</string>+ <string name="context_menu_go_to_queue" formatted="false">कतार पर जाएँ</string>+ <string name="context_menu_browse_album" formatted="false">एल्बम पर जाएँ</string>+ <string name="context_menu_browse_artist" formatted="false">आर्टिस्ट पर जाएँ</string>+ <string name="context_menu_share" formatted="false">शेयर करें</string>+ <string name="context_menu_sleep_timer" formatted="false">स्लीप टाइमर</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">टाइमर बंद करें</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">ट्रैक खत्म हुआ</string>+ <string name="snackbar_added_to_queue" formatted="false">कतार में जोड़ा गया</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">लाइक किए गए गानों में जोड़ा गया.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">लाइक किए गए गानों से हटाया गया.</string>+ <string name="content_description_context_menu" formatted="false">और विकल्प</string>+ <string name="close_button_content_description" formatted="false">बंद करें</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">यहाँ सेव किया गया है</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">नई प्लेलिस्ट</string>+ <string name="add_to_playlist_button_cancel" formatted="false">कैंसिल करें</string>+ <string name="create_playlist_create_button" formatted="false">बनाएँ</string>+ <string name="lyrics_card_title" formatted="false">गाने के बोल</string>+ <string name="lyrics_card_title_preview" formatted="false">गाने के बोल का प्रीव्यू</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">गाने के बोल दिखाएँ</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">फ़ुलस्क्रीन पर गाने के बोल दिखाएँ</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">गाने के बोल शेयर करें</string>+ <string name="lyrics_credential_note" formatted="false">गाने के बोल %1$s उपलब्ध कराए गए हैं</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">शेयर करें</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">अनुवाद करें</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">गाने के बोल वाला पेज बंद करें</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">गाने के बोल का अनुवाद करें</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">गाने के बोल का अनुवाद करना बंद करें</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">हम्म. हमें इस गाने के बोल नहीं पता.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">गाने के बोल, अभी तक सिंक नहीं हुए हैं.</string>+ <string name="av_switch_to_video" formatted="false">वीडियो पर स्विच करें</string>+ <string name="av_switch_to_audio" formatted="false">ऑडियो पर स्विच करें</string>+ <string name="av_content_desc" formatted="false">ऑडियो और वीडियो के बीच टॉगल करें</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">होम</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">खोजें</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">आपकी लाइब्रेरी</string>+ <string name="search_header_field_hint" formatted="false">आप क्या सुनना चाहते हैं?</string>+ <string name="filter_chip_all_label" formatted="false">सभी</string>+ <string name="recents_content_filter_music" formatted="false">म्यूज़िक</string>+ <string name="ad_category_title_podcasts" formatted="false">पॉडकास्ट</string>+ <string name="audiobooks_title" formatted="false">ऑडियोबुक</string>+ <string name="artist_popular_tracks" formatted="false">लोकप्रिय</string>+ <string name="curation_button_follow_state_text" formatted="false">फ़ॉलो करें</string>+ <string name="curation_button_following_state_text" formatted="false">फ़ॉलो कर रहे हैं</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">कलाकार</string>+ <string name="connect_phone_is_self" formatted="false">इस फ़ोन पर</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">जब कोई गाना चल रहा हो, तब छोटे और लूपिंग विज़ुअल.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">अभी नहीं</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">अपडेट करें</string>+ <string name="context_type_description_play_queue" formatted="false">कतार में से चलाएँ से चल रहा है</string>+ <string name="context_type_description_collection_your_library" formatted="false">आपकी लाइब्रेरी से चल रहा है</string>+ <string name="context_type_description_playlist" formatted="false">प्लेलिस्ट से चल रहा है</string>+ <string name="context_type_description_album" formatted="false">एल्बम से चल रहा है</string>+ <string name="context_type_description_artist" formatted="false">कलाकार में से चलाएँ</string>+ <string name="context_type_description_show" formatted="false">पॉडकास्ट से चल रहा है</string>+ <string name="context_type_description_search" formatted="false">खोज से चल रहा है</string>+ <string name="default_notification_channel_name" formatted="false">अभी चल रहा है</string>+ <string name="label_bluetooth" formatted="false">ब्लूटूथ</string>+ <string name="mr_user_route_category_name" formatted="false">डिवाइस</string>+ <string name="action_share_label" formatted="false">शेयर करें</string>+ <string name="action_queue_label" formatted="false">कतार</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 घंटे के लिए</string>+ <string name="curation_actions_edit_button_title" formatted="false">एडिट करें</string>+ <string name="content_description_pause_button" formatted="false">रोकें</string>+ <string name="content_description_play_button" formatted="false">चलाएँ</string>+ <string name="play_mode_item_shuffle_title" formatted="false">शफ़ल करें</string>+ <string name="np_content_desc_repeat" formatted="false">फिर से चलाएँ</string>+ <string name="np_content_desc_sleep_timer" formatted="false">स्लीप टाइमर</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">हटाएँ</string>+ <string name="edit_playlist_items_move_chip" formatted="false">ऊपर या नीचे ले जाएँ</string>+ <string name="bottom_actions_close" formatted="false">बंद करें</string>+ <string name="add_to_queue_action_content_description" formatted="false">कतार में जोड़ें</string>+ <string name="curation_button_saved_text" formatted="false">सेव किया गया</string>+ <string name="np_content_desc_prev" formatted="false">पिछला</string>+ <string name="np_content_desc_next" formatted="false">आगे बढ़ें</string>+ <string name="accessibility_navigate_back" formatted="false">पीछे जाएँ</string>+ <string name="monthly_listeners_text" formatted="false">महीने भर में %1$s सुनने वाले</string>+ <string name="profile_bio_show_less" formatted="false">कम दिखाएँ</string>+ <string name="audiobook_series_see_more_button" formatted="false">और दिखाएँ</string>+ <string name="popular_releases_section_title" formatted="false">लोकप्रिय रिलीज़</string>+ <string name="creator_biography_section_title" formatted="false">परिचय</string>+ <string name="fans_also_like_section_title" formatted="false">प्रशंसकों को यह भी पसंद है</string>+ <string name="appears_on_section_title" formatted="false">इस पर दिखते हैं</string>+ <string name="composer_section_button_show_all" formatted="false">सभी दिखाएँ</string>+ <string name="releases_title" formatted="false">रिलीज़</string>+ <string name="artist_releases_albums" formatted="false">एल्बम</string>+ <string name="artist_releases_singles" formatted="false">सिंगल और EP</string>+ <string name="latest_release_title" formatted="false">सबसे नई रिलीज़</string>+ <string name="artist_subtitle" formatted="false">आर्टिस्ट</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">हाल की खोजें</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">क्लियर करें</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">पॉडकास्ट</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">एपिसोड</string>+ <string name="assisted_curation_search_song" formatted="false">गाना</string>+ <string name="album" formatted="false">एल्बम</string>+ <string name="album_type_podcast" formatted="false">पॉडकास्ट</string>+ <string name="recently_played_user_profile" formatted="false">प्रोफ़ाइल</string>+ <string name="connect_device_menu_logout" formatted="false">लॉग आउट करें</string>+ <string name="library_search_text_hint" formatted="false">\'आपकी लाइब्रेरी\' में खोजें</string>+ <string name="account_title" formatted="false">अकाउंट</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">फ़ॉलो किए गए आर्टिस्ट</string>+ <string name="settings_item_crossfade_title" formatted="false">क्रॉसफ़ेड</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d सेकंड</string>+ <string name="local_files_title" formatted="false">लोकल फ़ाइलें</string>+ <string name="local_files_empty_section_title" formatted="false">\'आपकी लाइब्रेरी\' में अपनी खुद की ऑडियो फ़ाइलें जोड़ें</string>+ <string name="local_files_empty_section_subtitle" formatted="false">क्या आपके पास ऐसा कोई गाना या निजी पॉडकास्ट है जो Spotify पर उपलब्ध नहीं है?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">आपकी ऑडियो फ़ाइलें यहाँ दिखेंगी</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">ऐक्सेस दें</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">सेटिंग में जाएँ</string>+ <string name="context_menu_download" formatted="false">डाउनलोड करें</string>+ <string name="context_menu_undownload" formatted="false">डाउनलोड हटाएँ</string>+ <string name="collection_downloaded" formatted="false">डाउनलोड किया गया</string>+ <string name="download_badge_downloaded_content_description" formatted="false">डाउनलोड किया गया</string>+ <string name="download_badge_downloading_content_description" formatted="false">डाउनलोड हो रहा है</string>+ <string name="download_badge_error_content_description" formatted="false">डाउनलोड नहीं हुआ</string>+ <string name="download_notification_downloading" formatted="false">डाउनलोड हो रहा है…</string>+ <string name="toast_undownload" formatted="false">डाउनलोड हटाया गया.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">डाउनलोड से हटाएँ?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">आप इसे ऑफ़लाइन नहीं चला सकेंगे.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">हटाएँ</string>+ <string name="settings_item_remove_downloads_title" formatted="false">सभी डाउनलोड हटाएँ</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">सभी डाउनलोड हटाएँ?</string>+ <string name="album_type_album" formatted="false">एल्बम</string>+ <string name="album_type_single" formatted="false">सिंगल</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">कंपाइलेशन</string>+ <string name="assisted_curation_search_playlist" formatted="false">प्लेलिस्ट</string>+ <string name="assisted_curation_search_filter_top" formatted="false">टॉप</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">गाने</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">आर्टिस्ट</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">एल्बम</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">प्लेलिस्ट</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">फ़िल्टर क्लियर करें</string>+ <string name="ad_category_title_music" formatted="false">म्यूज़िक</string>+ <string name="made_for_you_hub_title" formatted="false">खास आपके लिए</string>+ <string name="settings_item_app_language_title" formatted="false">ऐप की भाषा</string>+ <string name="create_menu_item_folder_title" formatted="false">फ़ोल्डर</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">नया फ़ोल्डर</string>+ <string name="context_menu_rename_folder" formatted="false">फ़ोल्डर का नाम बदलें</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">फ़ोल्डर का नाम</string>+ <string name="create_playlist_content_description" formatted="false">प्लेलिस्ट बनाएँ</string>+ <string name="actions_picker_delete" formatted="false">मिटाएँ</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">इसके अनुसार क्रम से लगाएँ</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">वर्णक्रम के अनुसार</string>+ <string name="your_library_sort_order_creator" formatted="false">क्रिएटर</string>+ <string name="your_library_sort_order_custom" formatted="false">मनमुताबिक क्रम</string>+ <string name="settings_item_version_title" formatted="false">वर्शन</string>+ <string name="context_menu_go_to_song_radio" formatted="false">\'गाने का रेडियो\' पर जाएँ</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">लाइक किए गए गानों में ढूँढें</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">प्लेलिस्ट में ढूँढें</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\" नहीं मिला</string>+</resources>diff --git a/base/app/src/main/res/values-hr/spotify_plurals.xml b/base/app/src/main/res/values-hr/spotify_plurals.xmlnew file mode 100644index 00000000..c7b3f0c7--- /dev/null+++ b/base/app/src/main/res/values-hr/spotify_plurals.xml@@ -0,0 +1,24 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d pjesma</item>+ <item quantity="few">%1$d pjesme</item>+ <item quantity="other">%1$d pjesme</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">Spremljeno %1$,d put</item>+ <item quantity="few">Spremljeno %1$,d puta</item>+ <item quantity="other">Spremljeno %1$,d put(a)</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s popis za reprodukciju</item>+ <item quantity="few">%1$s popisa za reprodukciju</item>+ <item quantity="other">%1$s popisa za reprodukciju</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s pjesma</item>+ <item quantity="few">%1$s pjesme</item>+ <item quantity="other">%1$s pjesme</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-hr/spotify_strings.xml b/base/app/src/main/res/values-hr/spotify_strings.xmlnew file mode 100644index 00000000..dcba2659--- /dev/null+++ b/base/app/src/main/res/values-hr/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Dodajte u Pjesme koje vam se sviđaju</string>+ <string name="collection_liked_songs_title" formatted="false">Pjesme koje vam se sviđaju</string>+ <string name="context_menu_add_to_playlist" formatted="false">Dodaj na popis za reprodukciju</string>+ <string name="context_menu_play_next" formatted="false">Reproduciraj sljedeće</string>+ <string name="context_menu_add_to_queue" formatted="false">Dodaj u red čekanja</string>+ <string name="context_menu_go_to_queue" formatted="false">Otvori red čekanja</string>+ <string name="context_menu_browse_album" formatted="false">Prijeđi na album</string>+ <string name="context_menu_browse_artist" formatted="false">Prijeđi na izvođača</string>+ <string name="context_menu_share" formatted="false">Podijeli</string>+ <string name="context_menu_sleep_timer" formatted="false">Tajmer spavanja</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Isključi tajmer</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Kraj pjesme</string>+ <string name="snackbar_added_to_queue" formatted="false">Dodano u red čekanja</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Dodana Pjesmama koje vam se sviđaju.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Uklonjena iz Pjesama koje vam se sviđaju.</string>+ <string name="content_description_context_menu" formatted="false">Više mogućnosti</string>+ <string name="close_button_content_description" formatted="false">Zatvori</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Spremljeno u</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Novi popis za reprodukciju</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Odustani</string>+ <string name="create_playlist_create_button" formatted="false">Izradi</string>+ <string name="lyrics_card_title" formatted="false">Tekst</string>+ <string name="lyrics_card_title_preview" formatted="false">Pregled teksta</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Prikaži tekst</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Otvorite tekst preko punog zaslona</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Podijelite tekst</string>+ <string name="lyrics_credential_note" formatted="false">Tekst pjesme omogućio %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Podijeli</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Prevedi</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Zatvori tekst</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Prevedi tekst</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Prestanite prevoditi tekstove</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Ne znamo tekst te pjesme.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Ovaj tekst još nije vremenski sinkroniziran.</string>+ <string name="av_switch_to_video" formatted="false">Prebaci na videozapis</string>+ <string name="av_switch_to_audio" formatted="false">Prebaci na audiozapis</string>+ <string name="av_content_desc" formatted="false">Prebacivanje između zvučnih i videozapisa</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Početna</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Tražilica</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Vaša zbirka</string>+ <string name="search_header_field_hint" formatted="false">Što želite slušati?</string>+ <string name="filter_chip_all_label" formatted="false">Sav sadržaj</string>+ <string name="recents_content_filter_music" formatted="false">Glazba</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasti</string>+ <string name="audiobooks_title" formatted="false">Audioknjige</string>+ <string name="artist_popular_tracks" formatted="false">Popularna</string>+ <string name="curation_button_follow_state_text" formatted="false">Prati</string>+ <string name="curation_button_following_state_text" formatted="false">Pratite</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Izvođač</string>+ <string name="connect_phone_is_self" formatted="false">Ovaj telefon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Kratki, ponavljajući vizuali tijekom reprodukcije pjesme.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Ne sada</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Ažuriraj</string>+ <string name="context_type_description_play_queue" formatted="false">Reprodukcija iz reda čekanja</string>+ <string name="context_type_description_collection_your_library" formatted="false">Reprodukcija iz Moje zbirke</string>+ <string name="context_type_description_playlist" formatted="false">Reprodukcija s popisa za reprodukciju</string>+ <string name="context_type_description_album" formatted="false">Reprodukcija s albuma</string>+ <string name="context_type_description_artist" formatted="false">Reprodukcija glazbe izvođača</string>+ <string name="context_type_description_show" formatted="false">Reprodukcija s podcasta</string>+ <string name="context_type_description_search" formatted="false">Reprodukcija iz tražilice</string>+ <string name="default_notification_channel_name" formatted="false">Upravo svira</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Uređaji</string>+ <string name="action_share_label" formatted="false">Podijeli</string>+ <string name="action_queue_label" formatted="false">Red čekanja</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 sat</string>+ <string name="curation_actions_edit_button_title" formatted="false">Uredi</string>+ <string name="content_description_pause_button" formatted="false">Pauziraj</string>+ <string name="content_description_play_button" formatted="false">Reproduciraj</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Nasumično</string>+ <string name="np_content_desc_repeat" formatted="false">Ponovi</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Tajmer spavanja</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Ukloni</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Pomakni</string>+ <string name="bottom_actions_close" formatted="false">Zatvori</string>+ <string name="add_to_queue_action_content_description" formatted="false">Dodaj u red čekanja</string>+ <string name="curation_button_saved_text" formatted="false">Spremljeno</string>+ <string name="np_content_desc_prev" formatted="false">Prethodno</string>+ <string name="np_content_desc_next" formatted="false">Dalje</string>+ <string name="accessibility_navigate_back" formatted="false">Natrag</string>+ <string name="monthly_listeners_text" formatted="false">Broj slušatelja mjesečno: %1$s</string>+ <string name="profile_bio_show_less" formatted="false">Prikaži manje</string>+ <string name="audiobook_series_see_more_button" formatted="false">Prikaži više</string>+ <string name="popular_releases_section_title" formatted="false">Popularna izdanja</string>+ <string name="creator_biography_section_title" formatted="false">Detaljnije</string>+ <string name="fans_also_like_section_title" formatted="false">Obožavatelji također vole</string>+ <string name="appears_on_section_title" formatted="false">Pojavljuje se na albumima</string>+ <string name="composer_section_button_show_all" formatted="false">Prikaži sve</string>+ <string name="releases_title" formatted="false">Izdanja</string>+ <string name="artist_releases_albums" formatted="false">Albumi</string>+ <string name="artist_releases_singles" formatted="false">Singlovi i EP-ovi</string>+ <string name="latest_release_title" formatted="false">Najnovije izdanje</string>+ <string name="artist_subtitle" formatted="false">Izvođač</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Nedavna pretraživanja</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Izbriši</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasti</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Epizode</string>+ <string name="assisted_curation_search_song" formatted="false">Pjesma</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Odjava</string>+ <string name="library_search_text_hint" formatted="false">Pretražite svoju zbirku</string>+ <string name="account_title" formatted="false">Račun</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Izvođači koje pratite</string>+ <string name="settings_item_crossfade_title" formatted="false">Križno utišavanje</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Lokalne datoteke</string>+ <string name="local_files_empty_section_title" formatted="false">Dodajte vlastite audiodatoteke na popis Moja zbirka</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Imate pjesmu ili osobni podcast koji nisu na Spotifyu?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Vaše će se audiodatoteke prikazati ovdje</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Dopusti pristup</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Prijeđi na Postavke</string>+ <string name="context_menu_download" formatted="false">Preuzimanje</string>+ <string name="context_menu_undownload" formatted="false">Ukloni preuzimanje</string>+ <string name="collection_downloaded" formatted="false">Preuzeto</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Preuzeto</string>+ <string name="download_badge_downloading_content_description" formatted="false">Preuzimanje</string>+ <string name="download_badge_error_content_description" formatted="false">Preuzimanje neuspješno</string>+ <string name="download_notification_downloading" formatted="false">Preuzimanje…</string>+ <string name="toast_undownload" formatted="false">Preuzimanje uklonjeno.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Ukloniti iz preuzimanja?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Nećete ih moći reproducirati u izvanmrežnom načinu.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Ukloni</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Ukloni sva preuzimanja</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Ukloniti sva preuzimanja?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Singl</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Kompilacija</string>+ <string name="assisted_curation_search_playlist" formatted="false">Popis za reprodukciju</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Najbolje</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Pjesme</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Izvođači</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albumi</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Popisi za reprodukciju</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Brisanje filtra</string>+ <string name="ad_category_title_music" formatted="false">Glazba</string>+ <string name="made_for_you_hub_title" formatted="false">Za vas</string>+ <string name="settings_item_app_language_title" formatted="false">Jezik aplikacije</string>+ <string name="create_menu_item_folder_title" formatted="false">Mapa</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nova mapa</string>+ <string name="context_menu_rename_folder" formatted="false">Preimenovanje mape</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Naziv mape</string>+ <string name="create_playlist_content_description" formatted="false">Izradi popis za reprodukciju</string>+ <string name="actions_picker_delete" formatted="false">Izbriši</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sortiraj po</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Abecedno</string>+ <string name="your_library_sort_order_creator" formatted="false">Autor</string>+ <string name="your_library_sort_order_custom" formatted="false">Prilagođeni redoslijed</string>+ <string name="settings_item_version_title" formatted="false">Verzija</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Prijeđi na radio na temelju pjesme</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Pronađi u pjesmama koje mi se sviđaju</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Pronađi na popisu za reprodukciju</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Nije moguće pronaći „%1$s”</string>+</resources>diff --git a/base/app/src/main/res/values-hu/spotify_plurals.xml b/base/app/src/main/res/values-hu/spotify_plurals.xmlnew file mode 100644index 00000000..f64a3bbf--- /dev/null+++ b/base/app/src/main/res/values-hu/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d dal</item>+ <item quantity="other">%1$d dal</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d mentés</item>+ <item quantity="other">%1$,d mentés</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s műsorlista</item>+ <item quantity="other">%1$s műsorlista</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s dal</item>+ <item quantity="other">%1$s dal</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-hu/spotify_strings.xml b/base/app/src/main/res/values-hu/spotify_strings.xmlnew file mode 100644index 00000000..99dc3bf7--- /dev/null+++ b/base/app/src/main/res/values-hu/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Hozzáadás a Kedvelt dalokhoz</string>+ <string name="collection_liked_songs_title" formatted="false">Kedvelt dalok</string>+ <string name="context_menu_add_to_playlist" formatted="false">Felvétel műsorlistára</string>+ <string name="context_menu_play_next" formatted="false">Lejátszás következőként</string>+ <string name="context_menu_add_to_queue" formatted="false">Műsorra tűzés</string>+ <string name="context_menu_go_to_queue" formatted="false">Műsor megnyitása</string>+ <string name="context_menu_browse_album" formatted="false">Ugrás az albumhoz</string>+ <string name="context_menu_browse_artist" formatted="false">Ugrás az előadóhoz</string>+ <string name="context_menu_share" formatted="false">Megosztás</string>+ <string name="context_menu_sleep_timer" formatted="false">Elalvásidőzítő</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Időzítő kikapcsolása</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">A szám végén</string>+ <string name="snackbar_added_to_queue" formatted="false">Műsorra tűzve</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Hozzáadva a Kedvelt dalokhoz.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Eltávolítva a Kedvelt dalok közül.</string>+ <string name="content_description_context_menu" formatted="false">További lehetőségek</string>+ <string name="close_button_content_description" formatted="false">Bezárás</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Elmentve itt:</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Új műsorlista</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Mégse</string>+ <string name="create_playlist_create_button" formatted="false">Létrehozás</string>+ <string name="lyrics_card_title" formatted="false">Dalszöveg</string>+ <string name="lyrics_card_title_preview" formatted="false">Dalszöveg előnézete</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Dalszöveg megjelenítése</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Dalszöveg megjelenítése teljes képernyőn</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Dalszöveg megosztása</string>+ <string name="lyrics_credential_note" formatted="false">Dalszöveg tőle: %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Megosztás</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Fordítás</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Dalszöveg bezárása</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Dalszöveg fordítása</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Dalszöveg fordításának leállítása</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Ennek a dalnak nem tudjuk a szövegét.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Ezek a dalszövegek még nem érhetők el a számmal szinkronban megjelenő verzióban.</string>+ <string name="av_switch_to_video" formatted="false">Váltás videóra</string>+ <string name="av_switch_to_audio" formatted="false">Váltás audióra</string>+ <string name="av_content_desc" formatted="false">Váltás a hang és a videó között</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Kezdőlap</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Keresés</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Gyűjteményem</string>+ <string name="search_header_field_hint" formatted="false">Mit szeretnél hallgatni?</string>+ <string name="filter_chip_all_label" formatted="false">Mind</string>+ <string name="recents_content_filter_music" formatted="false">Zene</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcastok</string>+ <string name="audiobooks_title" formatted="false">Hangoskönyvek</string>+ <string name="artist_popular_tracks" formatted="false">Népszerű</string>+ <string name="curation_button_follow_state_text" formatted="false">Követés</string>+ <string name="curation_button_following_state_text" formatted="false">Követem</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Előadó</string>+ <string name="connect_phone_is_self" formatted="false">Ez a telefon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Rövid, ismétlődő vizuálok megjelenítése dalok lejátszása közben.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Most nem</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Frissítés</string>+ <string name="context_type_description_play_queue" formatted="false">Lejátszás a műsorból</string>+ <string name="context_type_description_collection_your_library" formatted="false">Lejátszás a gyűjteményedből</string>+ <string name="context_type_description_playlist" formatted="false">Lejátszás műsorlistáról</string>+ <string name="context_type_description_album" formatted="false">Lejátszás albumból</string>+ <string name="context_type_description_artist" formatted="false">Lejátszás előadótól</string>+ <string name="context_type_description_show" formatted="false">Lejátszás podcastról</string>+ <string name="context_type_description_search" formatted="false">Lejátszás keresésből</string>+ <string name="default_notification_channel_name" formatted="false">Most játszott tartalom</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Eszközök</string>+ <string name="action_share_label" formatted="false">Megosztás</string>+ <string name="action_queue_label" formatted="false">Műsor</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 óra</string>+ <string name="curation_actions_edit_button_title" formatted="false">Szerkesztés</string>+ <string name="content_description_pause_button" formatted="false">Lejátszás szüneteltetése</string>+ <string name="content_description_play_button" formatted="false">Lejátszás</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Véletlen sorrend</string>+ <string name="np_content_desc_repeat" formatted="false">Ismétlés</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Elalvásidőzítő</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Eltávolítás</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Áthelyezés</string>+ <string name="bottom_actions_close" formatted="false">Bezárás</string>+ <string name="add_to_queue_action_content_description" formatted="false">Műsorra tűzés</string>+ <string name="curation_button_saved_text" formatted="false">Mentve</string>+ <string name="np_content_desc_prev" formatted="false">Előző</string>+ <string name="np_content_desc_next" formatted="false">Következő</string>+ <string name="accessibility_navigate_back" formatted="false">Vissza</string>+ <string name="monthly_listeners_text" formatted="false">%1$s hallgató havonta</string>+ <string name="profile_bio_show_less" formatted="false">Kevesebb mutatása</string>+ <string name="audiobook_series_see_more_button" formatted="false">Több mutatása</string>+ <string name="popular_releases_section_title" formatted="false">Népszerű zenék</string>+ <string name="creator_biography_section_title" formatted="false">Névjegy</string>+ <string name="fans_also_like_section_title" formatted="false">A rajongók ezt is szeretik</string>+ <string name="appears_on_section_title" formatted="false">Itt is megtalálod</string>+ <string name="composer_section_button_show_all" formatted="false">Összes megjelenítése</string>+ <string name="releases_title" formatted="false">Megjelenések</string>+ <string name="artist_releases_albums" formatted="false">Albumok</string>+ <string name="artist_releases_singles" formatted="false">Kislemezek és EP-k</string>+ <string name="latest_release_title" formatted="false">Újdonság</string>+ <string name="artist_subtitle" formatted="false">Előadó</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Legutóbbi keresések</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Törlés</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcastok</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Epizódok</string>+ <string name="assisted_curation_search_song" formatted="false">Dal</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Kijelentkezés</string>+ <string name="library_search_text_hint" formatted="false">Keresés a Gyűjteményemben</string>+ <string name="account_title" formatted="false">Fiók</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Követett előadók</string>+ <string name="settings_item_crossfade_title" formatted="false">Áttűnés</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d mp</string>+ <string name="local_files_title" formatted="false">Helyi fájlok</string>+ <string name="local_files_empty_section_title" formatted="false">Add hozzá a saját hangfájljaidat a Gyűjteményedhez</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Van egy olyan dalod vagy személyes podcastod, amely még nem található meg a Spotifyon?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">A hangfájljaid itt fognak megjelenni</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Engedélyezés</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Beállítások megnyitása</string>+ <string name="context_menu_download" formatted="false">Letöltés</string>+ <string name="context_menu_undownload" formatted="false">Letöltés eltávolítása</string>+ <string name="collection_downloaded" formatted="false">Letöltve</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Letöltve</string>+ <string name="download_badge_downloading_content_description" formatted="false">Letöltés alatt</string>+ <string name="download_badge_error_content_description" formatted="false">Sikertelen letöltés</string>+ <string name="download_notification_downloading" formatted="false">Letöltés folyamatban…</string>+ <string name="toast_undownload" formatted="false">Letöltés eltávolítva.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Eltávolítod a letöltések közül?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Nem fogod tudni offline módban lejátszani.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Eltávolítás</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Az összes letöltött tartalom eltávolítása</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Eltávolítod az összes letöltött tartalmat?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Kislemez</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Válogatás</string>+ <string name="assisted_curation_search_playlist" formatted="false">Műsorlista</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Legjobb találat</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Dalok</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Előadók</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albumok</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Műsorlisták</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Szűrő eltávolítása</string>+ <string name="ad_category_title_music" formatted="false">Zene</string>+ <string name="made_for_you_hub_title" formatted="false">Neked készítettük</string>+ <string name="settings_item_app_language_title" formatted="false">Alkalmazás nyelve</string>+ <string name="create_menu_item_folder_title" formatted="false">Mappa</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Új mappa</string>+ <string name="context_menu_rename_folder" formatted="false">Mappa átnevezése</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Mappa neve</string>+ <string name="create_playlist_content_description" formatted="false">Műsorlista létrehozása</string>+ <string name="actions_picker_delete" formatted="false">Törlés</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Rendezési szempont</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Betűrendes</string>+ <string name="your_library_sort_order_creator" formatted="false">Készítő</string>+ <string name="your_library_sort_order_custom" formatted="false">Egyéni sorrend</string>+ <string name="settings_item_version_title" formatted="false">Verzió</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Ugrás a szám rádiójára</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Keresés a kedvelt dalok között</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Keresés a műsorlistában</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Nem találtuk a következőt: „%1$s”</string>+</resources>diff --git a/base/app/src/main/res/values-in/spotify_plurals.xml b/base/app/src/main/res/values-in/spotify_plurals.xmlnew file mode 100644index 00000000..e845eedd--- /dev/null+++ b/base/app/src/main/res/values-in/spotify_plurals.xml@@ -0,0 +1,16 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="other">%1$d lagu</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="other">%1$,d kali disimpan</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="other">%1$s playlist</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="other">%1$s lagu</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-in/spotify_strings.xml b/base/app/src/main/res/values-in/spotify_strings.xmlnew file mode 100644index 00000000..20bc561f--- /dev/null+++ b/base/app/src/main/res/values-in/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Tambahkan ke Lagu yang Disukai</string>+ <string name="collection_liked_songs_title" formatted="false">Lagu yang Disukai</string>+ <string name="context_menu_add_to_playlist" formatted="false">Tambahkan ke playlist</string>+ <string name="context_menu_play_next" formatted="false">Putar berikutnya</string>+ <string name="context_menu_add_to_queue" formatted="false">Tambahkan ke Antrean</string>+ <string name="context_menu_go_to_queue" formatted="false">Buka Antrean</string>+ <string name="context_menu_browse_album" formatted="false">Buka album</string>+ <string name="context_menu_browse_artist" formatted="false">Buka artis</string>+ <string name="context_menu_share" formatted="false">Bagikan</string>+ <string name="context_menu_sleep_timer" formatted="false">Pengatur waktu tidur</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Matikan timer</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Akhir lagu</string>+ <string name="snackbar_added_to_queue" formatted="false">Ditambahkan ke Antrean</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Ditambahkan ke Lagu yang Disukai</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Dihapus dari Lagu yang Disukai.</string>+ <string name="content_description_context_menu" formatted="false">Opsi lainnya</string>+ <string name="close_button_content_description" formatted="false">Tutup</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Tersimpan di</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Playlist baru</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Batalkan</string>+ <string name="create_playlist_create_button" formatted="false">Buat</string>+ <string name="lyrics_card_title" formatted="false">Lirik</string>+ <string name="lyrics_card_title_preview" formatted="false">Pratinjau lirik</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Tampilkan lirik</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Buka lirik di layar penuh</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Bagikan lirik</string>+ <string name="lyrics_credential_note" formatted="false">Lirik disediakan oleh %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Bagikan</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Terjemahkan</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Tutup lirik</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Terjemahkan lirik</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Berhenti menerjemahkan lirik</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Kami juga tidak tahu lirik lagu ini.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Lirik ini belum disinkronkan dengan waktu.</string>+ <string name="av_switch_to_video" formatted="false">Beralih ke video</string>+ <string name="av_switch_to_audio" formatted="false">Beralih ke audio</string>+ <string name="av_content_desc" formatted="false">Mengganti ke audio atau video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Home</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Cari</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Koleksi Kamu</string>+ <string name="search_header_field_hint" formatted="false">Apa yang ingin kamu dengarkan?</string>+ <string name="filter_chip_all_label" formatted="false">Semua</string>+ <string name="recents_content_filter_music" formatted="false">Musik</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcast</string>+ <string name="audiobooks_title" formatted="false">Buku Audio</string>+ <string name="artist_popular_tracks" formatted="false">Populer</string>+ <string name="curation_button_follow_state_text" formatted="false">Ikuti</string>+ <string name="curation_button_following_state_text" formatted="false">Mengikuti</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artis</string>+ <string name="connect_phone_is_self" formatted="false">Ponsel ini</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Visual pendek dan berulang saat lagu diputar.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Nanti</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Perbarui</string>+ <string name="context_type_description_play_queue" formatted="false">Memutar dari Antrean Putar</string>+ <string name="context_type_description_collection_your_library" formatted="false">Memutar dari Koleksi kamu</string>+ <string name="context_type_description_playlist" formatted="false">Memainkan dari Playlist</string>+ <string name="context_type_description_album" formatted="false">Memainkan dari Album</string>+ <string name="context_type_description_artist" formatted="false">Memainkan dari Artis</string>+ <string name="context_type_description_show" formatted="false">Putar dari Podcast</string>+ <string name="context_type_description_search" formatted="false">Memainkan dari Pencarian</string>+ <string name="default_notification_channel_name" formatted="false">Sedang diputar</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Perangkat</string>+ <string name="action_share_label" formatted="false">Bagikan</string>+ <string name="action_queue_label" formatted="false">Antrean</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 jam</string>+ <string name="curation_actions_edit_button_title" formatted="false">Edit</string>+ <string name="content_description_pause_button" formatted="false">Jeda</string>+ <string name="content_description_play_button" formatted="false">Putar</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Shuffle</string>+ <string name="np_content_desc_repeat" formatted="false">Ulang</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Pengatur waktu tidur</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Hapus</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Pindahkan</string>+ <string name="bottom_actions_close" formatted="false">Tutup</string>+ <string name="add_to_queue_action_content_description" formatted="false">Tambahkan ke antrean</string>+ <string name="curation_button_saved_text" formatted="false">Tersimpan</string>+ <string name="np_content_desc_prev" formatted="false">Sebelumnya</string>+ <string name="np_content_desc_next" formatted="false">Berikutnya</string>+ <string name="accessibility_navigate_back" formatted="false">Kembali</string>+ <string name="monthly_listeners_text" formatted="false">%1$s pendengar bulanan</string>+ <string name="profile_bio_show_less" formatted="false">Lihat lebih sedikit</string>+ <string name="audiobook_series_see_more_button" formatted="false">Lihat lebih banyak</string>+ <string name="popular_releases_section_title" formatted="false">Rilis populer</string>+ <string name="creator_biography_section_title" formatted="false">Tentang</string>+ <string name="fans_also_like_section_title" formatted="false">Fans juga suka</string>+ <string name="appears_on_section_title" formatted="false">Ditampilkan di</string>+ <string name="composer_section_button_show_all" formatted="false">Tampilkan semua</string>+ <string name="releases_title" formatted="false">Rilis</string>+ <string name="artist_releases_albums" formatted="false">Album</string>+ <string name="artist_releases_singles" formatted="false">Single dan Album Mini</string>+ <string name="latest_release_title" formatted="false">Rilis terbaru</string>+ <string name="artist_subtitle" formatted="false">Artis</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Pencarian terkini</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Hapus</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcast</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episode</string>+ <string name="assisted_curation_search_song" formatted="false">Lagu</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Keluar</string>+ <string name="library_search_text_hint" formatted="false">Cari Koleksi Kamu</string>+ <string name="account_title" formatted="false">Akun</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Artis yang diikuti</string>+ <string name="settings_item_crossfade_title" formatted="false">Crossfade</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d dtk</string>+ <string name="local_files_title" formatted="false">File Lokal</string>+ <string name="local_files_empty_section_title" formatted="false">Tambahkan file audiomu sendiri ke Koleksi Kamu</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Punya lagu atau podcast pribadi yang tidak ada di Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">File audiomu akan muncul di sini</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Beri akses</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Buka Pengaturan</string>+ <string name="context_menu_download" formatted="false">Download</string>+ <string name="context_menu_undownload" formatted="false">Hapus download</string>+ <string name="collection_downloaded" formatted="false">Sudah di-download</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Sudah download</string>+ <string name="download_badge_downloading_content_description" formatted="false">Sedang download</string>+ <string name="download_badge_error_content_description" formatted="false">Download gagal</string>+ <string name="download_notification_downloading" formatted="false">Sedang download…</string>+ <string name="toast_undownload" formatted="false">Download dihapus.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Hapus dari download?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Kamu tidak bisa memutar ini dalam mode offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Hapus</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Hapus semua download</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Hapus semua download?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Kompilasi</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Teratas</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Lagu</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artis</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Album</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Hapus filter</string>+ <string name="ad_category_title_music" formatted="false">Musik</string>+ <string name="made_for_you_hub_title" formatted="false">Dibuat untuk Kamu</string>+ <string name="settings_item_app_language_title" formatted="false">Bahasa app</string>+ <string name="create_menu_item_folder_title" formatted="false">Folder</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Folder baru</string>+ <string name="context_menu_rename_folder" formatted="false">Ganti nama folder</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Nama folder</string>+ <string name="create_playlist_content_description" formatted="false">Buat playlist</string>+ <string name="actions_picker_delete" formatted="false">Hapus</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Urutkan menurut</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Abjad</string>+ <string name="your_library_sort_order_creator" formatted="false">Kreator</string>+ <string name="your_library_sort_order_custom" formatted="false">Urutan khusus</string>+ <string name="settings_item_version_title" formatted="false">Versi</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Buka radio lagu</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Cari di lagu yang disukai</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Temukan di playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Tidak bisa menemukan \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-in/strings.xml b/base/app/src/main/res/values-in/strings.xmlnew file mode 100644index 00000000..f57c022d--- /dev/null+++ b/base/app/src/main/res/values-in/strings.xml@@ -0,0 +1,35 @@+<?xml version="1.0" encoding="utf-8"?>+<resources>+ <string name="app_name">Myspoti</string>+ <string name="aa_playlists">Playlist</string>+ <string name="aa_albums">Album</string>+ <string name="aa_artists">Artis</string>+ <string name="aa_podcasts">Podcast</string>+ <string name="settings_amoled_theme">Tema AMOLED</string>+ <string name="settings_amoled_theme_subtitle">Latar belakang hitam pekat untuk menghemat baterai</string>+ <string name="settings_lyrics_style_spotify_default">Default Spotify</string>+ <string name="settings_lyrics_style_fullscreen">Layar penuh (warna album)</string>+ <string name="settings_lyrics_style_compact">Ringkas</string>+ <string name="settings_lyrics_style_karaoke">Karaoke</string>+ <string name="settings_lyrics_style_bold">Besar dan tebal</string>+ <string name="main_update_available">Pembaruan baru tersedia</string>+ <string name="notif_channel_media_name">Pemutaran media</string>+ <string name="notif_channel_media_description">Kontrol pemutaran media Myspoti</string>+ <string name="notif_action_previous">Sebelumnya</string>+ <string name="notif_action_next">Berikutnya</string>+ <string name="notif_action_play">Putar</string>+ <string name="notif_action_pause">Jeda</string>+ <string name="notif_shuffle_enable">Aktifkan pemutaran acak</string>+ <string name="notif_shuffle_disable">Nonaktifkan pemutaran acak</string>+ <string name="notif_shuffle_disable_smart">Nonaktifkan pemutaran acak pintar</string>+ <string name="notif_action_like">Suka</string>+ <string name="notif_action_unlike">Batal suka</string>+ <string name="notif_unknown_name">Tidak dikenal</string>+ <string name="notif_by_artist">oleh %1$s</string>+ <string name="notif_repeat_disable">Nonaktifkan pengulangan</string>+ <string name="notif_repeat_disable_one">Nonaktifkan ulangi satu lagu</string>+ <string name="notif_repeat_enable">Aktifkan pengulangan</string>+ <string name="bridge_player_unlocked">Pemutar tidak terkunci</string>+ <string name="bridge_reloading">Memuat ulang...</string>+ <string name="service_disabled_message">Layanan tidak aktif</string>+</resources>diff --git a/base/app/src/main/res/values-is/spotify_plurals.xml b/base/app/src/main/res/values-is/spotify_plurals.xmlnew file mode 100644index 00000000..45c31b0d--- /dev/null+++ b/base/app/src/main/res/values-is/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d lag</item>+ <item quantity="other">%1$d lög</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">Vistað %1$,d sinni</item>+ <item quantity="other">Vistað %1$,d sinnum</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s spilunarlisti</item>+ <item quantity="other">%1$s spilunarlistar</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s lag</item>+ <item quantity="other">%1$s lög</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-is/spotify_strings.xml b/base/app/src/main/res/values-is/spotify_strings.xmlnew file mode 100644index 00000000..1eae79f5--- /dev/null+++ b/base/app/src/main/res/values-is/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Bæta við Lækuð lög</string>+ <string name="collection_liked_songs_title" formatted="false">Lækuð lög</string>+ <string name="context_menu_add_to_playlist" formatted="false">Bæta við spilunarlista</string>+ <string name="context_menu_play_next" formatted="false">Spila næst</string>+ <string name="context_menu_add_to_queue" formatted="false">Bæta við biðröð</string>+ <string name="context_menu_go_to_queue" formatted="false">Fara í biðröð</string>+ <string name="context_menu_browse_album" formatted="false">Opna plötu</string>+ <string name="context_menu_browse_artist" formatted="false">Skoða listamann</string>+ <string name="context_menu_share" formatted="false">Deila</string>+ <string name="context_menu_sleep_timer" formatted="false">Tímastillir hvíldarstöðu</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Slökkva á tímastilli</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Lok lags</string>+ <string name="snackbar_added_to_queue" formatted="false">Sett í biðröð</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Bætt við lækuð lög.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Fjarlægt úr lækuðum lögum.</string>+ <string name="content_description_context_menu" formatted="false">Fleiri valkostir</string>+ <string name="close_button_content_description" formatted="false">Loka</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Vistað á</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nýr spilunarlisti</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Hætta við</string>+ <string name="create_playlist_create_button" formatted="false">Stofna</string>+ <string name="lyrics_card_title" formatted="false">Texti</string>+ <string name="lyrics_card_title_preview" formatted="false">Textasýnishorn</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Sýna texta</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Opna texta á öllum skjánum</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Deila texta</string>+ <string name="lyrics_credential_note" formatted="false">Textar frá %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Deila</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Þýða</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Loka texta</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Þýða texta</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Hætta að þýða texta</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Við kunnum ekki textann við þetta lag.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Ekki er búið að samstilla þennan texta.</string>+ <string name="av_switch_to_video" formatted="false">Skipta yfir í vídeó</string>+ <string name="av_switch_to_audio" formatted="false">Skipta yfir í hljóð</string>+ <string name="av_content_desc" formatted="false">Skipta á milli hljóðs og myndar</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Heim</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Leit</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Safnið þitt</string>+ <string name="search_header_field_hint" formatted="false">Hvað viltu hlusta á?</string>+ <string name="filter_chip_all_label" formatted="false">Allt</string>+ <string name="recents_content_filter_music" formatted="false">Tónlist</string>+ <string name="ad_category_title_podcasts" formatted="false">Hlaðvörp</string>+ <string name="audiobooks_title" formatted="false">Hljóðbækur</string>+ <string name="artist_popular_tracks" formatted="false">Vinsælt</string>+ <string name="curation_button_follow_state_text" formatted="false">Fylgjast með</string>+ <string name="curation_button_following_state_text" formatted="false">Vaktin</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Listamaður</string>+ <string name="connect_phone_is_self" formatted="false">Þessum síma</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Stuttar myndlykkjur þegar lag er spilað.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Ekki núna</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Uppfæra</string>+ <string name="context_type_description_play_queue" formatted="false">Spilar úr spilunarbiðröð</string>+ <string name="context_type_description_collection_your_library" formatted="false">Spilar úr safninu þínu</string>+ <string name="context_type_description_playlist" formatted="false">Spilar af spilunarlista</string>+ <string name="context_type_description_album" formatted="false">Spilar af plötu</string>+ <string name="context_type_description_artist" formatted="false">Spilar frá listamanni</string>+ <string name="context_type_description_show" formatted="false">Spilar úr hlaðvarpi</string>+ <string name="context_type_description_search" formatted="false">Spilar úr leit</string>+ <string name="default_notification_channel_name" formatted="false">Í spilun</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Tæki</string>+ <string name="action_share_label" formatted="false">Deila</string>+ <string name="action_queue_label" formatted="false">Biðröð</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 klukkustund</string>+ <string name="curation_actions_edit_button_title" formatted="false">Breyta</string>+ <string name="content_description_pause_button" formatted="false">Gera hlé</string>+ <string name="content_description_play_button" formatted="false">Spila</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Stokka</string>+ <string name="np_content_desc_repeat" formatted="false">Endurtaka</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Tímastillir hvíldarstöðu</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Fjarlægja</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Færa</string>+ <string name="bottom_actions_close" formatted="false">Loka</string>+ <string name="add_to_queue_action_content_description" formatted="false">Setja í biðröð</string>+ <string name="curation_button_saved_text" formatted="false">Vistað</string>+ <string name="np_content_desc_prev" formatted="false">Fyrri</string>+ <string name="np_content_desc_next" formatted="false">Áfram</string>+ <string name="accessibility_navigate_back" formatted="false">Til baka</string>+ <string name="monthly_listeners_text" formatted="false">%1$s hlustendur á mánuði</string>+ <string name="profile_bio_show_less" formatted="false">Sýna minna</string>+ <string name="audiobook_series_see_more_button" formatted="false">Sýna meira</string>+ <string name="popular_releases_section_title" formatted="false">Vinsælar útgáfur</string>+ <string name="creator_biography_section_title" formatted="false">Um</string>+ <string name="fans_also_like_section_title" formatted="false">Aðdáendur fíla líka</string>+ <string name="appears_on_section_title" formatted="false">Kemur fram á</string>+ <string name="composer_section_button_show_all" formatted="false">Sýna allt</string>+ <string name="releases_title" formatted="false">Útgefið efni</string>+ <string name="artist_releases_albums" formatted="false">Plötur</string>+ <string name="artist_releases_singles" formatted="false">Smáskífur og stuttskífur</string>+ <string name="latest_release_title" formatted="false">Nýjasta útgáfa</string>+ <string name="artist_subtitle" formatted="false">Listamaður</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Nýlegar leitir</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Hreinsa</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Hlaðvörp</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Þættir</string>+ <string name="assisted_curation_search_song" formatted="false">Lag</string>+ <string name="album" formatted="false">Plata</string>+ <string name="album_type_podcast" formatted="false">Hlaðvarp</string>+ <string name="recently_played_user_profile" formatted="false">Prófíll</string>+ <string name="connect_device_menu_logout" formatted="false">Skrá út</string>+ <string name="library_search_text_hint" formatted="false">Leita í Safninu þínu</string>+ <string name="account_title" formatted="false">Reikningur</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Flytjendur sem þú fylgist með</string>+ <string name="settings_item_crossfade_title" formatted="false">Flæðispilun</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s.</string>+ <string name="local_files_title" formatted="false">Staðbundnar skrár</string>+ <string name="local_files_empty_section_title" formatted="false">Bættu eigin hljóðskrám í safnið þitt</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Ertu með lag eða eigið hlaðvarp sem er ekki á Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Hljóðskrárnar þínar birtast hér</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Veita aðgang</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Áfram í stillingar</string>+ <string name="context_menu_download" formatted="false">Niðurhal</string>+ <string name="context_menu_undownload" formatted="false">Fjarlægja niðurhal</string>+ <string name="collection_downloaded" formatted="false">Sótt</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Sótt</string>+ <string name="download_badge_downloading_content_description" formatted="false">Sækir</string>+ <string name="download_badge_error_content_description" formatted="false">Niðurhal mistókst</string>+ <string name="download_notification_downloading" formatted="false">Hleður niður …</string>+ <string name="toast_undownload" formatted="false">Niðurhal fjarlægt.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Fjarlægja úr niðurhali?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Þú getur ekki spilað þetta utan nets.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Fjarlægja</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Fjarlægja allt niðurhal</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Viltu fjarlægja allt sótt efni?</string>+ <string name="album_type_album" formatted="false">Plata</string>+ <string name="album_type_single" formatted="false">Smáskífa</string>+ <string name="album_type_ep" formatted="false">Stuttskífa</string>+ <string name="album_type_compilation" formatted="false">Safnplata</string>+ <string name="assisted_curation_search_playlist" formatted="false">Spilunarlisti</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Bestu niðurstöðurnar</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Lög</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Listamenn</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Plötur</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Spilunarlistar</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Hreinsa síu</string>+ <string name="ad_category_title_music" formatted="false">Tónlist</string>+ <string name="made_for_you_hub_title" formatted="false">Fyrir þig</string>+ <string name="settings_item_app_language_title" formatted="false">Tungumál forrits</string>+ <string name="create_menu_item_folder_title" formatted="false">Mappa</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Ný mappa</string>+ <string name="context_menu_rename_folder" formatted="false">Endurnefna möppu</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Heiti möppu</string>+ <string name="create_playlist_content_description" formatted="false">Búa til spilunarlista</string>+ <string name="actions_picker_delete" formatted="false">Eyða</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Raða eftir</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Í stafrófsröð</string>+ <string name="your_library_sort_order_creator" formatted="false">Höfundur</string>+ <string name="your_library_sort_order_custom" formatted="false">Sérsniðin röð</string>+ <string name="settings_item_version_title" formatted="false">Útgáfa</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Opna lagið í útvarpi</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Finna í lækuðum lögum</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Finna á spilunarlista</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">„%1$s“ fannst ekki</string>+</resources>diff --git a/base/app/src/main/res/values-it/spotify_plurals.xml b/base/app/src/main/res/values-it/spotify_plurals.xmlnew file mode 100644index 00000000..5edf649b--- /dev/null+++ b/base/app/src/main/res/values-it/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d brano</item>+ <item quantity="other">%1$d brani</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d salvataggio</item>+ <item quantity="other">%1$,d salvataggi</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="other">%1$s playlist</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s brano</item>+ <item quantity="other">%1$s brani</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-it/spotify_strings.xml b/base/app/src/main/res/values-it/spotify_strings.xmlnew file mode 100644index 00000000..f7612811--- /dev/null+++ b/base/app/src/main/res/values-it/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Aggiungi a Brani che ti piacciono</string>+ <string name="collection_liked_songs_title" formatted="false">Brani che ti piacciono</string>+ <string name="context_menu_add_to_playlist" formatted="false">Aggiungi alla playlist</string>+ <string name="context_menu_play_next" formatted="false">Prossimo</string>+ <string name="context_menu_add_to_queue" formatted="false">Aggiungi in coda</string>+ <string name="context_menu_go_to_queue" formatted="false">Vai alla coda</string>+ <string name="context_menu_browse_album" formatted="false">Vai all\'album</string>+ <string name="context_menu_browse_artist" formatted="false">Vai all\'artista</string>+ <string name="context_menu_share" formatted="false">Condividi</string>+ <string name="context_menu_sleep_timer" formatted="false">Timer spegnimento</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Disattiva timer</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Fine della traccia</string>+ <string name="snackbar_added_to_queue" formatted="false">Aggiunto/i alla coda</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Aggiunto ai Brani che ti piacciono.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Rimosso dai brani che ti piacciono.</string>+ <string name="content_description_context_menu" formatted="false">Altre opzioni</string>+ <string name="close_button_content_description" formatted="false">Chiudi</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Salvato in</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nuova playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Annulla</string>+ <string name="create_playlist_create_button" formatted="false">Crea</string>+ <string name="lyrics_card_title" formatted="false">Testi</string>+ <string name="lyrics_card_title_preview" formatted="false">Anteprima del testo</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Mostra testo</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Visualizza il testo a schermo intero</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Condividi il testo</string>+ <string name="lyrics_credential_note" formatted="false">Testo fornito da %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Condividi</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Traduci</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Chiudi testo</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Traduci il testo</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Interrompi la traduzione del testo</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Uhm. Non conosciamo il testo di questo brano.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Questo testo non è ancora sincronizzato.</string>+ <string name="av_switch_to_video" formatted="false">Passa a video</string>+ <string name="av_switch_to_audio" formatted="false">Passa ad audio</string>+ <string name="av_content_desc" formatted="false">Alterna tra audio e video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Home</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Cerca</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">La tua libreria</string>+ <string name="search_header_field_hint" formatted="false">Cosa vuoi ascoltare?</string>+ <string name="filter_chip_all_label" formatted="false">Tutto</string>+ <string name="recents_content_filter_music" formatted="false">Musica</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcast</string>+ <string name="audiobooks_title" formatted="false">Audiolibri</string>+ <string name="artist_popular_tracks" formatted="false">Popolare</string>+ <string name="curation_button_follow_state_text" formatted="false">Segui</string>+ <string name="curation_button_following_state_text" formatted="false">Segui già</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artista</string>+ <string name="connect_phone_is_self" formatted="false">Questo smartphone</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Brevi immagini a ciclo continuo durante la riproduzione di un brano.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Non ora</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Aggiornamento</string>+ <string name="context_type_description_play_queue" formatted="false">Riproduzione dalla coda di riproduzione</string>+ <string name="context_type_description_collection_your_library" formatted="false">Riproduzione da La tua libreria</string>+ <string name="context_type_description_playlist" formatted="false">Riproduzione da Playlist:</string>+ <string name="context_type_description_album" formatted="false">Riproduzione dall\'album</string>+ <string name="context_type_description_artist" formatted="false">Riproduzione dall\'artista</string>+ <string name="context_type_description_show" formatted="false">Riproduzione da Podcast</string>+ <string name="context_type_description_search" formatted="false">Riproduzione da Ricerca</string>+ <string name="default_notification_channel_name" formatted="false">Ora in riproduzione</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Dispositivi</string>+ <string name="action_share_label" formatted="false">Condividi</string>+ <string name="action_queue_label" formatted="false">Aggiungi in coda</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 ora</string>+ <string name="curation_actions_edit_button_title" formatted="false">Modifica</string>+ <string name="content_description_pause_button" formatted="false">Pausa</string>+ <string name="content_description_play_button" formatted="false">Play</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Riproduzione casuale</string>+ <string name="np_content_desc_repeat" formatted="false">Ripeti</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Timer spegnimento</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Rimuovi</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Sposta</string>+ <string name="bottom_actions_close" formatted="false">Chiudi</string>+ <string name="add_to_queue_action_content_description" formatted="false">Aggiungi in coda</string>+ <string name="curation_button_saved_text" formatted="false">Contenuti salvati</string>+ <string name="np_content_desc_prev" formatted="false">Indietro</string>+ <string name="np_content_desc_next" formatted="false">Avanti</string>+ <string name="accessibility_navigate_back" formatted="false">Indietro</string>+ <string name="monthly_listeners_text" formatted="false">%1$s ascoltatori mensili</string>+ <string name="profile_bio_show_less" formatted="false">Mostra meno</string>+ <string name="audiobook_series_see_more_button" formatted="false">Mostra altro</string>+ <string name="popular_releases_section_title" formatted="false">Uscite popolari</string>+ <string name="creator_biography_section_title" formatted="false">Informazioni</string>+ <string name="fans_also_like_section_title" formatted="false">I fan apprezzano anche</string>+ <string name="appears_on_section_title" formatted="false">Compare in</string>+ <string name="composer_section_button_show_all" formatted="false">Mostra tutto</string>+ <string name="releases_title" formatted="false">Uscite</string>+ <string name="artist_releases_albums" formatted="false">Album</string>+ <string name="artist_releases_singles" formatted="false">Singoli ed EP</string>+ <string name="latest_release_title" formatted="false">Ultima uscita</string>+ <string name="artist_subtitle" formatted="false">Artista</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Ricerche recenti</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Cancella</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcast</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episodi</string>+ <string name="assisted_curation_search_song" formatted="false">Brano</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profilo</string>+ <string name="connect_device_menu_logout" formatted="false">Esci</string>+ <string name="library_search_text_hint" formatted="false">Cerca in La tua libreria</string>+ <string name="account_title" formatted="false">Account</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Artisti seguiti</string>+ <string name="settings_item_crossfade_title" formatted="false">Dissolvenza</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">File locali</string>+ <string name="local_files_empty_section_title" formatted="false">Aggiungi i tuoi file audio a La tua libreria</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Hai un brano o un podcast personale che non è su Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">I file audio verranno visualizzati qui</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Consenti l\'accesso</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Vai a Impostazioni</string>+ <string name="context_menu_download" formatted="false">Scarica</string>+ <string name="context_menu_undownload" formatted="false">Rimuovi download</string>+ <string name="collection_downloaded" formatted="false">Contenuti scaricati</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Contenuti scaricati</string>+ <string name="download_badge_downloading_content_description" formatted="false">Download in corso</string>+ <string name="download_badge_error_content_description" formatted="false">Download non riuscito</string>+ <string name="download_notification_downloading" formatted="false">Download in corso…</string>+ <string name="toast_undownload" formatted="false">Download eliminato.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Desideri rimuovere l\'elemento dai download?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Non potrai riprodurla in modalità offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Rimuovi</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Rimuovi tutti i brani scaricati</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Vuoi rimuovere tutti i brani scaricati?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Singolo</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Compilation</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Risultati migliori</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Brani</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artisti</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Album</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Cancella filtro</string>+ <string name="ad_category_title_music" formatted="false">Musica</string>+ <string name="made_for_you_hub_title" formatted="false">Realizzata per te</string>+ <string name="settings_item_app_language_title" formatted="false">Lingua app</string>+ <string name="create_menu_item_folder_title" formatted="false">Cartella</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nuova cartella</string>+ <string name="context_menu_rename_folder" formatted="false">Rinomina cartella</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Nome cartella</string>+ <string name="create_playlist_content_description" formatted="false">Crea playlist</string>+ <string name="actions_picker_delete" formatted="false">Elimina</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Ordina per</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Ordine alfabetico</string>+ <string name="your_library_sort_order_creator" formatted="false">Autore</string>+ <string name="your_library_sort_order_custom" formatted="false">Ordinamento personalizzato</string>+ <string name="settings_item_version_title" formatted="false">Versione</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Vai a Radio dal brano</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Trova in Brani che ti piacciono</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Trova nella playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Impossibile trovare \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-it/strings.xml b/base/app/src/main/res/values-it/strings.xmlnew file mode 100644index 00000000..1faecf03--- /dev/null+++ b/base/app/src/main/res/values-it/strings.xml@@ -0,0 +1,35 @@+<?xml version="1.0" encoding="utf-8"?>+<resources>+ <string name="app_name">Myspoti</string>+ <string name="aa_playlists">Playlists</string>+ <string name="aa_albums">Album</string>+ <string name="aa_artists">Artisti</string>+ <string name="aa_podcasts">Podcast</string>+ <string name="settings_amoled_theme">Tema AMOLED</string>+ <string name="settings_amoled_theme_subtitle">Sfondo nero puro per risparmiare batteria</string>+ <string name="settings_lyrics_style_spotify_default">Spotify predefinito</string>+ <string name="settings_lyrics_style_fullscreen">Schermo intero (colori dell\'album)</string>+ <string name="settings_lyrics_style_compact">Compatto</string>+ <string name="settings_lyrics_style_karaoke">Karaoke</string>+ <string name="settings_lyrics_style_bold">Grande e in grassetto</string>+ <string name="main_update_available">È disponibile un nuovo aggiornamento</string>+ <string name="notif_channel_media_name">Riproduzione multimediale</string>+ <string name="notif_channel_media_description">Controlli di riproduzione multimediale di Myspoti</string>+ <string name="notif_action_previous">Precedente</string>+ <string name="notif_action_next">Successivo</string>+ <string name="notif_action_play">Riproduci</string>+ <string name="notif_action_pause">Pausa</string>+ <string name="notif_shuffle_enable">Attiva riproduzione casuale</string>+ <string name="notif_shuffle_disable">Disattiva riproduzione casuale</string>+ <string name="notif_shuffle_disable_smart">Disattiva riproduzione casuale intelligente</string>+ <string name="notif_action_like">Mi piace</string>+ <string name="notif_action_unlike">Rimuovi \'Mi piace\'</string>+ <string name="notif_unknown_name">Sconosciuto</string>+ <string name="notif_by_artist">di %1$s</string>+ <string name="notif_repeat_disable">Disattiva ripetizione</string>+ <string name="notif_repeat_disable_one">Disattiva ripetizione del brano</string>+ <string name="notif_repeat_enable">Attiva ripetizione</string>+ <string name="bridge_player_unlocked">Lettore sbloccato</string>+ <string name="bridge_reloading">Ricaricamento…</string>+ <string name="service_disabled_message">Il servizio non è attivo</string>+</resources>diff --git a/base/app/src/main/res/values-iw/spotify_plurals.xml b/base/app/src/main/res/values-iw/spotify_plurals.xmlnew file mode 100644index 00000000..11cf6a55--- /dev/null+++ b/base/app/src/main/res/values-iw/spotify_plurals.xml@@ -0,0 +1,28 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">שיר אחד (%1$d)</item>+ <item quantity="two">%1$d שירים</item>+ <item quantity="many">%1$d שירים</item>+ <item quantity="other">%1$d שירים</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">שמירה %1$,d</item>+ <item quantity="two">%1$,d שמירות</item>+ <item quantity="many">%1$,d שמירות</item>+ <item quantity="other">%1$,d שמירות</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">פלייליסט %1$s</item>+ <item quantity="two">%1$s פלייליסטים</item>+ <item quantity="many">%1$s פלייליסטים</item>+ <item quantity="other">%1$s פלייליסטים</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">שיר %1$s</item>+ <item quantity="two">%1$s שירים</item>+ <item quantity="many">%1$s שירים</item>+ <item quantity="other">%1$s שירים</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-iw/spotify_strings.xml b/base/app/src/main/res/values-iw/spotify_strings.xmlnew file mode 100644index 00000000..586dbced--- /dev/null+++ b/base/app/src/main/res/values-iw/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">הוספה לשירים שאהבתם</string>+ <string name="collection_liked_songs_title" formatted="false">שירים שאהבתם</string>+ <string name="context_menu_add_to_playlist" formatted="false">הוספה לפלייליסט</string>+ <string name="context_menu_play_next" formatted="false">ניגון הבא בתור</string>+ <string name="context_menu_add_to_queue" formatted="false">הוספה לתור</string>+ <string name="context_menu_go_to_queue" formatted="false">מעבר לתור ההשמעה</string>+ <string name="context_menu_browse_album" formatted="false">מעבר לאלבום</string>+ <string name="context_menu_browse_artist" formatted="false">מעבר לאמן או לאמנית</string>+ <string name="context_menu_share" formatted="false">שיתוף</string>+ <string name="context_menu_sleep_timer" formatted="false">טיימר שינה</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">כיבוי הטיימר</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">סוף השיר</string>+ <string name="snackbar_added_to_queue" formatted="false">נוסף לתור</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">נוסף לרשימת השירים שאהבתם.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">הוסר מרשימת השירים שאהבתם.</string>+ <string name="content_description_context_menu" formatted="false">אפשרויות נוספות</string>+ <string name="close_button_content_description" formatted="false">סגירה</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">נשמר בתיקייה</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">פלייליסט חדש</string>+ <string name="add_to_playlist_button_cancel" formatted="false">ביטול</string>+ <string name="create_playlist_create_button" formatted="false">יצירה</string>+ <string name="lyrics_card_title" formatted="false">מילות השיר</string>+ <string name="lyrics_card_title_preview" formatted="false">תצוגה מקדימה של מילות השיר</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">הצגת מילות השיר</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">לפתיחת מילות השיר במסך מלא</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">שיתוף מילות השיר</string>+ <string name="lyrics_credential_note" formatted="false">מילות השיר סופקו על ידי %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">שיתוף</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">תרגום</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">סגירת מילות השיר</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">תרגום של מילות השיר</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">להפסיק את התרגום של מילות השיר</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">המממ. אנחנו לא מכירים את מילות השיר הזה.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">מילות השיר הזה עדיין לא מסונכרנות.</string>+ <string name="av_switch_to_video" formatted="false">מעבר לווידאו</string>+ <string name="av_switch_to_audio" formatted="false">מעבר לאודיו</string>+ <string name="av_content_desc" formatted="false">החלפת מצב בין אודיו לווידאו</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">מסך הבית</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">חיפוש</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">הספרייה</string>+ <string name="search_header_field_hint" formatted="false">לאיזה תוכן תרצו להאזין?</string>+ <string name="filter_chip_all_label" formatted="false">הכול</string>+ <string name="recents_content_filter_music" formatted="false">מוזיקה</string>+ <string name="ad_category_title_podcasts" formatted="false">פודקאסטים</string>+ <string name="audiobooks_title" formatted="false">ספרי אודיו</string>+ <string name="artist_popular_tracks" formatted="false">פופולריים</string>+ <string name="curation_button_follow_state_text" formatted="false">מעקב</string>+ <string name="curation_button_following_state_text" formatted="false">במעקב</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">אמן</string>+ <string name="connect_phone_is_self" formatted="false">טלפון זה</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">דימויים חזותיים קצרים שחוזרים על עצמם כששיר מתנגן.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">לא עכשיו</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">עדכון</string>+ <string name="context_type_description_play_queue" formatted="false">משמיע מתוך תור ההשמעה</string>+ <string name="context_type_description_collection_your_library" formatted="false">משמיע מהספרייה שלכם</string>+ <string name="context_type_description_playlist" formatted="false">משמיע מתוך הפלייליסט</string>+ <string name="context_type_description_album" formatted="false">משמיע מהאלבום</string>+ <string name="context_type_description_artist" formatted="false">משמיע מהאמן</string>+ <string name="context_type_description_show" formatted="false">משמיע מפודקאסט</string>+ <string name="context_type_description_search" formatted="false">משמיע מהחיפוש</string>+ <string name="default_notification_channel_name" formatted="false">הפריט שמופעל עכשיו</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">מכשירים</string>+ <string name="action_share_label" formatted="false">שיתוף</string>+ <string name="action_queue_label" formatted="false">תור</string>+ <string name="mute_chat_duration_one_hour" formatted="false">שעה אחת</string>+ <string name="curation_actions_edit_button_title" formatted="false">עריכה</string>+ <string name="content_description_pause_button" formatted="false">השהיה</string>+ <string name="content_description_play_button" formatted="false">הפעלה</string>+ <string name="play_mode_item_shuffle_title" formatted="false">השמעה אקראית</string>+ <string name="np_content_desc_repeat" formatted="false">השמעה חוזרת</string>+ <string name="np_content_desc_sleep_timer" formatted="false">טיימר שינה</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">הסרה</string>+ <string name="edit_playlist_items_move_chip" formatted="false">העברה</string>+ <string name="bottom_actions_close" formatted="false">סגירה</string>+ <string name="add_to_queue_action_content_description" formatted="false">הוספה לתור</string>+ <string name="curation_button_saved_text" formatted="false">נשמר</string>+ <string name="np_content_desc_prev" formatted="false">הקודם</string>+ <string name="np_content_desc_next" formatted="false">הבא</string>+ <string name="accessibility_navigate_back" formatted="false">חזרה</string>+ <string name="monthly_listeners_text" formatted="false">%1$s מאזינים חודשיים</string>+ <string name="profile_bio_show_less" formatted="false">הצגת פחות מידע</string>+ <string name="audiobook_series_see_more_button" formatted="false">פרטים נוספים</string>+ <string name="popular_releases_section_title" formatted="false">ריליסים פופולריים</string>+ <string name="creator_biography_section_title" formatted="false">אודות</string>+ <string name="fans_also_like_section_title" formatted="false">מעריצים אהבו גם</string>+ <string name="appears_on_section_title" formatted="false">מופיע ב…</string>+ <string name="composer_section_button_show_all" formatted="false">הצגת כל האפשרויות</string>+ <string name="releases_title" formatted="false">ריליסים</string>+ <string name="artist_releases_albums" formatted="false">אלבומים</string>+ <string name="artist_releases_singles" formatted="false">סינגלים ו-EP</string>+ <string name="latest_release_title" formatted="false">ריליסים אחרונים</string>+ <string name="artist_subtitle" formatted="false">אמן</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">חיפושים אחרונים</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">מחיקה</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">פודקאסטים</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">פרקים</string>+ <string name="assisted_curation_search_song" formatted="false">שיר</string>+ <string name="album" formatted="false">אלבום</string>+ <string name="album_type_podcast" formatted="false">פודקאסט</string>+ <string name="recently_played_user_profile" formatted="false">פרופיל</string>+ <string name="connect_device_menu_logout" formatted="false">התנתקות</string>+ <string name="library_search_text_hint" formatted="false">חיפוש בספרייה</string>+ <string name="account_title" formatted="false">חשבון</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">אמנים במעקב</string>+ <string name="settings_item_crossfade_title" formatted="false">קרוספייד</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d שנ\'</string>+ <string name="local_files_title" formatted="false">קבצים מקומיים</string>+ <string name="local_files_empty_section_title" formatted="false">הוסיפו לספרייה קובצי אודיו משלכם</string>+ <string name="local_files_empty_section_subtitle" formatted="false">יש לכם שיר או פודקאסט אישי שלא מופיע ב-Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">קובצי האודיו שלכם יופיעו כאן</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">להפעלת הגישה</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">מעבר אל הגדרות</string>+ <string name="context_menu_download" formatted="false">הורדה</string>+ <string name="context_menu_undownload" formatted="false">הסרת ההורדה</string>+ <string name="collection_downloaded" formatted="false">תוכן שהורד</string>+ <string name="download_badge_downloaded_content_description" formatted="false">תוכן שהורד</string>+ <string name="download_badge_downloading_content_description" formatted="false">ההורדה מתבצעת</string>+ <string name="download_badge_error_content_description" formatted="false">ההורדה נכשלה</string>+ <string name="download_notification_downloading" formatted="false">ההורדה מתבצעת…</string>+ <string name="toast_undownload" formatted="false">ההורדה הוסרה.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">להסיר מההורדות?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">לא ניתן יהיה לנגן את התוכן הזה במצב לא מקוון.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">הסרה</string>+ <string name="settings_item_remove_downloads_title" formatted="false">הסירו את כל ההורדות</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">להסיר את כל ההורדות?</string>+ <string name="album_type_album" formatted="false">אלבום</string>+ <string name="album_type_single" formatted="false">סינגל</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">אוסף</string>+ <string name="assisted_curation_search_playlist" formatted="false">פלייליסט</string>+ <string name="assisted_curation_search_filter_top" formatted="false">המובילים</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">שירים</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">אמנים</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">אלבומים</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">פלייליסטים</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">ביטול הסינון</string>+ <string name="ad_category_title_music" formatted="false">מוזיקה</string>+ <string name="made_for_you_hub_title" formatted="false">במיוחד בשבילך</string>+ <string name="settings_item_app_language_title" formatted="false">שפת האפליקציה</string>+ <string name="create_menu_item_folder_title" formatted="false">תיקייה</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">תיקייה חדשה</string>+ <string name="context_menu_rename_folder" formatted="false">שינוי שם התיקייה</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">שם התיקייה</string>+ <string name="create_playlist_content_description" formatted="false">יצירת פלייליסט</string>+ <string name="actions_picker_delete" formatted="false">מחיקה</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">מיון לפי</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">אלפביתי</string>+ <string name="your_library_sort_order_creator" formatted="false">יוצר</string>+ <string name="your_library_sort_order_custom" formatted="false">סדר מותאם אישית</string>+ <string name="settings_item_version_title" formatted="false">גרסה</string>+ <string name="context_menu_go_to_song_radio" formatted="false">מעבר לרדיו שיר</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">חיפוש בשירים שאהבתם</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">חיפוש בפלייליסט</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">לא הצלחנו למצוא את \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-ja/spotify_plurals.xml b/base/app/src/main/res/values-ja/spotify_plurals.xmlnew file mode 100644index 00000000..c0402c6e--- /dev/null+++ b/base/app/src/main/res/values-ja/spotify_plurals.xml@@ -0,0 +1,16 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="other">%1$d曲</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="other">%1$,d件の保存</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="other">%1$s件のプレイリスト</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="other">%1$s曲</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ja/spotify_strings.xml b/base/app/src/main/res/values-ja/spotify_strings.xmlnew file mode 100644index 00000000..d8f583be--- /dev/null+++ b/base/app/src/main/res/values-ja/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">お気に入りの曲に追加</string>+ <string name="collection_liked_songs_title" formatted="false">お気に入りの曲</string>+ <string name="context_menu_add_to_playlist" formatted="false">プレイリストに追加</string>+ <string name="context_menu_play_next" formatted="false">次に再生</string>+ <string name="context_menu_add_to_queue" formatted="false">[次に再生] に追加</string>+ <string name="context_menu_go_to_queue" formatted="false">再生リストに移動</string>+ <string name="context_menu_browse_album" formatted="false">アルバムに移動</string>+ <string name="context_menu_browse_artist" formatted="false">アーティストに移動</string>+ <string name="context_menu_share" formatted="false">シェア</string>+ <string name="context_menu_sleep_timer" formatted="false">スリープタイマー</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">タイマーをオフ</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">曲の終了時</string>+ <string name="snackbar_added_to_queue" formatted="false">[次に再生] に追加しました</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">お気に入りの曲に追加しました。</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">お気に入りの曲から削除しました。</string>+ <string name="content_description_context_menu" formatted="false">その他のオプション</string>+ <string name="close_button_content_description" formatted="false">閉じる</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">保存先</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">新規プレイリスト</string>+ <string name="add_to_playlist_button_cancel" formatted="false">キャンセル</string>+ <string name="create_playlist_create_button" formatted="false">作成する</string>+ <string name="lyrics_card_title" formatted="false">歌詞</string>+ <string name="lyrics_card_title_preview" formatted="false">歌詞のプレビュー</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">歌詞を表示</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">歌詞を全画面表示します</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">歌詞をシェアします</string>+ <string name="lyrics_credential_note" formatted="false">歌詞提供:%1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">シェアします</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">翻訳</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">歌詞を閉じます</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">歌詞を翻訳</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">歌詞の翻訳を停止します</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">申し訳ありません。この曲の歌詞情報はありません。</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">この歌詞はまだ音楽と同期されていません。</string>+ <string name="av_switch_to_video" formatted="false">ビデオに切り替える</string>+ <string name="av_switch_to_audio" formatted="false">オーディオに切り替える</string>+ <string name="av_content_desc" formatted="false">オーディオとビデオを切り替えます</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">ホーム</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">検索</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">マイライブラリ</string>+ <string name="search_header_field_hint" formatted="false">何を聴きたいですか?</string>+ <string name="filter_chip_all_label" formatted="false">すべて</string>+ <string name="recents_content_filter_music" formatted="false">音楽</string>+ <string name="ad_category_title_podcasts" formatted="false">ポッドキャスト</string>+ <string name="audiobooks_title" formatted="false">オーディオブック</string>+ <string name="artist_popular_tracks" formatted="false">人気の曲</string>+ <string name="curation_button_follow_state_text" formatted="false">フォローする</string>+ <string name="curation_button_following_state_text" formatted="false">フォロー中</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">アーティスト</string>+ <string name="connect_phone_is_self" formatted="false">このスマホ</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">楽曲の再生中に表示される短いループ動画。</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">後で</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">アップデート</string>+ <string name="context_type_description_play_queue" formatted="false">[次に再生]から再生中</string>+ <string name="context_type_description_collection_your_library" formatted="false">マイライブラリから再生中</string>+ <string name="context_type_description_playlist" formatted="false">プレイリストから再生中</string>+ <string name="context_type_description_album" formatted="false">アルバムから再生中</string>+ <string name="context_type_description_artist" formatted="false">アーティストページから再生中</string>+ <string name="context_type_description_show" formatted="false">ポッドキャストから再生中</string>+ <string name="context_type_description_search" formatted="false">検索から再生中</string>+ <string name="default_notification_channel_name" formatted="false">再生中</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">デバイス</string>+ <string name="action_share_label" formatted="false">シェア</string>+ <string name="action_queue_label" formatted="false">次に再生</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1時間</string>+ <string name="curation_actions_edit_button_title" formatted="false">編集</string>+ <string name="content_description_pause_button" formatted="false">一時停止</string>+ <string name="content_description_play_button" formatted="false">再生</string>+ <string name="play_mode_item_shuffle_title" formatted="false">シャッフル</string>+ <string name="np_content_desc_repeat" formatted="false">リピート</string>+ <string name="np_content_desc_sleep_timer" formatted="false">スリープタイマー</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">削除します</string>+ <string name="edit_playlist_items_move_chip" formatted="false">移動</string>+ <string name="bottom_actions_close" formatted="false">閉じる</string>+ <string name="add_to_queue_action_content_description" formatted="false">[次に再生] に追加</string>+ <string name="curation_button_saved_text" formatted="false">保存済み</string>+ <string name="np_content_desc_prev" formatted="false">前へ</string>+ <string name="np_content_desc_next" formatted="false">次へ</string>+ <string name="accessibility_navigate_back" formatted="false">戻ります</string>+ <string name="monthly_listeners_text" formatted="false">%1$s人の月間リスナー</string>+ <string name="profile_bio_show_less" formatted="false">折りたたむ</string>+ <string name="audiobook_series_see_more_button" formatted="false">さらに表示</string>+ <string name="popular_releases_section_title" formatted="false">ディスコグラフィ</string>+ <string name="creator_biography_section_title" formatted="false">詳細情報</string>+ <string name="fans_also_like_section_title" formatted="false">ファンの間で人気</string>+ <string name="appears_on_section_title" formatted="false">コラボ作品</string>+ <string name="composer_section_button_show_all" formatted="false">すべて表示</string>+ <string name="releases_title" formatted="false">リリース</string>+ <string name="artist_releases_albums" formatted="false">アルバム</string>+ <string name="artist_releases_singles" formatted="false">シングル盤と EP 盤</string>+ <string name="latest_release_title" formatted="false">最新リリース</string>+ <string name="artist_subtitle" formatted="false">アーティスト</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">最近の検索</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">クリア</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">ポッドキャスト</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">エピソード</string>+ <string name="assisted_curation_search_song" formatted="false">楽曲</string>+ <string name="album" formatted="false">アルバム</string>+ <string name="album_type_podcast" formatted="false">ポッドキャスト</string>+ <string name="recently_played_user_profile" formatted="false">プロフィール</string>+ <string name="connect_device_menu_logout" formatted="false">ログアウト</string>+ <string name="library_search_text_hint" formatted="false">マイライブラリを検索</string>+ <string name="account_title" formatted="false">アカウント</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">フォローしているアーティスト</string>+ <string name="settings_item_crossfade_title" formatted="false">クロスフェード</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d秒</string>+ <string name="local_files_title" formatted="false">ローカルファイル</string>+ <string name="local_files_empty_section_title" formatted="false">マイライブラリに独自のオーディオファイルを追加しましょう</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Spotifyにない楽曲や個人のポッドキャストがおありですか?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">オーディオファイルはこちらに表示されます</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">アクセスを許可</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">設定に移動</string>+ <string name="context_menu_download" formatted="false">ダウンロード</string>+ <string name="context_menu_undownload" formatted="false">ダウンロード済みのコンテンツを削除</string>+ <string name="collection_downloaded" formatted="false">ダウンロード済み</string>+ <string name="download_badge_downloaded_content_description" formatted="false">ダウンロード済み</string>+ <string name="download_badge_downloading_content_description" formatted="false">ダウンロード中</string>+ <string name="download_badge_error_content_description" formatted="false">ダウンロード失敗</string>+ <string name="download_notification_downloading" formatted="false">ダウンロード中…</string>+ <string name="toast_undownload" formatted="false">ダウンロードを削除しました。</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">ダウンロード済みのコンテンツを削除しますか?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">今後はこのコンテンツをオフライン再生できなくなります。</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">削除</string>+ <string name="settings_item_remove_downloads_title" formatted="false">ダウンロード済みのコンテンツをすべて削除</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">ダウンロード済みの曲をすべて削除しますか?</string>+ <string name="album_type_album" formatted="false">アルバム</string>+ <string name="album_type_single" formatted="false">シングル</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">コンピレーション</string>+ <string name="assisted_curation_search_playlist" formatted="false">プレイリスト</string>+ <string name="assisted_curation_search_filter_top" formatted="false">トップ</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">楽曲</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">アーティスト</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">アルバム</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">プレイリスト</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">検索条件をクリアします</string>+ <string name="ad_category_title_music" formatted="false">音楽</string>+ <string name="made_for_you_hub_title" formatted="false">メイド・フォー・ユー</string>+ <string name="settings_item_app_language_title" formatted="false">アプリの言語</string>+ <string name="create_menu_item_folder_title" formatted="false">フォルダ</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">新しいフォルダ</string>+ <string name="context_menu_rename_folder" formatted="false">フォルダ名を変更</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">フォルダ名</string>+ <string name="create_playlist_content_description" formatted="false">プレイリストを作成します</string>+ <string name="actions_picker_delete" formatted="false">削除</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">並べ替え</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">アルファベット順</string>+ <string name="your_library_sort_order_creator" formatted="false">クリエーターの名前順</string>+ <string name="your_library_sort_order_custom" formatted="false">カスタム順</string>+ <string name="settings_item_version_title" formatted="false">バージョン</string>+ <string name="context_menu_go_to_song_radio" formatted="false">ソングラジオに移動</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">お気に入りの曲から探す</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">プレイリストから探す</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\"に一致する情報は見つかりませんでした</string>+</resources>diff --git a/base/app/src/main/res/values-kn/spotify_plurals.xml b/base/app/src/main/res/values-kn/spotify_plurals.xmlnew file mode 100644index 00000000..460b187a--- /dev/null+++ b/base/app/src/main/res/values-kn/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d ಹಾಡು</item>+ <item quantity="other">%1$d ಹಾಡುಗಳು</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d ಸೇವ್</item>+ <item quantity="other">%1$,d ಸೇವ್ಗಳು</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s ಪ್ಲೇಲಿಸ್ಟ್</item>+ <item quantity="other">%1$s ಪ್ಲೇಲಿಸ್ಟ್ಗಳು</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s ಹಾಡು</item>+ <item quantity="other">%1$s ಹಾಡುಗಳು</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-kn/spotify_strings.xml b/base/app/src/main/res/values-kn/spotify_strings.xmlnew file mode 100644index 00000000..e844a7fc--- /dev/null+++ b/base/app/src/main/res/values-kn/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">ಲೈಕ್ ಮಾಡಿದ ಹಾಡುಗಳಿಗೆ ಸೇರಿಸಿ</string>+ <string name="collection_liked_songs_title" formatted="false">ಲೈಕ್ ಮಾಡಿದ ಹಾಡುಗಳು</string>+ <string name="context_menu_add_to_playlist" formatted="false">ಪ್ಲೇಲಿಸ್ಟ್ಗೆ ಸೇರಿಸಿ</string>+ <string name="context_menu_play_next" formatted="false">ಮುಂದೆ ಪ್ಲೇ ಮಾಡಿ</string>+ <string name="context_menu_add_to_queue" formatted="false">ಸರದಿಗೆ ಸೇರಿಸಿ</string>+ <string name="context_menu_go_to_queue" formatted="false">ಸರದಿಗೆ ಹೋಗಿ</string>+ <string name="context_menu_browse_album" formatted="false">ಆಲ್ಬಂ ಗೆ ಹೋಗಿ</string>+ <string name="context_menu_browse_artist" formatted="false">ಕಲಾವಿದರ ಪುಟಕ್ಕೆ ಹೋಗಿ</string>+ <string name="context_menu_share" formatted="false">ಶೇರ್</string>+ <string name="context_menu_sleep_timer" formatted="false">ಸ್ಲೀಪ್ ಟೈಮರ್</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">ಟೈಮರ್ ಆಫ್ ಮಾಡಿ</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">ಟ್ರ್ಯಾಕ್ ಮುಗಿದಿದೆ</string>+ <string name="snackbar_added_to_queue" formatted="false">ಸರದಿಗೆ ಸೇರಿಸಲಾಗಿದೆ</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">ಇಷ್ಟವಾದ ಹಾಡುಗಳಿಗೆ ಸೇರಿಸಲಾಗಿದೆ.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">ಲೈಕ್ ಮಾಡಿದ ಹಾಡುಗಳಿಂದ ತೆಗೆದುಹಾಕಲಾಗಿದೆ.</string>+ <string name="content_description_context_menu" formatted="false">ಮತ್ತಷ್ಟು ಆಯ್ಕೆಗಳು</string>+ <string name="close_button_content_description" formatted="false">ಮುಚ್ಚಿ</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">ಸೇವ್ ಆಗಿದೆ:</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">ಹೊಸ ಪ್ಲೇಲಿಸ್ಟ್</string>+ <string name="add_to_playlist_button_cancel" formatted="false">ರದ್ದುಮಾಡಿ</string>+ <string name="create_playlist_create_button" formatted="false">ರಚಿಸಿ</string>+ <string name="lyrics_card_title" formatted="false">ಸಾಹಿತ್ಯ</string>+ <string name="lyrics_card_title_preview" formatted="false">ಸಾಹಿತ್ಯ ಪ್ರಿವ್ಯೂ</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">ಸಾಹಿತ್ಯವನ್ನು ತೋರಿಸು</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">ಫುಲ್ಸ್ಕ್ರೀನ್ ಸಾಹಿತ್ಯವನ್ನು ತೆರೆಯಿರಿ</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">ಸಾಹಿತ್ಯವನ್ನು ಹಂಚಿಕೊಳ್ಳಿ</string>+ <string name="lyrics_credential_note" formatted="false">%1$s ಒದಗಿಸಿದ ಗೀತಸಾಹಿತ್ಯ</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">ಶೇರ್ ಮಾಡಿ</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">ಅನುವಾದಿಸಿ</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">ಸಾಹಿತ್ಯವನ್ನು ಮುಚ್ಚಿ</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">ಸಾಹಿತ್ಯವನ್ನು ಅನುವಾದಿಸಿ</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">ಸಾಹಿತ್ಯ ಅನುವಾದಿಸುವುದನ್ನು ನಿಲ್ಲಿಸಿ</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">ಹ್ಞೂಂ. ನಮಗೆ ಇದರ ಗೀತಸಾಹಿತ್ಯ ತಿಳಿದಿಲ್ಲ.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">ಈ ಸಾಹಿತ್ಯವು ಇನ್ನೂ ಟೈಂ-ಸಿಂಕ್ ಆಗಿಲ್ಲ.</string>+ <string name="av_switch_to_video" formatted="false">ವೀಡಿಯೊಗೆ ಬದಲಿಸಿ</string>+ <string name="av_switch_to_audio" formatted="false">ಆಡಿಯೋಗೆ ಬದಲಿಸಿ</string>+ <string name="av_content_desc" formatted="false">ಆಡಿಯೋ ಮತ್ತು ವೀಡಿಯೊ ನಡುವೆ ಟಾಗಲ್ ಮಾಡಿ</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">ಹೋಮ್</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">ಹುಡುಕಿ</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">ನಿಮ್ಮ ಲೈಬ್ರರಿ</string>+ <string name="search_header_field_hint" formatted="false">ನೀವು ಏನನ್ನು ಕೇಳಲು ಬಯಸುವಿರಿ?</string>+ <string name="filter_chip_all_label" formatted="false">ಎಲ್ಲ</string>+ <string name="recents_content_filter_music" formatted="false">ಸಂಗೀತ</string>+ <string name="ad_category_title_podcasts" formatted="false">ಪಾಡ್ಕಾಸ್ಟ್ಗಳು</string>+ <string name="audiobooks_title" formatted="false">ಆಡಿಯೊಬುಕ್ಗಳು</string>+ <string name="artist_popular_tracks" formatted="false">ಜನಪ್ರಿಯ</string>+ <string name="curation_button_follow_state_text" formatted="false">ಫಾಲೋ</string>+ <string name="curation_button_following_state_text" formatted="false">ಫಾಲೋಯಿಂಗ್</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">ಕಲಾವಿದರು</string>+ <string name="connect_phone_is_self" formatted="false">ಈ ಫೋನ್ನಲ್ಲಿ</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">ಹಾಡು ಪ್ಲೇ ಆಗುತ್ತಿರುವಾಗ ಸಣ್ಣ, ಲೂಪಿಂಗ್ ದೃಶ್ಯಗಳು.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">ಈಗ ಬೇಡ</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">ಅಪ್ಡೇಟ್</string>+ <string name="context_type_description_play_queue" formatted="false">ಪ್ಲೇ ಕ್ಯೂನಿಂದ ಪ್ಲೇ ಆಗುತ್ತಿದೆ</string>+ <string name="context_type_description_collection_your_library" formatted="false">ನಿಮ್ಮ ಲೈಬ್ರರಿಯಿಂದ ಪ್ಲೇ ಆಗುತ್ತಿದೆ</string>+ <string name="context_type_description_playlist" formatted="false">ಪ್ಲೇಪಟ್ಟಿಯಿಂದ ಪ್ಲೇ ಆಗುತ್ತಿದೆ</string>+ <string name="context_type_description_album" formatted="false">ಆಲ್ಬಂನಿಂದ ಪ್ಲೇ ಆಗುತ್ತಿದೆ</string>+ <string name="context_type_description_artist" formatted="false">ಕಲಾವಿದರಿಂದ ಪ್ಲೇ ಆಗುತ್ತಿದೆ</string>+ <string name="context_type_description_show" formatted="false">ಪಾಡ್ಕಾಸ್ಟ್ನಿಂದ ಪ್ಲೇ ಮಾಡಲಾಗುತ್ತಿದೆ</string>+ <string name="context_type_description_search" formatted="false">ಹುಡುಕಾಟದಿಂದ ಪ್ಲೇ ಆಗುತ್ತಿದೆ</string>+ <string name="default_notification_channel_name" formatted="false">ಇದೀಗ ಪ್ಲೇ ಮಾಡಲಾಗುತ್ತಿದೆ</string>+ <string name="label_bluetooth" formatted="false">ಬ್ಲೂಟೂತ್</string>+ <string name="mr_user_route_category_name" formatted="false">ಸಾಧನಗಳು</string>+ <string name="action_share_label" formatted="false">ಶೇರ್ ಮಾಡಿ</string>+ <string name="action_queue_label" formatted="false">ಸರದಿ</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 ಗಂಟೆ</string>+ <string name="curation_actions_edit_button_title" formatted="false">ಎಡಿಟ್ ಮಾಡಿ</string>+ <string name="content_description_pause_button" formatted="false">ವಿರಾಮ</string>+ <string name="content_description_play_button" formatted="false">ಪ್ಲೇ</string>+ <string name="play_mode_item_shuffle_title" formatted="false">ಷಫಲ್</string>+ <string name="np_content_desc_repeat" formatted="false">ಪುನಃ ಪ್ಲೇಮಾಡಿ</string>+ <string name="np_content_desc_sleep_timer" formatted="false">ಸ್ಲೀಪ್ ಟೈಮರ್</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">ತೆಗೆದುಹಾಕಿ</string>+ <string name="edit_playlist_items_move_chip" formatted="false">ಸರಿಸಿ</string>+ <string name="bottom_actions_close" formatted="false">ಮುಚ್ಚಿ</string>+ <string name="add_to_queue_action_content_description" formatted="false">ಸರದಿಗೆ ಸೇರಿಸಿ</string>+ <string name="curation_button_saved_text" formatted="false">ಉಳಿಸಲಾಗಿದೆ</string>+ <string name="np_content_desc_prev" formatted="false">ಹಿಂದಿನದು</string>+ <string name="np_content_desc_next" formatted="false">ಮುಂದೆ</string>+ <string name="accessibility_navigate_back" formatted="false">ಹಿಂದೆ</string>+ <string name="monthly_listeners_text" formatted="false">%1$s ಮಾಸಿಕ ಕೇಳುಗರು</string>+ <string name="profile_bio_show_less" formatted="false">ಕಡಿಮೆ ತೋರಿಸಿ</string>+ <string name="audiobook_series_see_more_button" formatted="false">ಇನ್ನಷ್ಟು ತೋರಿಸಿ</string>+ <string name="popular_releases_section_title" formatted="false">ಜನಪ್ರಿಯ ಬಿಡುಗಡೆಗಳು</string>+ <string name="creator_biography_section_title" formatted="false">ಹೆಚ್ಚಿನ ಮಾಹಿತಿ</string>+ <string name="fans_also_like_section_title" formatted="false">ಅಭಿಮಾನಿಗಳು ಇದನ್ನೂ ಇಷ್ಟಪಟ್ಟಿದ್ದಾರೆ</string>+ <string name="appears_on_section_title" formatted="false">ಇಲ್ಲಿ ಣಿಸಿಕೊಳ್ಳುತ್ತದೆ:</string>+ <string name="composer_section_button_show_all" formatted="false">ಎಲ್ಲವನ್ನೂ ತೋರಿಸಿ</string>+ <string name="releases_title" formatted="false">ಬಿಡುಗಡೆಗಳು</string>+ <string name="artist_releases_albums" formatted="false">ಆಲ್ಬಂಗಳು</string>+ <string name="artist_releases_singles" formatted="false">ಸೋಲೋಗಳು ಮತ್ತು EP ಗಳು</string>+ <string name="latest_release_title" formatted="false">ಇತ್ತೀಚಿನ ಬಿಡುಗಡೆ</string>+ <string name="artist_subtitle" formatted="false">ಕಲಾವಿದರು</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">ಇತ್ತೀಚಿನ ಹುಡುಕಾಟಗಳು</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">ಅಳಿಸಿ</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">ಪಾಡ್ಕಾಸ್ಟ್ಗಳು</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">ಎಪಿಸೋಡ್ಗಳು</string>+ <string name="assisted_curation_search_song" formatted="false">ಹಾಡು</string>+ <string name="album" formatted="false">ಆಲ್ಬಂ</string>+ <string name="album_type_podcast" formatted="false">ಪಾಡ್ಕಾಸ್ಟ್</string>+ <string name="recently_played_user_profile" formatted="false">ಪ್ರೊಫೈಲ್</string>+ <string name="connect_device_menu_logout" formatted="false">ಲಾಗ್ ಔಟ್</string>+ <string name="library_search_text_hint" formatted="false">ನಿಮ್ಮ ಲೈಬ್ರರಿಯನ್ನು ಹುಡುಕಿ</string>+ <string name="account_title" formatted="false">ಖಾತೆ</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">ಕಲಾವಿದರನ್ನು ಫಾಲೋ ಮಾಡಲಾಗಿದೆ</string>+ <string name="settings_item_crossfade_title" formatted="false">ಕ್ರಾಸ್ಫೇಡ್</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d ಸೆ</string>+ <string name="local_files_title" formatted="false">ಲೋಕಲ್ ಫೈಲ್ಗಳು</string>+ <string name="local_files_empty_section_title" formatted="false">ನಿಮ್ಮ ಸ್ವಂತ ಆಡಿಯೋ ಫೈಲ್ಗಳನ್ನು ನಿಮ್ಮ ಲೈಬ್ರರಿಗೆ ಸೇರಿಸಿ</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Spotify ನಲ್ಲಿ ಇಲ್ಲದ ಹಾಡು ಅಥವಾ ವೈಯಕ್ತಿಕ ಪಾಡ್ಕಾಸ್ಟ್ ಯಾವುದಾದರೂ ಇದೆಯೇ?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">ನಿಮ್ಮ ಆಡಿಯೋ ಫೈಲ್ಗಳು ಇಲ್ಲಿ ಗೋಚರಿಸುತ್ತವೆ</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">ಆ್ಯಕ್ಸೆಸ್ ನೀಡಿ</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">ಸೆಟ್ಟಿಂಗ್ಗಳಿಗೆ ಹೋಗಿ</string>+ <string name="context_menu_download" formatted="false">ಡೌನ್ಲೋಡ್</string>+ <string name="context_menu_undownload" formatted="false">ಡೌನ್ಲೋಡ್ ತೆಗೆದುಹಾಕಿ</string>+ <string name="collection_downloaded" formatted="false">ಡೌನ್ಲೋಡ್ ಆಗಿದೆ</string>+ <string name="download_badge_downloaded_content_description" formatted="false">ಡೌನ್ಲೋಡ್ ಆಗಿದೆ</string>+ <string name="download_badge_downloading_content_description" formatted="false">ಡೌನ್ಲೋಡ್ ಆಗುತ್ತಿದೆೆ</string>+ <string name="download_badge_error_content_description" formatted="false">ಡೌನ್ಲೋಡ್ ವಿಫಲವಾಗಿದೆ</string>+ <string name="download_notification_downloading" formatted="false">ಡೌನ್ಲೋಡ್ ಆಗುತ್ತಿದೆ…</string>+ <string name="toast_undownload" formatted="false">ಡೌನ್ಲೋಡ್ ತೆಗೆದುಹಾಕಲಾಗಿದೆ.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">ಡೌನ್ಲೋಡ್ಗಳಿಂದ ತೆಗೆದುಹಾಕಬೇಕೇ?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">ಇದನ್ನು ಆಫ್ಲೈನ್ನಲ್ಲಿ ಪ್ಲೇ ಮಾಡಲು ನಿಮಗೆ ಆಗುವುದಿಲ್ಲ.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">ತೆಗೆದುಹಾಕಿ</string>+ <string name="settings_item_remove_downloads_title" formatted="false">ಎಲ್ಲಾ ಡೌನ್ಲೋಡ್ಗಳನ್ನು ತೆಗೆದುಹಾಕಿ</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">ಎಲ್ಲಾ ಡೌನ್ಲೋಡ್ಗಳನ್ನು ತೆಗೆದುಹಾಕಬೇಕೇ?</string>+ <string name="album_type_album" formatted="false">ಆಲ್ಬಂ</string>+ <string name="album_type_single" formatted="false">ಸಿಂಗಲ್</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">ಸಂಕಲನಗಳು</string>+ <string name="assisted_curation_search_playlist" formatted="false">ಪ್ಲೇಲಿಸ್ಟ್</string>+ <string name="assisted_curation_search_filter_top" formatted="false">ಟಾಪ್</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">ಹಾಡುಗಳು</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">ಕಲಾವಿದರು</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">ಆಲ್ಬಂಗಳು</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">ಪ್ಲೇಲಿಸ್ಟ್ಗಳು</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">ಫಿಲ್ಟರ್ಗಳನ್ನು ಅಳಿಸಿ</string>+ <string name="ad_category_title_music" formatted="false">ಸಂಗೀತ</string>+ <string name="made_for_you_hub_title" formatted="false">ನಿಮಗಾಗಿ ಸಿದ್ಧವಾಗಿರುವುದು</string>+ <string name="settings_item_app_language_title" formatted="false">ಆ್ಯಪ್ ಭಾಷೆ</string>+ <string name="create_menu_item_folder_title" formatted="false">ಫೋಲ್ಡರ್</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">ಹೊಸ ಫೋಲ್ಡರ್</string>+ <string name="context_menu_rename_folder" formatted="false">ಫೋಲ್ಡರ್ ಅನ್ನು ಮರುಹೆಸರಿಸಿ</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">ಫೋಲ್ಡರ್ ಹೆಸರು</string>+ <string name="create_playlist_content_description" formatted="false">ಪ್ಲೇಲಿಸ್ಟ್ ರಚಿಸಿ</string>+ <string name="actions_picker_delete" formatted="false">ಅಳಿಸಿ</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">ವಿಂಗಡಿಸಿ:</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">ವರ್ಣಮಾಲೆಯ ಪ್ರಕಾರ</string>+ <string name="your_library_sort_order_creator" formatted="false">ಕ್ರಿಯೇಟರ್</string>+ <string name="your_library_sort_order_custom" formatted="false">ಕಸ್ಟಮ್ ಆರ್ಡರ್</string>+ <string name="settings_item_version_title" formatted="false">ಆವೃತ್ತಿ</string>+ <string name="context_menu_go_to_song_radio" formatted="false">ಹಾಡು ರೇಡಿಯೊಗೆ ಹೋಗಿ</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">ಲೈಕ್ ಮಾಡಿದ ಹಾಡುಗಳಲ್ಲಿ ಹುಡುಕಿ</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">ಪ್ಲೇಲಿಸ್ಟ್ನಲ್ಲಿ ಹುಡುಕಿ</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\" %1$s \" ಅನ್ನು ಹುಡುಕಲು ಆಗಲಿಲ್ಲ</string>+</resources>diff --git a/base/app/src/main/res/values-ko/spotify_plurals.xml b/base/app/src/main/res/values-ko/spotify_plurals.xmlnew file mode 100644index 00000000..85fee08e--- /dev/null+++ b/base/app/src/main/res/values-ko/spotify_plurals.xml@@ -0,0 +1,16 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="other">%1$d곡</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="other">저장 횟수: %1$,d</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="other">플레이리스트 %1$s개</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="other">곡 %1$s개</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ko/spotify_strings.xml b/base/app/src/main/res/values-ko/spotify_strings.xmlnew file mode 100644index 00000000..9af0923d--- /dev/null+++ b/base/app/src/main/res/values-ko/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">좋아요 표시한 곡에 추가</string>+ <string name="collection_liked_songs_title" formatted="false">좋아요 표시한 곡</string>+ <string name="context_menu_add_to_playlist" formatted="false">플레이리스트에 추가</string>+ <string name="context_menu_play_next" formatted="false">다음 항목 재생</string>+ <string name="context_menu_add_to_queue" formatted="false">재생목록에 추가하기</string>+ <string name="context_menu_go_to_queue" formatted="false">재생 목록 보러가기</string>+ <string name="context_menu_browse_album" formatted="false">앨범으로 가기</string>+ <string name="context_menu_browse_artist" formatted="false">아티스트로 이동하기</string>+ <string name="context_menu_share" formatted="false">공유</string>+ <string name="context_menu_sleep_timer" formatted="false">수면 타이머</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">타이머 끄기</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">트랙의 끝</string>+ <string name="snackbar_added_to_queue" formatted="false">재생목록에 추가됨</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">좋아요 표시한 곡에 추가되었습니다.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">좋아요 표시한 곡에서 삭제되었습니다.</string>+ <string name="content_description_context_menu" formatted="false">옵션 더보기</string>+ <string name="close_button_content_description" formatted="false">닫기</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">저장된 플레이리스트</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">새 플레이리스트</string>+ <string name="add_to_playlist_button_cancel" formatted="false">취소</string>+ <string name="create_playlist_create_button" formatted="false">만들기</string>+ <string name="lyrics_card_title" formatted="false">가사</string>+ <string name="lyrics_card_title_preview" formatted="false">가사 미리 보기</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">가사 표시하기</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">전체화면으로 가사 보기</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">가사 공유</string>+ <string name="lyrics_credential_note" formatted="false">가사 제공: %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">공유</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">번역</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">가사를 닫습니다</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">가사 번역</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">가사 번역을 중단합니다</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">죄송합니다. 가사를 찾을 수 없습니다.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">이 가사는 아직 동기화되지 않았습니다.</string>+ <string name="av_switch_to_video" formatted="false">동영상으로 전환</string>+ <string name="av_switch_to_audio" formatted="false">오디오로 전환</string>+ <string name="av_content_desc" formatted="false">오디오와 동영상 간 전환하기</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">홈</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">검색</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">내 라이브러리</string>+ <string name="search_header_field_hint" formatted="false">어떤 것을 듣고 싶으세요?</string>+ <string name="filter_chip_all_label" formatted="false">모두</string>+ <string name="recents_content_filter_music" formatted="false">음악</string>+ <string name="ad_category_title_podcasts" formatted="false">팟캐스트</string>+ <string name="audiobooks_title" formatted="false">오디오북</string>+ <string name="artist_popular_tracks" formatted="false">인기</string>+ <string name="curation_button_follow_state_text" formatted="false">팔로우</string>+ <string name="curation_button_following_state_text" formatted="false">팔로잉</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">아티스트</string>+ <string name="connect_phone_is_self" formatted="false">이 휴대폰</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">곡이 재생될 때 표시되는 짧고 반복되는 시각 자료입니다.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">나중에</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">업데이트</string>+ <string name="context_type_description_play_queue" formatted="false">재생 대기열에서 재생</string>+ <string name="context_type_description_collection_your_library" formatted="false">내 라이브러리에서 재생</string>+ <string name="context_type_description_playlist" formatted="false">플레이리스트에서 재생</string>+ <string name="context_type_description_album" formatted="false">앨범에서 재생</string>+ <string name="context_type_description_artist" formatted="false">아티스트에서 재생</string>+ <string name="context_type_description_show" formatted="false">팟캐스트에서 재생</string>+ <string name="context_type_description_search" formatted="false">검색에서 재생</string>+ <string name="default_notification_channel_name" formatted="false">지금 재생 중</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">기기</string>+ <string name="action_share_label" formatted="false">공유</string>+ <string name="action_queue_label" formatted="false">재생목록</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1시간</string>+ <string name="curation_actions_edit_button_title" formatted="false">수정</string>+ <string name="content_description_pause_button" formatted="false">일시 정지하기</string>+ <string name="content_description_play_button" formatted="false">재생</string>+ <string name="play_mode_item_shuffle_title" formatted="false">셔플</string>+ <string name="np_content_desc_repeat" formatted="false">반복</string>+ <string name="np_content_desc_sleep_timer" formatted="false">수면 타이머</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">삭제하기</string>+ <string name="edit_playlist_items_move_chip" formatted="false">이동</string>+ <string name="bottom_actions_close" formatted="false">닫기</string>+ <string name="add_to_queue_action_content_description" formatted="false">재생목록에 추가하기</string>+ <string name="curation_button_saved_text" formatted="false">저장됨</string>+ <string name="np_content_desc_prev" formatted="false">이전</string>+ <string name="np_content_desc_next" formatted="false">다음</string>+ <string name="accessibility_navigate_back" formatted="false">뒤로</string>+ <string name="monthly_listeners_text" formatted="false">월별 청취자 %1$s명</string>+ <string name="profile_bio_show_less" formatted="false">간단히 보기</string>+ <string name="audiobook_series_see_more_button" formatted="false">자세히 보기</string>+ <string name="popular_releases_section_title" formatted="false">인기 음악</string>+ <string name="creator_biography_section_title" formatted="false">정보</string>+ <string name="fans_also_like_section_title" formatted="false">팬들이 좋아하는 다른 음악</string>+ <string name="appears_on_section_title" formatted="false">참여 앨범</string>+ <string name="composer_section_button_show_all" formatted="false">모두 보기</string>+ <string name="releases_title" formatted="false">발매 음악</string>+ <string name="artist_releases_albums" formatted="false">앨범</string>+ <string name="artist_releases_singles" formatted="false">싱글 및 EP</string>+ <string name="latest_release_title" formatted="false">최신 발매 음악</string>+ <string name="artist_subtitle" formatted="false">아티스트</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">최근 검색</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">지우기</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">팟캐스트</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">에피소드</string>+ <string name="assisted_curation_search_song" formatted="false">곡</string>+ <string name="album" formatted="false">앨범</string>+ <string name="album_type_podcast" formatted="false">팟캐스트</string>+ <string name="recently_played_user_profile" formatted="false">프로필</string>+ <string name="connect_device_menu_logout" formatted="false">로그아웃</string>+ <string name="library_search_text_hint" formatted="false">내 라이브러리 검색하기</string>+ <string name="account_title" formatted="false">계정</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">팔로우한 아티스트</string>+ <string name="settings_item_crossfade_title" formatted="false">크로스페이드</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d초</string>+ <string name="local_files_title" formatted="false">로컬 파일</string>+ <string name="local_files_empty_section_title" formatted="false">갖고 있는 오디오 파일을 내 라이브러리에 추가하세요</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Spotify에서 제공하지 않는 곡 또는 개인 팟캐스트를 가지고 계신가요?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">내 오디오 파일이 여기에 표시됩니다</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">액세스 권한 부여</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">설정으로 이동</string>+ <string name="context_menu_download" formatted="false">다운로드</string>+ <string name="context_menu_undownload" formatted="false">다운로드 항목 삭제하기</string>+ <string name="collection_downloaded" formatted="false">다운로드 항목</string>+ <string name="download_badge_downloaded_content_description" formatted="false">다운로드됨</string>+ <string name="download_badge_downloading_content_description" formatted="false">다운로드 중</string>+ <string name="download_badge_error_content_description" formatted="false">다운로드 실패</string>+ <string name="download_notification_downloading" formatted="false">다운로드 중…</string>+ <string name="toast_undownload" formatted="false">다운로드가 삭제되었습니다.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">다운로드 항목에서 삭제하시겠어요?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">이 항목을 오프라인으로 재생할 수 없게 됩니다.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">삭제하기</string>+ <string name="settings_item_remove_downloads_title" formatted="false">다운로드한 항목 모두 삭제</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">다운로드 항목을 모두 삭제할까요?</string>+ <string name="album_type_album" formatted="false">앨범</string>+ <string name="album_type_single" formatted="false">싱글</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">컴필레이션</string>+ <string name="assisted_curation_search_playlist" formatted="false">플레이리스트</string>+ <string name="assisted_curation_search_filter_top" formatted="false">인기</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">곡</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">아티스트</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">앨범</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">플레이리스트</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">필터 지우기</string>+ <string name="ad_category_title_music" formatted="false">음악</string>+ <string name="made_for_you_hub_title" formatted="false">나만의 플레이리스트</string>+ <string name="settings_item_app_language_title" formatted="false">앱에서 사용할 언어</string>+ <string name="create_menu_item_folder_title" formatted="false">폴더</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">새 폴더</string>+ <string name="context_menu_rename_folder" formatted="false">폴더 이름 바꾸기</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">폴더 이름</string>+ <string name="create_playlist_content_description" formatted="false">플레이리스트 만들기</string>+ <string name="actions_picker_delete" formatted="false">삭제</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">정렬 기준</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">알파벳 순</string>+ <string name="your_library_sort_order_creator" formatted="false">크리에이터 순</string>+ <string name="your_library_sort_order_custom" formatted="false">맞춤형 순서</string>+ <string name="settings_item_version_title" formatted="false">버전</string>+ <string name="context_menu_go_to_song_radio" formatted="false">음악 라디오 보러가기</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">좋아요 표시한 곡에서 찾기</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">플레이리스트에서 찾기</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\"을(를) 찾을 수 없습니다.</string>+</resources>diff --git a/base/app/src/main/res/values-lt/spotify_plurals.xml b/base/app/src/main/res/values-lt/spotify_plurals.xmlnew file mode 100644index 00000000..a79526da--- /dev/null+++ b/base/app/src/main/res/values-lt/spotify_plurals.xml@@ -0,0 +1,24 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d daina</item>+ <item quantity="few">%1$d dainos</item>+ <item quantity="other">%1$d dainų</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d įsirašymas</item>+ <item quantity="few">%1$,d įsirašymai</item>+ <item quantity="other">%1$,d įsirašymų</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s grojaraštis</item>+ <item quantity="few">%1$s grojaraščiai</item>+ <item quantity="other">%1$s grojaraščių</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s daina</item>+ <item quantity="few">%1$s dainos</item>+ <item quantity="other">%1$s dainų</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-lt/spotify_strings.xml b/base/app/src/main/res/values-lt/spotify_strings.xmlnew file mode 100644index 00000000..da89b100--- /dev/null+++ b/base/app/src/main/res/values-lt/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Įtraukti į aplanką „Patinkančios dainos“</string>+ <string name="collection_liked_songs_title" formatted="false">Patinkančios dainos</string>+ <string name="context_menu_add_to_playlist" formatted="false">Įtraukti į grojaraštį</string>+ <string name="context_menu_play_next" formatted="false">Leisti kitą</string>+ <string name="context_menu_add_to_queue" formatted="false">Įtraukti į eilę</string>+ <string name="context_menu_go_to_queue" formatted="false">Eiti į eilę</string>+ <string name="context_menu_browse_album" formatted="false">Eiti į albumą</string>+ <string name="context_menu_browse_artist" formatted="false">Eiti į atlikėją</string>+ <string name="context_menu_share" formatted="false">Dalintis</string>+ <string name="context_menu_sleep_timer" formatted="false">Miego laikmatis</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Išjungti laikmatį</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Takelio pabaiga</string>+ <string name="snackbar_added_to_queue" formatted="false">Įtraukta į eilę</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Įtraukta į grojaraštį „Patinkančios dainos“.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Pašalinta iš aplanko „Patinkančios dainos“.</string>+ <string name="content_description_context_menu" formatted="false">Daugiau parinkčių</string>+ <string name="close_button_content_description" formatted="false">Uždaryti</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Įrašyta</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Naujas grojaraštis</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Atšaukti</string>+ <string name="create_playlist_create_button" formatted="false">Kurti</string>+ <string name="lyrics_card_title" formatted="false">Dainų tekstai</string>+ <string name="lyrics_card_title_preview" formatted="false">Dainos teksto peržiūra</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Rodyti dainos tekstą</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Atidaryti dainos tekstą per visą ekraną</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Bendrinti dainos tekstą</string>+ <string name="lyrics_credential_note" formatted="false">Dainos tekstą pateikė %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Dalintis</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Išversti</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Uždaryti dainos tekstą</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Išversti dainos tekstą</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Nebeversti dainos teksto</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Mes irgi nežinome šios dainos teksto.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Šie dainų tekstai kol kas nėra sinchronizuojami pagal laiką.</string>+ <string name="av_switch_to_video" formatted="false">Įjungti vaizdą</string>+ <string name="av_switch_to_audio" formatted="false">Įjungti garsą</string>+ <string name="av_content_desc" formatted="false">Perjunk į garsą arba vaizdą</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Pagrindinis</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Paieška</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Mano biblioteka</string>+ <string name="search_header_field_hint" formatted="false">Ko norėtum klausytis?</string>+ <string name="filter_chip_all_label" formatted="false">Viskas</string>+ <string name="recents_content_filter_music" formatted="false">Muzika</string>+ <string name="ad_category_title_podcasts" formatted="false">Tinklalaidės</string>+ <string name="audiobooks_title" formatted="false">Garsinės knygos</string>+ <string name="artist_popular_tracks" formatted="false">Populiarūs</string>+ <string name="curation_button_follow_state_text" formatted="false">Stebėti</string>+ <string name="curation_button_following_state_text" formatted="false">Stebi</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Atlikėjas</string>+ <string name="connect_phone_is_self" formatted="false">šiame telefone</string>+ <string name="settings_item_canvas_title" formatted="false">„Canvas“</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Trumpos pasikartojančios vizualizacijos, rodomos klausantis dainos.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Ne dabar</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Atnaujinti</string>+ <string name="context_type_description_play_queue" formatted="false">Leidžiama iš leidžiamųjų eilės</string>+ <string name="context_type_description_collection_your_library" formatted="false">Leidžiama iš aplanko „Mano biblioteka“</string>+ <string name="context_type_description_playlist" formatted="false">Leidžiama iš grojaraščio</string>+ <string name="context_type_description_album" formatted="false">Leidžiama iš albumo</string>+ <string name="context_type_description_artist" formatted="false">Leidžiama iš atlikėjo</string>+ <string name="context_type_description_show" formatted="false">Leidžiama iš tinklalaidės</string>+ <string name="context_type_description_search" formatted="false">Leidžiama iš paieškos</string>+ <string name="default_notification_channel_name" formatted="false">Dabar leidžiama</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Įrenginiai</string>+ <string name="action_share_label" formatted="false">Dalintis</string>+ <string name="action_queue_label" formatted="false">Eilė</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 val.</string>+ <string name="curation_actions_edit_button_title" formatted="false">Redaguoti</string>+ <string name="content_description_pause_button" formatted="false">Pristabdyti</string>+ <string name="content_description_play_button" formatted="false">Leisti</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Maišyti</string>+ <string name="np_content_desc_repeat" formatted="false">Kartoti</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Miego laikmatis</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Pašalinti</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Perkelti</string>+ <string name="bottom_actions_close" formatted="false">Uždaryti</string>+ <string name="add_to_queue_action_content_description" formatted="false">Įtraukti į eilę</string>+ <string name="curation_button_saved_text" formatted="false">Įrašyta</string>+ <string name="np_content_desc_prev" formatted="false">Ankstesnis</string>+ <string name="np_content_desc_next" formatted="false">Kitas</string>+ <string name="accessibility_navigate_back" formatted="false">Atgal</string>+ <string name="monthly_listeners_text" formatted="false">Klausytojų per mėnesį: %1$s</string>+ <string name="profile_bio_show_less" formatted="false">Rodyti mažiau</string>+ <string name="audiobook_series_see_more_button" formatted="false">Rodyti daugiau</string>+ <string name="popular_releases_section_title" formatted="false">Populiarūs leidimai</string>+ <string name="creator_biography_section_title" formatted="false">Apie</string>+ <string name="fans_also_like_section_title" formatted="false">Gerbėjams taip pat patinka</string>+ <string name="appears_on_section_title" formatted="false">Rodoma</string>+ <string name="composer_section_button_show_all" formatted="false">Rodyti viską</string>+ <string name="releases_title" formatted="false">Leidimai</string>+ <string name="artist_releases_albums" formatted="false">Albumai</string>+ <string name="artist_releases_singles" formatted="false">Singlai ir minialbumai</string>+ <string name="latest_release_title" formatted="false">Naujausias leidimas</string>+ <string name="artist_subtitle" formatted="false">Atlikėjas</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Neseniai ieškota</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Išvalyti</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Tinklalaidės</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Serijos</string>+ <string name="assisted_curation_search_song" formatted="false">Daina</string>+ <string name="album" formatted="false">Albumas</string>+ <string name="album_type_podcast" formatted="false">Tinklalaidė</string>+ <string name="recently_played_user_profile" formatted="false">Profilis</string>+ <string name="connect_device_menu_logout" formatted="false">Atsijungti</string>+ <string name="library_search_text_hint" formatted="false">Ieškok aplanke „Mano biblioteka“</string>+ <string name="account_title" formatted="false">Paskyra</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Stebimi atlikėjai</string>+ <string name="settings_item_crossfade_title" formatted="false">Leisti sujungiant</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d sek.</string>+ <string name="local_files_title" formatted="false">Failai šiame įrenginyje</string>+ <string name="local_files_empty_section_title" formatted="false">Įtrauk savo garso failus į aplanką „Mano biblioteka“</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Turi dainą ar asmeninę tinklalaidę, kurios nėra „Spotify“?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Tavo garso failai bus rodomi čia</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Suteikti prieigą</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Eiti į nustatymus</string>+ <string name="context_menu_download" formatted="false">Atsisiųsti</string>+ <string name="context_menu_undownload" formatted="false">Pašalinti atsisiuntimą</string>+ <string name="collection_downloaded" formatted="false">Atsisiųsta</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Atsisiųsta</string>+ <string name="download_badge_downloading_content_description" formatted="false">Atsisiunčiama</string>+ <string name="download_badge_error_content_description" formatted="false">Atsisiųsti nepavyko</string>+ <string name="download_notification_downloading" formatted="false">Atsisiunčiama…</string>+ <string name="toast_undownload" formatted="false">Atsisiuntimas pašalintas.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Pašalinti iš atsisiuntimų?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Negalėsi to leisti, kol neprisijungsi prie interneto.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Pašalinti</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Pašalinti visus atsisiuntimus</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Pašalinti visus atsisiuntimus?</string>+ <string name="album_type_album" formatted="false">Albumas</string>+ <string name="album_type_single" formatted="false">Singlas</string>+ <string name="album_type_ep" formatted="false">Minialbumas</string>+ <string name="album_type_compilation" formatted="false">Rinkinys</string>+ <string name="assisted_curation_search_playlist" formatted="false">Grojaraštis</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Geriausi atitikmenys</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Dainos</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Atlikėjai</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albumai</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Grojaraščiai</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Išvalyti filtrą</string>+ <string name="ad_category_title_music" formatted="false">Muzika</string>+ <string name="made_for_you_hub_title" formatted="false">Sukurta tau</string>+ <string name="settings_item_app_language_title" formatted="false">Programėlės kalba</string>+ <string name="create_menu_item_folder_title" formatted="false">Aplankas</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Naujas aplankas</string>+ <string name="context_menu_rename_folder" formatted="false">Pervardinti aplanką</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Aplanko pavadinimas</string>+ <string name="create_playlist_content_description" formatted="false">Kurti grojaraštį</string>+ <string name="actions_picker_delete" formatted="false">Naikinti</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Rikiuoti pagal</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Abėcėlės tvarka</string>+ <string name="your_library_sort_order_creator" formatted="false">Kūrėjas</string>+ <string name="your_library_sort_order_custom" formatted="false">Pasirinktinis eiliškumas</string>+ <string name="settings_item_version_title" formatted="false">Versija</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Eiti į radiją pagal dainą</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Ieškoti patinkančiose dainose</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Ieškoti grojaraštyje</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Nepavyko rasti „%1$s“</string>+</resources>diff --git a/base/app/src/main/res/values-lv/spotify_plurals.xml b/base/app/src/main/res/values-lv/spotify_plurals.xmlnew file mode 100644index 00000000..607a87ad--- /dev/null+++ b/base/app/src/main/res/values-lv/spotify_plurals.xml@@ -0,0 +1,24 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="zero">%1$d dziesmas</item>+ <item quantity="one">%1$d dziesma</item>+ <item quantity="other">%1$d dziesmas</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="zero">Saglabāts %1$,d reizes</item>+ <item quantity="one">Saglabāts %1$,d reizi</item>+ <item quantity="other">Saglabāts %1$,d reizes</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="zero">%1$s mūzikas saraksti</item>+ <item quantity="one">%1$s mūzikas saraksts</item>+ <item quantity="other">%1$s mūzikas saraksti</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="zero">%1$s dziesmas</item>+ <item quantity="one">%1$s dziesma</item>+ <item quantity="other">%1$s dziesmas</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-lv/spotify_strings.xml b/base/app/src/main/res/values-lv/spotify_strings.xmlnew file mode 100644index 00000000..4b4b13d3--- /dev/null+++ b/base/app/src/main/res/values-lv/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Pievienot dziesmām, kas man patīk</string>+ <string name="collection_liked_songs_title" formatted="false">Dziesmas, kas tev patīk</string>+ <string name="context_menu_add_to_playlist" formatted="false">Pievienot mūzikas sarakstam</string>+ <string name="context_menu_play_next" formatted="false">Atskaņot nākamo</string>+ <string name="context_menu_add_to_queue" formatted="false">Pievienot rindai</string>+ <string name="context_menu_go_to_queue" formatted="false">Atvērt rindu</string>+ <string name="context_menu_browse_album" formatted="false">Pāriet uz albumu</string>+ <string name="context_menu_browse_artist" formatted="false">Pāriet uz izpildītāju</string>+ <string name="context_menu_share" formatted="false">Kopīgot</string>+ <string name="context_menu_sleep_timer" formatted="false">Miega taimeris</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Izslēgt taimeri</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Ieraksta beigās</string>+ <string name="snackbar_added_to_queue" formatted="false">Pievienota rindai</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Pievienota dziesmām ar atzīmi “Patīk”.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Noņemta no dziesmām, kas atzīmētas ar “Patīk”.</string>+ <string name="content_description_context_menu" formatted="false">Citas opcijas</string>+ <string name="close_button_content_description" formatted="false">Aizvērt</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Saglabāts pie</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Jauns mūzikas saraksts</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Atcelt</string>+ <string name="create_playlist_create_button" formatted="false">Izveidot</string>+ <string name="lyrics_card_title" formatted="false">Dziesmu vārdi</string>+ <string name="lyrics_card_title_preview" formatted="false">Dziesmu vārdu priekšskatījums</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Rādīt dziesmas vārdus</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Atvērt dziesmu vārdus pilnekrāna skatā</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Dziesmu vārdu kopīgošana</string>+ <string name="lyrics_credential_note" formatted="false">Dziesmas vārdus nodrošina %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Kopīgot</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Tulkot</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Aizvērtu dziesmas vārdus</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Dziesmu vārdu tulkošana</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Pārtrauktu dziesmu vārdu tulkošanu</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Mēs nezinām šīs dziesmas vārdus.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Šie dziesmu vārdi vēl nav sinhronizēti, lai tiktu rādīti pareizajā laikā.</string>+ <string name="av_switch_to_video" formatted="false">Pārslēgties uz video</string>+ <string name="av_switch_to_audio" formatted="false">Pārslēgties uz audio</string>+ <string name="av_content_desc" formatted="false">Pārslēgties starp audio un video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Sākums</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Meklēt</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Mana bibliotēka</string>+ <string name="search_header_field_hint" formatted="false">Ko tu vēlies klausīties?</string>+ <string name="filter_chip_all_label" formatted="false">Viss</string>+ <string name="recents_content_filter_music" formatted="false">Mūzika</string>+ <string name="ad_category_title_podcasts" formatted="false">Raidieraksti</string>+ <string name="audiobooks_title" formatted="false">Audiogrāmatas</string>+ <string name="artist_popular_tracks" formatted="false">Populāras</string>+ <string name="curation_button_follow_state_text" formatted="false">Sekot</string>+ <string name="curation_button_following_state_text" formatted="false">Sekoju</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Izpildītājs</string>+ <string name="connect_phone_is_self" formatted="false">Šajā tālrunī</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Īsa, cikliska vizualizācija dziesmas atskaņošanas laikā.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Ne tagad</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Atjaunināt</string>+ <string name="context_type_description_play_queue" formatted="false">Atskaņo no atskaņošanas rindas</string>+ <string name="context_type_description_collection_your_library" formatted="false">Atskaņo no sadaļas Mana bibliotēka</string>+ <string name="context_type_description_playlist" formatted="false">Atskaņo no mūzikas saraksta</string>+ <string name="context_type_description_album" formatted="false">Atskaņo no albuma</string>+ <string name="context_type_description_artist" formatted="false">Atskaņo no izpildītāja</string>+ <string name="context_type_description_show" formatted="false">Atskaņo no raidieraksta</string>+ <string name="context_type_description_search" formatted="false">Atskaņo no meklēšanas rezultātiem</string>+ <string name="default_notification_channel_name" formatted="false">Tagad atskaņo</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Ierīces</string>+ <string name="action_share_label" formatted="false">Kopīgot</string>+ <string name="action_queue_label" formatted="false">Rinda</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 stunda</string>+ <string name="curation_actions_edit_button_title" formatted="false">Rediģēt</string>+ <string name="content_description_pause_button" formatted="false">Pauze</string>+ <string name="content_description_play_button" formatted="false">Atskaņot</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Jaukt</string>+ <string name="np_content_desc_repeat" formatted="false">Atkārtot</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Miega taimeris</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Noņemt</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Pārvietot</string>+ <string name="bottom_actions_close" formatted="false">Aizvērt</string>+ <string name="add_to_queue_action_content_description" formatted="false">Pievienot rindai</string>+ <string name="curation_button_saved_text" formatted="false">Saglabāts</string>+ <string name="np_content_desc_prev" formatted="false">Iepriekšējais</string>+ <string name="np_content_desc_next" formatted="false">Tālāk</string>+ <string name="accessibility_navigate_back" formatted="false">Atpakaļ</string>+ <string name="monthly_listeners_text" formatted="false">%1$s klausītāji mēnesī</string>+ <string name="profile_bio_show_less" formatted="false">Rādīt mazāk</string>+ <string name="audiobook_series_see_more_button" formatted="false">Rādīt vairāk</string>+ <string name="popular_releases_section_title" formatted="false">Populārs saturs</string>+ <string name="creator_biography_section_title" formatted="false">Par</string>+ <string name="fans_also_like_section_title" formatted="false">Faniem patīk arī</string>+ <string name="appears_on_section_title" formatted="false">Piedalās</string>+ <string name="composer_section_button_show_all" formatted="false">Rādīt visu</string>+ <string name="releases_title" formatted="false">Jaunumi</string>+ <string name="artist_releases_albums" formatted="false">Albumi</string>+ <string name="artist_releases_singles" formatted="false">Singli un EP</string>+ <string name="latest_release_title" formatted="false">Jaunākais</string>+ <string name="artist_subtitle" formatted="false">Izpildītājs</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Nesenie meklējumi</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Notīrīt</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Raidieraksti</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Sērijas</string>+ <string name="assisted_curation_search_song" formatted="false">Dziesma</string>+ <string name="album" formatted="false">Albums</string>+ <string name="album_type_podcast" formatted="false">Raidieraksts</string>+ <string name="recently_played_user_profile" formatted="false">Profils</string>+ <string name="connect_device_menu_logout" formatted="false">Atteikties</string>+ <string name="library_search_text_hint" formatted="false">Meklēt sadaļā Mana bibliotēka</string>+ <string name="account_title" formatted="false">Konts</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Izpildītāji, kam sekoju</string>+ <string name="settings_item_crossfade_title" formatted="false">Sapludināšana</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Vietējie faili</string>+ <string name="local_files_empty_section_title" formatted="false">Pievieno savus audio failus mapē Tava bibliotēka</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Vai tev ir dziesma vai personīgais raidieraksts, kas nav pieejams Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Tavi audio faili tiks parādīti šeit</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Piešķirt piekļuvi</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Atvērt iestatījumus</string>+ <string name="context_menu_download" formatted="false">Lejupielādēt</string>+ <string name="context_menu_undownload" formatted="false">Noņemt lejupielādi</string>+ <string name="collection_downloaded" formatted="false">Lejupielādēts</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Lejupielādēts</string>+ <string name="download_badge_downloading_content_description" formatted="false">Lejupielādē</string>+ <string name="download_badge_error_content_description" formatted="false">Lejupielāde neizdevās</string>+ <string name="download_notification_downloading" formatted="false">Lejupielādē…</string>+ <string name="toast_undownload" formatted="false">Lejupielāde noņemta.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Vai noņemt no lejupielādēm?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Tu nevarēsi to atskaņot bezsaistē.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Noņemt</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Noņemt visas lejupielādes</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Vai noņemt visas lejupielādes?</string>+ <string name="album_type_album" formatted="false">Albums</string>+ <string name="album_type_single" formatted="false">Singls</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Kompilācija</string>+ <string name="assisted_curation_search_playlist" formatted="false">Mūzikas saraksts</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Populāri</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Dziesmas</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Izpildītāji</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albumi</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Mūzikas saraksti</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Notīrīt filtru</string>+ <string name="ad_category_title_music" formatted="false">Mūzika</string>+ <string name="made_for_you_hub_title" formatted="false">Izveidots tev</string>+ <string name="settings_item_app_language_title" formatted="false">Lietotnes valoda</string>+ <string name="create_menu_item_folder_title" formatted="false">Mape</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Jauna mape</string>+ <string name="context_menu_rename_folder" formatted="false">Pārdēvēt mapi</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Mapes nosaukums</string>+ <string name="create_playlist_content_description" formatted="false">Izveidot mūzikas sarakstu</string>+ <string name="actions_picker_delete" formatted="false">Dzēst</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Kārtot pēc</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alfabētiski</string>+ <string name="your_library_sort_order_creator" formatted="false">Izveidoja</string>+ <string name="your_library_sort_order_custom" formatted="false">Pielāgota secība</string>+ <string name="settings_item_version_title" formatted="false">Versija</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Atvērt dziesmas radio</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Atrast starp dziesmām ar atzīmi “Patīk”</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Atrast mūzikas sarakstā</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Nevarēja atrast “%1$s”</string>+</resources>diff --git a/base/app/src/main/res/values-mk/spotify_plurals.xml b/base/app/src/main/res/values-mk/spotify_plurals.xmlnew file mode 100644index 00000000..de803a89--- /dev/null+++ b/base/app/src/main/res/values-mk/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d песна</item>+ <item quantity="other">%1$d песни</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d зачувување</item>+ <item quantity="other">%1$,d зачувувања</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s плејлиста</item>+ <item quantity="other">%1$s плејлисти</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s песна</item>+ <item quantity="other">%1$s песни</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-mk/spotify_strings.xml b/base/app/src/main/res/values-mk/spotify_strings.xmlnew file mode 100644index 00000000..aa39c8f0--- /dev/null+++ b/base/app/src/main/res/values-mk/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Се додаде во „Песни што ти се допаѓаат“</string>+ <string name="collection_liked_songs_title" formatted="false">Песни што ти се допаѓаат</string>+ <string name="context_menu_add_to_playlist" formatted="false">Додај во плејлиста</string>+ <string name="context_menu_play_next" formatted="false">Пушти следно</string>+ <string name="context_menu_add_to_queue" formatted="false">Додај во низа</string>+ <string name="context_menu_go_to_queue" formatted="false">Појди до низата</string>+ <string name="context_menu_browse_album" formatted="false">Појди до албумот</string>+ <string name="context_menu_browse_artist" formatted="false">Појди до изведувачот</string>+ <string name="context_menu_share" formatted="false">Сподели</string>+ <string name="context_menu_sleep_timer" formatted="false">Тајмер за спиење</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Исклучи го тајмерот</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Крај на аудиозаписот</string>+ <string name="snackbar_added_to_queue" formatted="false">Додадено во низата</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Додадено во „Песни што ти се допаѓаат“.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Отстрането од „Песни што ти се допаѓаат“.</string>+ <string name="content_description_context_menu" formatted="false">Повеќе опции</string>+ <string name="close_button_content_description" formatted="false">Затвори</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Зачувано во</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Нова плејлиста</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Откажи</string>+ <string name="create_playlist_create_button" formatted="false">Создај</string>+ <string name="lyrics_card_title" formatted="false">Текст</string>+ <string name="lyrics_card_title_preview" formatted="false">Преглед на текстот</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Прикажи текст</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Отвори го текстот на цел екран</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Сподели текст</string>+ <string name="lyrics_credential_note" formatted="false">Текстот е обезбеден од %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Сподели</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Преведи</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Затвори го текстот</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Преведи го текстот</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Престани да го преведуваш текстот</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Хмм. Не го знаеме текстот за оваа.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Текстов сè уште не е временски синхронизиран.</string>+ <string name="av_switch_to_video" formatted="false">Префрли се на видео</string>+ <string name="av_switch_to_audio" formatted="false">Префрли се на аудио</string>+ <string name="av_content_desc" formatted="false">Менувај помеѓу звук и видео</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Почеток</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Пребарување</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Твојата збирка</string>+ <string name="search_header_field_hint" formatted="false">Што сакаш да слушаш?</string>+ <string name="filter_chip_all_label" formatted="false">Сите</string>+ <string name="recents_content_filter_music" formatted="false">Музика</string>+ <string name="ad_category_title_podcasts" formatted="false">Поткасти</string>+ <string name="audiobooks_title" formatted="false">Аудиокниги</string>+ <string name="artist_popular_tracks" formatted="false">Популарни</string>+ <string name="curation_button_follow_state_text" formatted="false">Следи</string>+ <string name="curation_button_following_state_text" formatted="false">Следиш</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Изведувач</string>+ <string name="connect_phone_is_self" formatted="false">Телефонов</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Кратки, повторливи визуелни елементи кога е пуштена некоја песна.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Не сега</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Ажурирај</string>+ <string name="context_type_description_play_queue" formatted="false">Се пушта од „Пушти низа“</string>+ <string name="context_type_description_collection_your_library" formatted="false">Се пушта од „Твојата збирка“</string>+ <string name="context_type_description_playlist" formatted="false">Се пушта од плејлиста</string>+ <string name="context_type_description_album" formatted="false">Се пушта од албум</string>+ <string name="context_type_description_artist" formatted="false">Се пушта од изведувач</string>+ <string name="context_type_description_show" formatted="false">Се пушта од поткаст</string>+ <string name="context_type_description_search" formatted="false">Се пушта од „Пребарување“</string>+ <string name="default_notification_channel_name" formatted="false">Сега е пуштено</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Уреди</string>+ <string name="action_share_label" formatted="false">Сподели</string>+ <string name="action_queue_label" formatted="false">Низа</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 час</string>+ <string name="curation_actions_edit_button_title" formatted="false">Измени</string>+ <string name="content_description_pause_button" formatted="false">Паузирај</string>+ <string name="content_description_play_button" formatted="false">Пушти</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Пушти по случаен избор</string>+ <string name="np_content_desc_repeat" formatted="false">Повтори</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Тајмер за спиење</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Отстрани</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Премести</string>+ <string name="bottom_actions_close" formatted="false">Затвори</string>+ <string name="add_to_queue_action_content_description" formatted="false">Додај во низа</string>+ <string name="curation_button_saved_text" formatted="false">Зачувано</string>+ <string name="np_content_desc_prev" formatted="false">Претходно</string>+ <string name="np_content_desc_next" formatted="false">Следно</string>+ <string name="accessibility_navigate_back" formatted="false">Назад</string>+ <string name="monthly_listeners_text" formatted="false">%1$s месечни слушатели</string>+ <string name="profile_bio_show_less" formatted="false">Прикажи помалку</string>+ <string name="audiobook_series_see_more_button" formatted="false">Прикажи повеќе</string>+ <string name="popular_releases_section_title" formatted="false">Популарни изданија</string>+ <string name="creator_biography_section_title" formatted="false">Информации</string>+ <string name="fans_also_like_section_title" formatted="false">На обожавателите им се допаѓа и</string>+ <string name="appears_on_section_title" formatted="false">Се појавува на</string>+ <string name="composer_section_button_show_all" formatted="false">Прикажи ги сите</string>+ <string name="releases_title" formatted="false">Изданија</string>+ <string name="artist_releases_albums" formatted="false">Албуми</string>+ <string name="artist_releases_singles" formatted="false">Синглови и EP</string>+ <string name="latest_release_title" formatted="false">Најново издание</string>+ <string name="artist_subtitle" formatted="false">Изведувач</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Неодамнешни пребарувања</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Избриши</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Поткасти</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Епизоди</string>+ <string name="assisted_curation_search_song" formatted="false">Песна</string>+ <string name="album" formatted="false">Албум</string>+ <string name="album_type_podcast" formatted="false">Поткаст</string>+ <string name="recently_played_user_profile" formatted="false">Профил</string>+ <string name="connect_device_menu_logout" formatted="false">Одјави се</string>+ <string name="library_search_text_hint" formatted="false">Пребарај ја „Твојата збирка“</string>+ <string name="account_title" formatted="false">Сметка</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Следени изведувачи</string>+ <string name="settings_item_crossfade_title" formatted="false">Постепен премин</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d сек.</string>+ <string name="local_files_title" formatted="false">Локални датотеки</string>+ <string name="local_files_empty_section_title" formatted="false">Додавај свои аудиодатотеки во „Твојата збирка“</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Имаш песна или личен поткаст што не е на Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Аудиодатотеките ќе се прикажат тука</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Дај пристап</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Појди до „Поставки“</string>+ <string name="context_menu_download" formatted="false">Преземи</string>+ <string name="context_menu_undownload" formatted="false">Отстрани го преземањето</string>+ <string name="collection_downloaded" formatted="false">Преземено</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Преземено</string>+ <string name="download_badge_downloading_content_description" formatted="false">Се презема</string>+ <string name="download_badge_error_content_description" formatted="false">Преземањето не успеа</string>+ <string name="download_notification_downloading" formatted="false">Се презема…</string>+ <string name="toast_undownload" formatted="false">Преземањето се отстрани.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Да се отстрани од преземањата?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Нема да може да го пушташ ова офлајн.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Отстрани</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Отстрани ги сите преземања</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Да се отстранат сите преземања?</string>+ <string name="album_type_album" formatted="false">Албум</string>+ <string name="album_type_single" formatted="false">Сингл</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Компилација</string>+ <string name="assisted_curation_search_playlist" formatted="false">Плејлиста</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Најпопуларни</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Песни</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Изведувачи</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Албуми</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Плејлисти</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Избриши го филтерот</string>+ <string name="ad_category_title_music" formatted="false">Музика</string>+ <string name="made_for_you_hub_title" formatted="false">Создадени за тебе</string>+ <string name="settings_item_app_language_title" formatted="false">Јазик на апликацијата</string>+ <string name="create_menu_item_folder_title" formatted="false">Папка</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Нова папка</string>+ <string name="context_menu_rename_folder" formatted="false">Преименувај ја папката</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Име на папката</string>+ <string name="create_playlist_content_description" formatted="false">Создај плејлиста</string>+ <string name="actions_picker_delete" formatted="false">Избриши</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Подреди по</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">По азбучен ред</string>+ <string name="your_library_sort_order_creator" formatted="false">Создавач</string>+ <string name="your_library_sort_order_custom" formatted="false">Приспособен редослед</string>+ <string name="settings_item_version_title" formatted="false">Верзија</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Појди до радиото од песната</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Најди во песните што ти се допаѓаат</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Најди во плејлиста</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Не можев да најдам „%1$s“</string>+</resources>diff --git a/base/app/src/main/res/values-ml/spotify_plurals.xml b/base/app/src/main/res/values-ml/spotify_plurals.xmlnew file mode 100644index 00000000..15d87820--- /dev/null+++ b/base/app/src/main/res/values-ml/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d ഗാനം</item>+ <item quantity="other">%1$d ഗാനങ്ങൾ</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d സംരക്ഷിക്കൽ</item>+ <item quantity="other">%1$,d സംരക്ഷിക്കലുകൾ</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s പ്ലേലിസ്റ്റ്</item>+ <item quantity="other">%1$s പ്ലേലിസ്റ്റുകൾ</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s ഗാനം</item>+ <item quantity="other">%1$s ഗാനങ്ങൾ</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ml/spotify_strings.xml b/base/app/src/main/res/values-ml/spotify_strings.xmlnew file mode 100644index 00000000..239eda77--- /dev/null+++ b/base/app/src/main/res/values-ml/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">ലൈക്ക് ചെയ്ത ഗാനങ്ങളിലേക്ക് ചേർക്കുക</string>+ <string name="collection_liked_songs_title" formatted="false">ലൈക്ക് ചെയ്ത ഗാനങ്ങൾ</string>+ <string name="context_menu_add_to_playlist" formatted="false">പ്ലേലിസ്റ്റിലേക്ക് ചേർക്കുക</string>+ <string name="context_menu_play_next" formatted="false">അടുത്തത് പ്ലേ ചെയ്യുക</string>+ <string name="context_menu_add_to_queue" formatted="false">ക്യൂവിലേക്ക് ചേർക്കുക</string>+ <string name="context_menu_go_to_queue" formatted="false">ക്യൂവിലേക്ക് പോകുക</string>+ <string name="context_menu_browse_album" formatted="false">ആൽബത്തിലേക്ക് പോകുക</string>+ <string name="context_menu_browse_artist" formatted="false">ആർട്ടിസ്റ്റിലേക്ക് പോകുക</string>+ <string name="context_menu_share" formatted="false">പങ്കിടുക</string>+ <string name="context_menu_sleep_timer" formatted="false">സ്ലീപ്പ് ടൈമർ</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">ടൈമർ ഓഫാക്കുക</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">ട്രാക്കിന്റെ അവസാനം</string>+ <string name="snackbar_added_to_queue" formatted="false">ക്യൂവിലേക്ക് ചേർത്തു</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">ലൈക്ക് ചെയ്ത ഗാനങ്ങളിലേക്ക് ചേർത്തു.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">ലൈക്ക് ചെയ്ത ഗാനങ്ങളിൽ നിന്ന് നീക്കംചെയ്തു.</string>+ <string name="content_description_context_menu" formatted="false">കൂടുതൽ ഓപ്ഷനുകൾ</string>+ <string name="close_button_content_description" formatted="false">അടയ്ക്കുക</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">ഇതിൽ സംരക്ഷിച്ചിരിക്കുന്നു</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">പുതിയ പ്ലേലിസ്റ്റ്</string>+ <string name="add_to_playlist_button_cancel" formatted="false">റദ്ദാക്കുക</string>+ <string name="create_playlist_create_button" formatted="false">സൃഷ്ടിക്കുക</string>+ <string name="lyrics_card_title" formatted="false">വരികൾ</string>+ <string name="lyrics_card_title_preview" formatted="false">വരികളുടെ പ്രിവ്യൂ</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">വരികൾ കാണിക്കുക</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">വരികളുടെ പൂർണ്ണ സ്ക്രീൻ തുറക്കുക</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">വരികൾ പങ്കിടുക</string>+ <string name="lyrics_credential_note" formatted="false">വരികൾ നൽകിയിരിക്കുന്നത് %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">പങ്കിടുക</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">വിവർത്തനം ചെയ്യുക</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">വരികൾ അടയ്ക്കുക</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">വരികൾ വിവർത്തനം ചെയ്യുക</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">വരികൾ വിവർത്തനം ചെയ്യുന്നത് നിർത്തുക</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">ക്ഷമിക്കണം. ഞങ്ങൾക്ക് ഇതിന്റെ വരികൾ അറിയില്ല.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">ഈ വരികൾക്ക് ഇതുവരെയും സമയം സമന്വയിപ്പിച്ചിട്ടില്ല.</string>+ <string name="av_switch_to_video" formatted="false">വീഡിയോയിലേക്ക് മാറുക</string>+ <string name="av_switch_to_audio" formatted="false">ഓഡിയോയിലേക്ക് മാറുക</string>+ <string name="av_content_desc" formatted="false">ഓഡിയോയ്ക്കും വീഡിയോയ്ക്കുമിടയിൽ ടോഗിൾ ചെയ്യുക</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">ഹോം</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">തിരയുക</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">നിങ്ങളുടെ ലൈബ്രറി</string>+ <string name="search_header_field_hint" formatted="false">നിങ്ങൾ എന്താണ് കേൾക്കാൻ ആഗ്രഹിക്കുന്നത്?</string>+ <string name="filter_chip_all_label" formatted="false">എല്ലാം</string>+ <string name="recents_content_filter_music" formatted="false">സംഗീതം</string>+ <string name="ad_category_title_podcasts" formatted="false">പോഡ്കാസ്റ്റുകൾ</string>+ <string name="audiobooks_title" formatted="false">ഓഡിയോബുക്കുകൾ</string>+ <string name="artist_popular_tracks" formatted="false">ജനപ്രിയം</string>+ <string name="curation_button_follow_state_text" formatted="false">പിന്തുടരുക</string>+ <string name="curation_button_following_state_text" formatted="false">പിന്തുടരുന്നു</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">ആർട്ടിസ്റ്റ്</string>+ <string name="connect_phone_is_self" formatted="false">ഈ ഫോൺ</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">ഒരു ഗാനം പ്ലേ ചെയ്യുമ്പോഴുള്ള ഹ്രസ്വവും ലൂപ്പ് ചെയ്യുന്നതുമായ ദൃശ്യങ്ങൾ.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">ഇപ്പോൾ വേണ്ട</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">അപ്ഡേറ്റ് ചെയ്യുക</string>+ <string name="context_type_description_play_queue" formatted="false">പ്ലേ ക്യൂവിൽ നിന്ന് പ്ലേ ചെയ്യുന്നു</string>+ <string name="context_type_description_collection_your_library" formatted="false">നിങ്ങളുടെ ലൈബ്രറിയിൽ നിന്ന് പ്ലേ ചെയ്യുന്നു</string>+ <string name="context_type_description_playlist" formatted="false">പ്ലേലിസ്റ്റിൽ നിന്ന് പ്ലേ ചെയ്യുന്നു</string>+ <string name="context_type_description_album" formatted="false">ആൽബത്തിൽ നിന്ന് പ്ലേ ചെയ്യുന്നു</string>+ <string name="context_type_description_artist" formatted="false">ആർട്ടിസ്റ്റിൽ നിന്ന് പ്ലേ ചെയ്യുന്നു</string>+ <string name="context_type_description_show" formatted="false">പോഡ്കാസ്റ്റിൽ നിന്ന് പ്ലേ ചെയ്യുന്നു</string>+ <string name="context_type_description_search" formatted="false">തിരയലിൽ നിന്ന് പ്ലേ ചെയ്യുന്നു</string>+ <string name="default_notification_channel_name" formatted="false">ഇപ്പോൾ പ്ലേ ചെയ്യുന്നത്</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">ഉപകരണങ്ങൾ</string>+ <string name="action_share_label" formatted="false">പങ്കിടുക</string>+ <string name="action_queue_label" formatted="false">ക്യൂ</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 മണിക്കൂർ</string>+ <string name="curation_actions_edit_button_title" formatted="false">എഡിറ്റ് ചെയ്യുക</string>+ <string name="content_description_pause_button" formatted="false">തൽക്കാലം നിർത്തുക</string>+ <string name="content_description_play_button" formatted="false">പ്ലേ ചെയ്യുക</string>+ <string name="play_mode_item_shuffle_title" formatted="false">ഷഫിൾ ചെയ്യുക</string>+ <string name="np_content_desc_repeat" formatted="false">ആവർത്തിക്കുക</string>+ <string name="np_content_desc_sleep_timer" formatted="false">സ്ലീപ്പ് ടൈമർ</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">നീക്കംചെയ്യുക</string>+ <string name="edit_playlist_items_move_chip" formatted="false">നീക്കുക</string>+ <string name="bottom_actions_close" formatted="false">അടയ്ക്കുക</string>+ <string name="add_to_queue_action_content_description" formatted="false">ക്യൂവിലേക്ക് ചേർക്കുക</string>+ <string name="curation_button_saved_text" formatted="false">സംരക്ഷിച്ചു</string>+ <string name="np_content_desc_prev" formatted="false">മുമ്പത്തെ</string>+ <string name="np_content_desc_next" formatted="false">അടുത്തത്</string>+ <string name="accessibility_navigate_back" formatted="false">മടങ്ങുക</string>+ <string name="monthly_listeners_text" formatted="false">%1$s പ്രതിമാസ ശ്രോതാക്കള്</string>+ <string name="profile_bio_show_less" formatted="false">കുറച്ച് കാണിക്കുക</string>+ <string name="audiobook_series_see_more_button" formatted="false">കൂടുതൽ കാണിക്കുക</string>+ <string name="popular_releases_section_title" formatted="false">പ്രചാരമേറിയ റിലീസുകൾ</string>+ <string name="creator_biography_section_title" formatted="false">വിവരം</string>+ <string name="fans_also_like_section_title" formatted="false">ഫാൻസ് ഇതും ഇഷ്ടപ്പെടുന്നു</string>+ <string name="appears_on_section_title" formatted="false">ഇതിൽ ദൃശ്യമാകുന്നു:</string>+ <string name="composer_section_button_show_all" formatted="false">എല്ലാം കാണിക്കുക</string>+ <string name="releases_title" formatted="false">റിലീസുകൾ</string>+ <string name="artist_releases_albums" formatted="false">ആൽബങ്ങൾ</string>+ <string name="artist_releases_singles" formatted="false">സിംഗിളുകളും EP-ളും</string>+ <string name="latest_release_title" formatted="false">ഏറ്റവും പുതിയ റിലീസ്</string>+ <string name="artist_subtitle" formatted="false">ആർട്ടിസ്റ്റ്</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">സമീപകാല തിരയലുകൾ</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">മായ്ക്കുക</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">പോഡ്കാസ്റ്റുകൾ</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">എപ്പിസോഡുകൾ</string>+ <string name="assisted_curation_search_song" formatted="false">ഗാനം</string>+ <string name="album" formatted="false">ആൽബം</string>+ <string name="album_type_podcast" formatted="false">പോഡ്കാസ്റ്റ്</string>+ <string name="recently_played_user_profile" formatted="false">പ്രൊഫൈൽ</string>+ <string name="connect_device_menu_logout" formatted="false">ലോഗൗട്ട് ചെയ്യുക</string>+ <string name="library_search_text_hint" formatted="false">നിങ്ങളുടെ ലൈബ്രറി തിരയുക</string>+ <string name="account_title" formatted="false">അക്കൗണ്ട്</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">പിന്തുടരുന്ന ആർട്ടിസ്റ്റുകൾ</string>+ <string name="settings_item_crossfade_title" formatted="false">ക്രോസ്ഫേഡ്</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d സെ</string>+ <string name="local_files_title" formatted="false">ലോക്കൽ ഫയലുകൾ</string>+ <string name="local_files_empty_section_title" formatted="false">നിങ്ങളുടെ ലൈബ്രറിയിലേക്ക് സ്വന്തം ഓഡിയോ ഫയലുകൾ ചേർക്കുക</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Spotify-യിൽ ഇല്ലാത്ത ഒരു ഗാനമോ വ്യക്തിഗത പോഡ്കാസ്റ്റോ ലഭിച്ചോ?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">നിങ്ങളുടെ ഓഡിയോ ഫയലുകൾ ഇവിടെ ദൃശ്യമാകും</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">ആക്സസ് നൽകുക</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">ക്രമീകരണത്തിലേക്ക് പോകുക</string>+ <string name="context_menu_download" formatted="false">ഡൗൺലോഡ് ചെയ്യുക</string>+ <string name="context_menu_undownload" formatted="false">ഡൗൺലോഡ് നീക്കംചെയ്യുക</string>+ <string name="collection_downloaded" formatted="false">ഡൗൺലോഡ് ചെയ്തവ</string>+ <string name="download_badge_downloaded_content_description" formatted="false">ഡൗൺലോഡ് ചെയ്തു</string>+ <string name="download_badge_downloading_content_description" formatted="false">ഡൗൺലോഡ് ചെയ്യുന്നു</string>+ <string name="download_badge_error_content_description" formatted="false">ഡൗൺലോഡ് പരാജയപ്പെട്ടു</string>+ <string name="download_notification_downloading" formatted="false">ഡൗൺലോഡ് ചെയ്യുന്നു…</string>+ <string name="toast_undownload" formatted="false">ഡൗൺലോഡ് നീക്കംചെയ്തു.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">ഡൗൺലോഡുകളിൽ നിന്ന് നീക്കംചെയ്യണോ?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">നിങ്ങൾക്ക് ഇത് ഓഫ്ലൈനിൽ പ്ലേ ചെയ്യാനാവില്ല.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">നീക്കംചെയ്യുക</string>+ <string name="settings_item_remove_downloads_title" formatted="false">എല്ലാ ഡൗൺലോഡുകളും നീക്കംചെയ്യുക</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">എല്ലാ ഡൗൺലോഡുകളും നീക്കംചെയ്യണോ?</string>+ <string name="album_type_album" formatted="false">ആൽബം</string>+ <string name="album_type_single" formatted="false">സിംഗിൾ</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">സമാഹാരം</string>+ <string name="assisted_curation_search_playlist" formatted="false">പ്ലേലിസ്റ്റ്</string>+ <string name="assisted_curation_search_filter_top" formatted="false">ടോപ്പ്</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">ഗാനങ്ങൾ</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">ആർട്ടിസ്റ്റുകൾ</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">ആൽബങ്ങൾ</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">പ്ലേലിസ്റ്റുകൾ</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">ഫിൽട്ടർ ക്ലിയർ ചെയ്യുക</string>+ <string name="ad_category_title_music" formatted="false">സംഗീതം</string>+ <string name="made_for_you_hub_title" formatted="false">നിങ്ങൾക്കായി സൃഷ്ടിച്ചിരിക്കുന്നത്</string>+ <string name="settings_item_app_language_title" formatted="false">ആപ്പ് ഭാഷ</string>+ <string name="create_menu_item_folder_title" formatted="false">ഫോൾഡർ</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">പുതിയ ഫോൾഡർ</string>+ <string name="context_menu_rename_folder" formatted="false">ഫോൾഡറിന്റെ പേര് മാറ്റുക</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">ഫോൾഡറിന്റെ പേര്</string>+ <string name="create_playlist_content_description" formatted="false">പ്ലേലിസ്റ്റ് സൃഷ്ടിക്കുക</string>+ <string name="actions_picker_delete" formatted="false">ഇല്ലാതാക്കുക</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">ഇപ്രകാരം അടുക്കുക</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">അക്ഷരമാലാക്രമത്തിൽ</string>+ <string name="your_library_sort_order_creator" formatted="false">സ്രഷ്ടാവ്</string>+ <string name="your_library_sort_order_custom" formatted="false">ഇഷ്ടാനുസൃത ക്രമം</string>+ <string name="settings_item_version_title" formatted="false">പതിപ്പ്</string>+ <string name="context_menu_go_to_song_radio" formatted="false">ഗാന റേഡിയോയിലേക്ക് പോകുക</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">ലൈക്ക് ചെയ്ത ഗാനങ്ങളിൽ കണ്ടെത്തുക</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">പ്ലേലിസ്റ്റിൽ കണ്ടെത്തുക</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\" കണ്ടെത്താൻ കഴിഞ്ഞില്ല</string>+</resources>diff --git a/base/app/src/main/res/values-mr/spotify_plurals.xml b/base/app/src/main/res/values-mr/spotify_plurals.xmlnew file mode 100644index 00000000..f9ee8b8c--- /dev/null+++ b/base/app/src/main/res/values-mr/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d गाणे</item>+ <item quantity="other">%1$d गाणी</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d सेव्ह करा</item>+ <item quantity="other">%1$,d सेव्ह करतो/ते</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s प्लेलिस्ट</item>+ <item quantity="other">%1$s प्लेलिस्ट</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s गाणे</item>+ <item quantity="other">%1$s गाणी</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-mr/spotify_strings.xml b/base/app/src/main/res/values-mr/spotify_strings.xmlnew file mode 100644index 00000000..eab317f8--- /dev/null+++ b/base/app/src/main/res/values-mr/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">आवडत्या गाण्यांमध्ये जोडा</string>+ <string name="collection_liked_songs_title" formatted="false">लाइक केलेली गाणी</string>+ <string name="context_menu_add_to_playlist" formatted="false">प्लेलिस्टमध्ये जोडा</string>+ <string name="context_menu_play_next" formatted="false">पुढील प्ले करा</string>+ <string name="context_menu_add_to_queue" formatted="false">रांगेत जोडा</string>+ <string name="context_menu_go_to_queue" formatted="false">रांगेवर जा</string>+ <string name="context_menu_browse_album" formatted="false">अल्बमवर जा</string>+ <string name="context_menu_browse_artist" formatted="false">कलाकार वर जा</string>+ <string name="context_menu_share" formatted="false">शेअर करा</string>+ <string name="context_menu_sleep_timer" formatted="false">स्लीप टायमर</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">टायमर बंद करा</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">ट्रॅकचा शेवट</string>+ <string name="snackbar_added_to_queue" formatted="false">रांगेमध्ये जोडले</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">लाईक केलेल्या गाण्यामध्ये जोडले.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">लाइक केलेल्या गाण्यांमधून हटवले.</string>+ <string name="content_description_context_menu" formatted="false">अधिक पर्याय</string>+ <string name="close_button_content_description" formatted="false">बंद करा</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">मध्ये सेव्ह केले</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">नवीन प्लेलिस्ट</string>+ <string name="add_to_playlist_button_cancel" formatted="false">रद्द करा</string>+ <string name="create_playlist_create_button" formatted="false">तयार करा</string>+ <string name="lyrics_card_title" formatted="false">गाण्याचे बोल</string>+ <string name="lyrics_card_title_preview" formatted="false">गाण्याच्या बोलाचे पूर्वावलोकन</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">गाण्याचे बोल दर्शवा</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">फुलस्क्रीन गाण्याचे बोल उघडा</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">गाण्याचे बोल शेअर करा</string>+ <string name="lyrics_credential_note" formatted="false">गीत %1$s द्वारे शब्दबद्ध केले आहेत</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">शेअर करा</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">भाषांतर करा</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">गाण्याचे बोल बंद करा</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">गाण्याच्या बोलांचे भाषांतर करा</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">गाण्याच्या बोलांचे भाषांतर करणे थांबवा</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">होय. आम्हाला या एकाच्या गाण्याचे बोल माहीत नाहीत.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">या गाण्याच्या बोलांना अद्याप टाइम सिंक केलेले नाही.</string>+ <string name="av_switch_to_video" formatted="false">व्हिडिओवर स्विच करा</string>+ <string name="av_switch_to_audio" formatted="false">ऑडिओवर स्विच करा</string>+ <string name="av_content_desc" formatted="false">ऑडिओ आणि व्हिडिओ दरम्यान टॉगल करा</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">होम</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">शोधा</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">तुमची लायब्ररी</string>+ <string name="search_header_field_hint" formatted="false">तुम्हाला काय ऐकायचे आहे?</string>+ <string name="filter_chip_all_label" formatted="false">सर्व</string>+ <string name="recents_content_filter_music" formatted="false">संगीत</string>+ <string name="ad_category_title_podcasts" formatted="false">पॉडकास्ट</string>+ <string name="audiobooks_title" formatted="false">ऑडिओबुक</string>+ <string name="artist_popular_tracks" formatted="false">लोकप्रिय</string>+ <string name="curation_button_follow_state_text" formatted="false">फॉलो करा</string>+ <string name="curation_button_following_state_text" formatted="false">फॉलो करत आहे</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">कलाकार</string>+ <string name="connect_phone_is_self" formatted="false">हा फोन</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">गाणे प्ले होत असताना लहान, लूपमध्ये चालणारी व्हिज्युअल.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">आता नको</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">अपडेट</string>+ <string name="context_type_description_play_queue" formatted="false">रांग प्ले करा मधून प्ले करत आहे</string>+ <string name="context_type_description_collection_your_library" formatted="false">तुमच्या लायब्ररीमधून प्ले करत आहे</string>+ <string name="context_type_description_playlist" formatted="false">प्लेलिस्टमधून प्ले करत आहे</string>+ <string name="context_type_description_album" formatted="false">अल्बम मधून प्ले करत आहे</string>+ <string name="context_type_description_artist" formatted="false">कलाकार मधून प्ले करत आहे</string>+ <string name="context_type_description_show" formatted="false">पॉडकास्ट मधून प्ले करा</string>+ <string name="context_type_description_search" formatted="false">शोधा मधून प्ले करत आहे</string>+ <string name="default_notification_channel_name" formatted="false">आता प्ले करत आहे</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">डिव्हाइस</string>+ <string name="action_share_label" formatted="false">शेअर करा</string>+ <string name="action_queue_label" formatted="false">रांग</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 तास</string>+ <string name="curation_actions_edit_button_title" formatted="false">संपादित करा</string>+ <string name="content_description_pause_button" formatted="false">तात्काळ थांबवा</string>+ <string name="content_description_play_button" formatted="false">प्ले करा</string>+ <string name="play_mode_item_shuffle_title" formatted="false">शफल</string>+ <string name="np_content_desc_repeat" formatted="false">रिपीट करा</string>+ <string name="np_content_desc_sleep_timer" formatted="false">स्लीप टायमर</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">काढून टाका</string>+ <string name="edit_playlist_items_move_chip" formatted="false">हलवा</string>+ <string name="bottom_actions_close" formatted="false">बंद करा</string>+ <string name="add_to_queue_action_content_description" formatted="false">रांगेत जोडा</string>+ <string name="curation_button_saved_text" formatted="false">सेव्ह केलेले</string>+ <string name="np_content_desc_prev" formatted="false">मागील</string>+ <string name="np_content_desc_next" formatted="false">पुढील</string>+ <string name="accessibility_navigate_back" formatted="false">मागे</string>+ <string name="monthly_listeners_text" formatted="false">%1$s मासिक लिसनर्स</string>+ <string name="profile_bio_show_less" formatted="false">कमी दाखवा</string>+ <string name="audiobook_series_see_more_button" formatted="false">आणखी दाखवा</string>+ <string name="popular_releases_section_title" formatted="false">लोकप्रिय रिलीझेस</string>+ <string name="creator_biography_section_title" formatted="false">याविषयी</string>+ <string name="fans_also_like_section_title" formatted="false">चाहत्यांना हे देखील आवडते</string>+ <string name="appears_on_section_title" formatted="false">येथे दिसते</string>+ <string name="composer_section_button_show_all" formatted="false">सर्व दाखवा</string>+ <string name="releases_title" formatted="false">रिलीझेस</string>+ <string name="artist_releases_albums" formatted="false">अल्बम्स</string>+ <string name="artist_releases_singles" formatted="false">सिंगल्स आणि EP</string>+ <string name="latest_release_title" formatted="false">नवीनतम रिलीझ</string>+ <string name="artist_subtitle" formatted="false">कलाकार</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">अलीकडील शोध</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">साफ करा</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">पॉडकास्ट</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">भाग</string>+ <string name="assisted_curation_search_song" formatted="false">गाणे</string>+ <string name="album" formatted="false">अल्बम</string>+ <string name="album_type_podcast" formatted="false">पॉडकास्ट</string>+ <string name="recently_played_user_profile" formatted="false">प्रोफाइल</string>+ <string name="connect_device_menu_logout" formatted="false">लॉग आउट करा</string>+ <string name="library_search_text_hint" formatted="false">तुमची लायब्ररी शोधा</string>+ <string name="account_title" formatted="false">खाते</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">फॉलो केलेले कलाकार</string>+ <string name="settings_item_crossfade_title" formatted="false">क्रॉसफेड</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d से</string>+ <string name="local_files_title" formatted="false">स्थानिक फाइल्स</string>+ <string name="local_files_empty_section_title" formatted="false">तुमच्या स्वतःच्या ऑडिओ फाइल तुमच्या लायब्ररीमध्ये जोडा</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Spotify वर नसलेले गाणे किंवा वैयक्तिक पॉडकास्ट मिळाले?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">तुमच्या ऑडिओ फाइल येथे दिसतील</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">अॅक्सेस द्या</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">सेटिंग मध्ये जा</string>+ <string name="context_menu_download" formatted="false">डाउनलोड करा</string>+ <string name="context_menu_undownload" formatted="false">डाउनलोड काढून टाका</string>+ <string name="collection_downloaded" formatted="false">डाउनलोड केलेले</string>+ <string name="download_badge_downloaded_content_description" formatted="false">डाउनलोड केलेले</string>+ <string name="download_badge_downloading_content_description" formatted="false">डाउनलोड होत आहे</string>+ <string name="download_badge_error_content_description" formatted="false">डाउनलोड अयशस्वी</string>+ <string name="download_notification_downloading" formatted="false">डाउनलोड होत आहे…</string>+ <string name="toast_undownload" formatted="false">डाउनलोड हटवले.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">डाउनलोडमधून काढून टाकायचे का?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">तुम्ही हे ऑफलाइन प्ले करू शकणार नाही.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">काढून टाका</string>+ <string name="settings_item_remove_downloads_title" formatted="false">सर्व डाउनलोड काढून टाका</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">सर्व डाउनलोड काढून टाकायचे?</string>+ <string name="album_type_album" formatted="false">अल्बम</string>+ <string name="album_type_single" formatted="false">एकल</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">कंपायलेशन</string>+ <string name="assisted_curation_search_playlist" formatted="false">प्लेलिस्ट</string>+ <string name="assisted_curation_search_filter_top" formatted="false">टॉप</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">गाणी</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">कलाकार</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">अल्बम</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">प्लेलिस्ट</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">फिल्टर साफ करा</string>+ <string name="ad_category_title_music" formatted="false">संगीत</string>+ <string name="made_for_you_hub_title" formatted="false">तुमच्यासाठी बनवलेले</string>+ <string name="settings_item_app_language_title" formatted="false">अॅप भाषा</string>+ <string name="create_menu_item_folder_title" formatted="false">फोल्डर</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">नवीन फोल्डर</string>+ <string name="context_menu_rename_folder" formatted="false">फोल्डरचे नाव बदला</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">फोल्डरचे नाव</string>+ <string name="create_playlist_content_description" formatted="false">प्लेलिस्ट तयार करा</string>+ <string name="actions_picker_delete" formatted="false">हटवा</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">द्वारा क्रमवारी</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">अल्फाबेटिकल</string>+ <string name="your_library_sort_order_creator" formatted="false">निर्माणकर्ता</string>+ <string name="your_library_sort_order_custom" formatted="false">कस्टम ऑर्डर</string>+ <string name="settings_item_version_title" formatted="false">आवृत्ती</string>+ <string name="context_menu_go_to_song_radio" formatted="false">गाणे रेडिओमध्ये जा</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">लाइक केलेल्या गाण्यामध्ये शोधा</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">प्लेलिस्टमध्ये शोधा</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\" सापडले नाही</string>+</resources>diff --git a/base/app/src/main/res/values-ms/spotify_plurals.xml b/base/app/src/main/res/values-ms/spotify_plurals.xmlnew file mode 100644index 00000000..b3a6d8b0--- /dev/null+++ b/base/app/src/main/res/values-ms/spotify_plurals.xml@@ -0,0 +1,16 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="other">%1$d lagu</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="other">%1$,d penyimpanan</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="other">%1$s playlist</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="other">%1$s lagu</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ms/spotify_strings.xml b/base/app/src/main/res/values-ms/spotify_strings.xmlnew file mode 100644index 00000000..4af60e79--- /dev/null+++ b/base/app/src/main/res/values-ms/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Tambah ke Lagu Disukai</string>+ <string name="collection_liked_songs_title" formatted="false">Lagu Disukai</string>+ <string name="context_menu_add_to_playlist" formatted="false">Tambah ke playlist</string>+ <string name="context_menu_play_next" formatted="false">Main seterusnya</string>+ <string name="context_menu_add_to_queue" formatted="false">Tambah ke Baris Gilir</string>+ <string name="context_menu_go_to_queue" formatted="false">Pergi ke Baris Gilir</string>+ <string name="context_menu_browse_album" formatted="false">Pergi ke album</string>+ <string name="context_menu_browse_artist" formatted="false">Pergi ke artis</string>+ <string name="context_menu_share" formatted="false">Kongsi</string>+ <string name="context_menu_sleep_timer" formatted="false">Pemasa tidur</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Matikan pemasa</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Penghujung lagu</string>+ <string name="snackbar_added_to_queue" formatted="false">Telah ditambah ke Senarai Lagu</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Ditambahkan pada Lagu Disukai.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Dikeluarkan daripada Lagu Disukai.</string>+ <string name="content_description_context_menu" formatted="false">Lebih banyak pilihan</string>+ <string name="close_button_content_description" formatted="false">Tutup</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Disimpan dalam</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Playlist baharu</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Batal</string>+ <string name="create_playlist_create_button" formatted="false">Cipta</string>+ <string name="lyrics_card_title" formatted="false">Lirik</string>+ <string name="lyrics_card_title_preview" formatted="false">Pratonton lirik</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Tunjukkan lirik</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Buka lirik skrin penuh</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Kongsi lirik</string>+ <string name="lyrics_credential_note" formatted="false">Lirik disediakan oleh %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Kongsi</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Terjemah</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Tutup lirik</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Terjemahkan lirik</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Berhenti menterjemahkan lirik</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Kami tidak tahu lirik untuk lagu ini.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Lirik ini belum disegerakkan mengikut masa lagi.</string>+ <string name="av_switch_to_video" formatted="false">Bertukar kepada video</string>+ <string name="av_switch_to_audio" formatted="false">Bertukar kepada audio</string>+ <string name="av_content_desc" formatted="false">Togol antara audio dan video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Utama</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Cari</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Pustaka Anda</string>+ <string name="search_header_field_hint" formatted="false">Apakah yang anda mahu dengar?</string>+ <string name="filter_chip_all_label" formatted="false">Semua</string>+ <string name="recents_content_filter_music" formatted="false">Muzik</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcast</string>+ <string name="audiobooks_title" formatted="false">Buku audio</string>+ <string name="artist_popular_tracks" formatted="false">Popular</string>+ <string name="curation_button_follow_state_text" formatted="false">Ikuti</string>+ <string name="curation_button_following_state_text" formatted="false">Mengikuti</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artis</string>+ <string name="connect_phone_is_self" formatted="false">Telefon ini</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Visual pendek dan berulang apabila lagu dimainkan.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Bukan sekarang</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Kemas kini</string>+ <string name="context_type_description_play_queue" formatted="false">Memainkan dari Giliran Main</string>+ <string name="context_type_description_collection_your_library" formatted="false">Memainkan daripada Pustaka Anda</string>+ <string name="context_type_description_playlist" formatted="false">Memainkan daripada Playlist</string>+ <string name="context_type_description_album" formatted="false">Memainkan daripada Album</string>+ <string name="context_type_description_artist" formatted="false">Memainkan daripada Artis</string>+ <string name="context_type_description_show" formatted="false">Memainkan daripada Podcast</string>+ <string name="context_type_description_search" formatted="false">Memainkan dari Carian</string>+ <string name="default_notification_channel_name" formatted="false">Sedang dimainkan</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Peranti</string>+ <string name="action_share_label" formatted="false">Kongsi</string>+ <string name="action_queue_label" formatted="false">Senarai lagu</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 jam</string>+ <string name="curation_actions_edit_button_title" formatted="false">Edit</string>+ <string name="content_description_pause_button" formatted="false">Jeda</string>+ <string name="content_description_play_button" formatted="false">Main</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Rawak</string>+ <string name="np_content_desc_repeat" formatted="false">Ulang</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Pemasa tidur</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Keluarkan</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Alihkan</string>+ <string name="bottom_actions_close" formatted="false">Tutup</string>+ <string name="add_to_queue_action_content_description" formatted="false">Tambah ke senarai lagu</string>+ <string name="curation_button_saved_text" formatted="false">Disimpan</string>+ <string name="np_content_desc_prev" formatted="false">Sebelumnya</string>+ <string name="np_content_desc_next" formatted="false">Seterusnya</string>+ <string name="accessibility_navigate_back" formatted="false">Kembali</string>+ <string name="monthly_listeners_text" formatted="false">%1$s pendengar bulanan</string>+ <string name="profile_bio_show_less" formatted="false">Kurangkan paparan</string>+ <string name="audiobook_series_see_more_button" formatted="false">Tunjukkan lagi</string>+ <string name="popular_releases_section_title" formatted="false">Keluaran yang popular</string>+ <string name="creator_biography_section_title" formatted="false">Perihal</string>+ <string name="fans_also_like_section_title" formatted="false">Peminat juga suka</string>+ <string name="appears_on_section_title" formatted="false">Muncul di</string>+ <string name="composer_section_button_show_all" formatted="false">Tunjukkan semua</string>+ <string name="releases_title" formatted="false">Keluaran</string>+ <string name="artist_releases_albums" formatted="false">Album</string>+ <string name="artist_releases_singles" formatted="false">Single dan EP</string>+ <string name="latest_release_title" formatted="false">Keluaran terkini</string>+ <string name="artist_subtitle" formatted="false">Artis</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Carian terkini</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Kosongkan</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcast</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episod</string>+ <string name="assisted_curation_search_song" formatted="false">Lagu</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Log keluar</string>+ <string name="library_search_text_hint" formatted="false">Cari dalam Pustaka Anda</string>+ <string name="account_title" formatted="false">Akaun</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Artis yang diikuti</string>+ <string name="settings_item_crossfade_title" formatted="false">Lenyap silang</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Fail Tempatan</string>+ <string name="local_files_empty_section_title" formatted="false">Tambahkan fail audio anda sendiri pada Pustaka Anda</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Terdapat lagu atau podcast peribadi yang tidak ada di Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Fail audio anda akan muncul di sini</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Berikan akses</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Pergi ke Tetapan</string>+ <string name="context_menu_download" formatted="false">Muat Turun</string>+ <string name="context_menu_undownload" formatted="false">Keluarkan muat turun</string>+ <string name="collection_downloaded" formatted="false">Dimuat turun</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Dimuat turun</string>+ <string name="download_badge_downloading_content_description" formatted="false">Memuat turun</string>+ <string name="download_badge_error_content_description" formatted="false">Muat turun gagal</string>+ <string name="download_notification_downloading" formatted="false">Memuat turun…</string>+ <string name="toast_undownload" formatted="false">Muat turun dikeluarkan.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Keluarkan daripada muat turun?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Anda tidak akan dapat memainkan playlist ini di luar talian.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Keluarkan</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Keluarkan semua muat turun</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Keluarkan semua muat turun?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Kompilasi</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Hasil terbaik</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Lagu</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artis</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Album</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Kosongkan penapis</string>+ <string name="ad_category_title_music" formatted="false">Muzik</string>+ <string name="made_for_you_hub_title" formatted="false">Dibuat untuk Anda</string>+ <string name="settings_item_app_language_title" formatted="false">Bahasa aplikasi</string>+ <string name="create_menu_item_folder_title" formatted="false">Folder</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Folder baharu</string>+ <string name="context_menu_rename_folder" formatted="false">Namakan semula folder</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Nama folder</string>+ <string name="create_playlist_content_description" formatted="false">Buat playlist</string>+ <string name="actions_picker_delete" formatted="false">Padam</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Isih mengikut</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Mengikut abjad</string>+ <string name="your_library_sort_order_creator" formatted="false">Pencipta</string>+ <string name="your_library_sort_order_custom" formatted="false">Urutan tersuai</string>+ <string name="settings_item_version_title" formatted="false">Versi</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Pergi ke radio lagu</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Cari dalam Lagu Disukai</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Cari dalam playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Tidak menjumpai \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-nb/spotify_plurals.xml b/base/app/src/main/res/values-nb/spotify_plurals.xmlnew file mode 100644index 00000000..7b9adcfc--- /dev/null+++ b/base/app/src/main/res/values-nb/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d låt</item>+ <item quantity="other">%1$d låter</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d lagring</item>+ <item quantity="other">%1$,d lagringer</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s spilleliste</item>+ <item quantity="other">%1$s spillelister</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s låt</item>+ <item quantity="other">%1$s låter</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-nb/spotify_strings.xml b/base/app/src/main/res/values-nb/spotify_strings.xmlnew file mode 100644index 00000000..6b7281a3--- /dev/null+++ b/base/app/src/main/res/values-nb/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Legg til i Likte sanger</string>+ <string name="collection_liked_songs_title" formatted="false">Likte låter</string>+ <string name="context_menu_add_to_playlist" formatted="false">Legg til i spilleliste</string>+ <string name="context_menu_play_next" formatted="false">Spill av neste</string>+ <string name="context_menu_add_to_queue" formatted="false">Legg til i kø</string>+ <string name="context_menu_go_to_queue" formatted="false">Gå til kø</string>+ <string name="context_menu_browse_album" formatted="false">Gå til album</string>+ <string name="context_menu_browse_artist" formatted="false">Gå til artist</string>+ <string name="context_menu_share" formatted="false">Del</string>+ <string name="context_menu_sleep_timer" formatted="false">Søvntidtaker</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Slå av tidtakeren</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Slutten av sporet</string>+ <string name="snackbar_added_to_queue" formatted="false">Lagt til i køen</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Lagt til i Likte låter.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Fjernet fra Likte låter.</string>+ <string name="content_description_context_menu" formatted="false">Flere valg</string>+ <string name="close_button_content_description" formatted="false">Lukk</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Lagret i</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Ny spilleliste</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Avbryt</string>+ <string name="create_playlist_create_button" formatted="false">Lag</string>+ <string name="lyrics_card_title" formatted="false">Sangtekster</string>+ <string name="lyrics_card_title_preview" formatted="false">Forhåndsvisning av sangtekster</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Vis sangtekst</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Åpne sangtekster i fullskjerm</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Del sangtekst</string>+ <string name="lyrics_credential_note" formatted="false">Sangtekster levert av %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Del</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Oversett</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Lukk sangtekst</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Oversett sangtekster</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Slutt å oversette sangtekster</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Vi kan ikke sangteksten til denne.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Disse sangtekstene er ikke tidssynkronisert ennå.</string>+ <string name="av_switch_to_video" formatted="false">Bytt til video</string>+ <string name="av_switch_to_audio" formatted="false">Bytt til lyd</string>+ <string name="av_content_desc" formatted="false">Veksle mellom lyd og video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Hjem</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Søk</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Ditt bibliotek</string>+ <string name="search_header_field_hint" formatted="false">Hva vil du lytte til?</string>+ <string name="filter_chip_all_label" formatted="false">Alle</string>+ <string name="recents_content_filter_music" formatted="false">Musikk</string>+ <string name="ad_category_title_podcasts" formatted="false">Podkaster</string>+ <string name="audiobooks_title" formatted="false">Lydbøker</string>+ <string name="artist_popular_tracks" formatted="false">Populære</string>+ <string name="curation_button_follow_state_text" formatted="false">Følg</string>+ <string name="curation_button_following_state_text" formatted="false">Følger</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artist</string>+ <string name="connect_phone_is_self" formatted="false">Denne telefonen</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Korte, gjentakende bilder når en låt spilles av.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Ikke nå</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Oppdater</string>+ <string name="context_type_description_play_queue" formatted="false">Spiller av fra Spillekø</string>+ <string name="context_type_description_collection_your_library" formatted="false">Spiller av fra Biblioteket ditt</string>+ <string name="context_type_description_playlist" formatted="false">Spiller av fra Spilleliste</string>+ <string name="context_type_description_album" formatted="false">Spiller av fra album</string>+ <string name="context_type_description_artist" formatted="false">Spiller av fra artist</string>+ <string name="context_type_description_show" formatted="false">Spiller av fra Podkast</string>+ <string name="context_type_description_search" formatted="false">Spiller av fra Søk</string>+ <string name="default_notification_channel_name" formatted="false">Spilles nå</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Enheter</string>+ <string name="action_share_label" formatted="false">Del</string>+ <string name="action_queue_label" formatted="false">Kø</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 time</string>+ <string name="curation_actions_edit_button_title" formatted="false">Rediger</string>+ <string name="content_description_pause_button" formatted="false">Sett på pause</string>+ <string name="content_description_play_button" formatted="false">Spill av</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Shuffle</string>+ <string name="np_content_desc_repeat" formatted="false">Gjenta</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Søvntidtaker</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Fjern</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Flytt</string>+ <string name="bottom_actions_close" formatted="false">Lukk</string>+ <string name="add_to_queue_action_content_description" formatted="false">Legg til i kø</string>+ <string name="curation_button_saved_text" formatted="false">Lagret</string>+ <string name="np_content_desc_prev" formatted="false">Forrige</string>+ <string name="np_content_desc_next" formatted="false">Neste</string>+ <string name="accessibility_navigate_back" formatted="false">Tilbake</string>+ <string name="monthly_listeners_text" formatted="false">%1$s månedlige lyttere</string>+ <string name="profile_bio_show_less" formatted="false">Vis mindre</string>+ <string name="audiobook_series_see_more_button" formatted="false">Vis mer</string>+ <string name="popular_releases_section_title" formatted="false">Populære utgivelser</string>+ <string name="creator_biography_section_title" formatted="false">Om</string>+ <string name="fans_also_like_section_title" formatted="false">Fans liker også</string>+ <string name="appears_on_section_title" formatted="false">Medvirker på</string>+ <string name="composer_section_button_show_all" formatted="false">Vis alle</string>+ <string name="releases_title" formatted="false">Utgivelser</string>+ <string name="artist_releases_albums" formatted="false">Album</string>+ <string name="artist_releases_singles" formatted="false">Singler og EP-er</string>+ <string name="latest_release_title" formatted="false">Nyeste</string>+ <string name="artist_subtitle" formatted="false">Artist</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Nylige søk</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Tøm</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podkaster</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episoder</string>+ <string name="assisted_curation_search_song" formatted="false">Låt</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podkast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Logg av</string>+ <string name="library_search_text_hint" formatted="false">Søk i Ditt bibliotek</string>+ <string name="account_title" formatted="false">Konto</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Fulgte artister</string>+ <string name="settings_item_crossfade_title" formatted="false">Crossfade</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d sek</string>+ <string name="local_files_title" formatted="false">Lokale filer</string>+ <string name="local_files_empty_section_title" formatted="false">Legg til dine egne lydfiler i biblioteket ditt</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Har du en låt eller personlig podkast som ikke er på Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Lydfilene dine vises her</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Gi tilgang</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Gå til Innstillinger</string>+ <string name="context_menu_download" formatted="false">Last ned</string>+ <string name="context_menu_undownload" formatted="false">Fjern nedlasting</string>+ <string name="collection_downloaded" formatted="false">Lastet ned</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Lastet ned</string>+ <string name="download_badge_downloading_content_description" formatted="false">Laster ned</string>+ <string name="download_badge_error_content_description" formatted="false">Nedlasting mislyktes</string>+ <string name="download_notification_downloading" formatted="false">Laster ned …</string>+ <string name="toast_undownload" formatted="false">Nedlasting fjernet.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Fjern fra nedlastinger?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Du kan ikke spille av dette uten nettilgang.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Fjern</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Fjern alle nedlastinger</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Fjern alle nedlastinger?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Singel</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Samling</string>+ <string name="assisted_curation_search_playlist" formatted="false">Spilleliste</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Populært</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Låter</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artister</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Album</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Spillelister</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Fjern filter</string>+ <string name="ad_category_title_music" formatted="false">Musikk</string>+ <string name="made_for_you_hub_title" formatted="false">Spesielt for deg</string>+ <string name="settings_item_app_language_title" formatted="false">Språk i appen</string>+ <string name="create_menu_item_folder_title" formatted="false">Mappe</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Ny mappe</string>+ <string name="context_menu_rename_folder" formatted="false">Gi nytt navn til mappen</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Mappenavn</string>+ <string name="create_playlist_content_description" formatted="false">Lag spilleliste</string>+ <string name="actions_picker_delete" formatted="false">Slett</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sorter etter</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alfabetisk</string>+ <string name="your_library_sort_order_creator" formatted="false">Kreatør</string>+ <string name="your_library_sort_order_custom" formatted="false">Egendefinert rekkefølge</string>+ <string name="settings_item_version_title" formatted="false">Versjon</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Gå til låtradio</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Finn i Likte låter</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Finn i spilleliste</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Fant ikke «%1$s»</string>+</resources>diff --git a/base/app/src/main/res/values-ne/spotify_plurals.xml b/base/app/src/main/res/values-ne/spotify_plurals.xmlnew file mode 100644index 00000000..5b593f81--- /dev/null+++ b/base/app/src/main/res/values-ne/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d गीत</item>+ <item quantity="other">%1$d वटा गीतहरू</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d वटा सेभ</item>+ <item quantity="other">%1$,d वटा सेभ</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s प्लेलिस्ट</item>+ <item quantity="other">%1$s प्लेलिस्टहरू</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s गीत</item>+ <item quantity="other">%1$s वटा गीतहरू</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ne/spotify_strings.xml b/base/app/src/main/res/values-ne/spotify_strings.xmlnew file mode 100644index 00000000..dee24be4--- /dev/null+++ b/base/app/src/main/res/values-ne/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">\"मन पराइएका गीतहरू\" मा हाल्नुहोस्</string>+ <string name="collection_liked_songs_title" formatted="false">मन पराइएका गीतहरू</string>+ <string name="context_menu_add_to_playlist" formatted="false">प्लेलिस्टमा थप्नुहोस्</string>+ <string name="context_menu_play_next" formatted="false">अर्को प्ले गर्नुहोस्</string>+ <string name="context_menu_add_to_queue" formatted="false">लाइनमा राख्नुहोस्</string>+ <string name="context_menu_go_to_queue" formatted="false">लाइनमा जानुहोस्</string>+ <string name="context_menu_browse_album" formatted="false">एल्बमा जानुहोस्</string>+ <string name="context_menu_browse_artist" formatted="false">\'कलाकार\' मा जानुहोस्</string>+ <string name="context_menu_share" formatted="false">सेयर गर्नुहोस्</string>+ <string name="context_menu_sleep_timer" formatted="false">स्लिप टाइमर</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">टाइमर अफ गर्नुहोस्</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">ट्र्याकको अन्त्य</string>+ <string name="snackbar_added_to_queue" formatted="false">लाइनमा राखियो</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">मनपराइएका गीतहरूमा थपियो।</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">मनपरेका गीतहरूबाट हटाइयो।</string>+ <string name="content_description_context_menu" formatted="false">थप विकल्पहरू</string>+ <string name="close_button_content_description" formatted="false">बन्द गर्नुहोस्</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">यहाँ सेभ गरिएको</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">नयाँ प्लेलिस्ट</string>+ <string name="add_to_playlist_button_cancel" formatted="false">रद्द गर्नुहोस्</string>+ <string name="create_playlist_create_button" formatted="false">सिर्जना गर्नुहोस्</string>+ <string name="lyrics_card_title" formatted="false">लिरिक्स</string>+ <string name="lyrics_card_title_preview" formatted="false">लिरिक्स प्रिभ्यू</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">लिरिक्स देखाउनुहोस्</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">लिरिक्स कार्ड फुल स्क्रिनमा खोल्नुहोस्</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">लिरिक्स सेयर गर्नुहोस्</string>+ <string name="lyrics_credential_note" formatted="false">%1$s द्वारा उपलब्ध गराइएको लिरिक्स</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">सेयर गर्नुहोस्</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">अनुवाद गर्नुहोस्</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">लिरिक्स बन्द गर्नुहोस्</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">गीतका शब्दहरू अनुवाद गर्नुहोस्</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">लिरिक्स अनुवाद गर्न छाड्नुहोस्</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">ओहो। हामीलाई यसको लिरिक्स थाहा छैन।</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">यी लिरिक्स र समय अहिलेसम्म सिङ्क गरिएको छैन।</string>+ <string name="av_switch_to_video" formatted="false">भिडियो प्रयोग गर्नुहोस्</string>+ <string name="av_switch_to_audio" formatted="false">अडियो प्रयोग गर्नुहोस्</string>+ <string name="av_content_desc" formatted="false">अडियो र भिडियोका बिचमा टगल गर्नुहोस्</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">होम</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">खोज्नुहोस्</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">तपाईंको लाइब्रेरी</string>+ <string name="search_header_field_hint" formatted="false">तपाईं कुन गीत सुन्न चाहनुहुन्छ?</string>+ <string name="filter_chip_all_label" formatted="false">सबै</string>+ <string name="recents_content_filter_music" formatted="false">सङ्गीत</string>+ <string name="ad_category_title_podcasts" formatted="false">पोडकास्टहरू</string>+ <string name="audiobooks_title" formatted="false">अडियोबुकहरू</string>+ <string name="artist_popular_tracks" formatted="false">लोकप्रिय</string>+ <string name="curation_button_follow_state_text" formatted="false">फलो गर्नुहोस्</string>+ <string name="curation_button_following_state_text" formatted="false">फलो गरिरहेको</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">कलाकार</string>+ <string name="connect_phone_is_self" formatted="false">यो फोनमा</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">गीत बजिरहेको बेला छोटो, लुपिङ दृश्यहरू।</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">अहिले होइन</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">अपडेट गर्नुहोस्</string>+ <string name="context_type_description_play_queue" formatted="false">प्ले लाइनबाट प्ले गर्दै</string>+ <string name="context_type_description_collection_your_library" formatted="false">तपाईंको लाइब्रेरीबाट प्ले गर्दै</string>+ <string name="context_type_description_playlist" formatted="false">प्लेलिस्टबाट प्ले गर्दै</string>+ <string name="context_type_description_album" formatted="false">एल्बमबाट प्ले गर्दै</string>+ <string name="context_type_description_artist" formatted="false">\'कलाकार\' बाट प्ले गर्दै</string>+ <string name="context_type_description_show" formatted="false">पोडकास्टबाट प्ले गरिँदै</string>+ <string name="context_type_description_search" formatted="false">खोजबाट प्ले गर्दै</string>+ <string name="default_notification_channel_name" formatted="false">अहिले प्ले भइरहेको</string>+ <string name="label_bluetooth" formatted="false">ब्लुटुथ</string>+ <string name="mr_user_route_category_name" formatted="false">यन्त्रहरू</string>+ <string name="action_share_label" formatted="false">सेयर गर्नुहोस्</string>+ <string name="action_queue_label" formatted="false">लाइन</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 घण्टा</string>+ <string name="curation_actions_edit_button_title" formatted="false">सम्पादन गर्नुहोस्</string>+ <string name="content_description_pause_button" formatted="false">पज गर्नुहोस्</string>+ <string name="content_description_play_button" formatted="false">प्ले गर्नुहोस्</string>+ <string name="play_mode_item_shuffle_title" formatted="false">सफल गर्नुहोस्</string>+ <string name="np_content_desc_repeat" formatted="false">दोहोर्याउनुहोस्</string>+ <string name="np_content_desc_sleep_timer" formatted="false">स्लिप टाइमर</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">हटाउनुहोस्</string>+ <string name="edit_playlist_items_move_chip" formatted="false">सार्नुहोस्</string>+ <string name="bottom_actions_close" formatted="false">बन्द गर्नुहोस्</string>+ <string name="add_to_queue_action_content_description" formatted="false">लाइनमा राख्नुहोस्</string>+ <string name="curation_button_saved_text" formatted="false">सेभ गरियो</string>+ <string name="np_content_desc_prev" formatted="false">अघिल्लो</string>+ <string name="np_content_desc_next" formatted="false">अर्को</string>+ <string name="accessibility_navigate_back" formatted="false">पछाडि</string>+ <string name="monthly_listeners_text" formatted="false">%1$s जना मासिक श्रोता</string>+ <string name="profile_bio_show_less" formatted="false">कम देखाउनुहोस्</string>+ <string name="audiobook_series_see_more_button" formatted="false">थप देखाउनुहोस्</string>+ <string name="popular_releases_section_title" formatted="false">लोकप्रिय रिलिजहरू</string>+ <string name="creator_biography_section_title" formatted="false">बारेमा</string>+ <string name="fans_also_like_section_title" formatted="false">फ्यानहरूलाई यो पनि मन पर्छ</string>+ <string name="appears_on_section_title" formatted="false">देखिने ठाउँ</string>+ <string name="composer_section_button_show_all" formatted="false">सबै देखाउनुहोस्</string>+ <string name="releases_title" formatted="false">रिलिजहरू</string>+ <string name="artist_releases_albums" formatted="false">एल्बमहरू</string>+ <string name="artist_releases_singles" formatted="false">एकल र EP हरू</string>+ <string name="latest_release_title" formatted="false">ताजा रिलिजहरू</string>+ <string name="artist_subtitle" formatted="false">कलाकार</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">हालैका खोजहरू</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">मेटाउनुहोस्</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">पोडकास्टहरू</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">भागहरू</string>+ <string name="assisted_curation_search_song" formatted="false">गीत</string>+ <string name="album" formatted="false">एल्बम</string>+ <string name="album_type_podcast" formatted="false">पोडकास्ट</string>+ <string name="recently_played_user_profile" formatted="false">प्रोफाइल</string>+ <string name="connect_device_menu_logout" formatted="false">लग आउट गर्नुहोस्</string>+ <string name="library_search_text_hint" formatted="false">\"तपाईंको लाइब्रेरी\" मा खोज्नुहोस्</string>+ <string name="account_title" formatted="false">खाता</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">फलो गरिएका कलाकारहरू</string>+ <string name="settings_item_crossfade_title" formatted="false">क्रसफेड</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d सेकेन्ड</string>+ <string name="local_files_title" formatted="false">लोकल फाइलहरू</string>+ <string name="local_files_empty_section_title" formatted="false">आफ्नो लाइब्रेरीमा आफ्नै अडियो फाइलहरू हाल्नुहोस्</string>+ <string name="local_files_empty_section_subtitle" formatted="false">तपाईंसँग Spotify मा नभएको गीत वा व्यक्तिगत पोडकास्ट छ?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">तपाईंका अडियो फाइलहरू यहाँ देखिने छन्</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">प्रयोग गर्ने अनुमति दिनुहोस्</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">सेटिङमा जानुहोस्</string>+ <string name="context_menu_download" formatted="false">डाउनलोड गर्नुहोस्</string>+ <string name="context_menu_undownload" formatted="false">डाउनलोड गरिएको सामग्री हटाउनुहोस्</string>+ <string name="collection_downloaded" formatted="false">डाउनलोड गरिएका सामग्री</string>+ <string name="download_badge_downloaded_content_description" formatted="false">डाउनलोड गरियो</string>+ <string name="download_badge_downloading_content_description" formatted="false">डाउनलोड गर्दै</string>+ <string name="download_badge_error_content_description" formatted="false">डाउनलोड भएन</string>+ <string name="download_notification_downloading" formatted="false">डाउनलोड गर्दै…</string>+ <string name="toast_undownload" formatted="false">डाउनलोड हटाइयो।</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">\'डाउनलोडहरू\' बाट हटाउने हो?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">तपाईं यो सामग्री अफलाइन प्ले गर्न सक्नुहुने छैन।</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">हटाउनुहोस्</string>+ <string name="settings_item_remove_downloads_title" formatted="false">डाउनलोड गरिएका सबै गीत हटाउनुहोस्</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">डाउनलोड गरिएका सबै संगीत हटाउने हो?</string>+ <string name="album_type_album" formatted="false">एल्बम</string>+ <string name="album_type_single" formatted="false">सिङ्गल</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">संग्रह</string>+ <string name="assisted_curation_search_playlist" formatted="false">प्लेलिस्ट</string>+ <string name="assisted_curation_search_filter_top" formatted="false">शीर्ष</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">गीतहरू</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">कलाकारहरू</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">एल्बमहरू</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">प्लेलिस्टहरू</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">फिल्टर हटाउनुहोस्</string>+ <string name="ad_category_title_music" formatted="false">सङ्गीत</string>+ <string name="made_for_you_hub_title" formatted="false">तपाईंका लागि बनाइएको</string>+ <string name="settings_item_app_language_title" formatted="false">एपको भाषा</string>+ <string name="create_menu_item_folder_title" formatted="false">फोल्डर</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">नयाँ फोल्डर</string>+ <string name="context_menu_rename_folder" formatted="false">फोल्डरको नाम बदल्नुहोस्</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">फोल्डरको नाम</string>+ <string name="create_playlist_content_description" formatted="false">प्लेलिस्ट सिर्जना गर्नुहोस्</string>+ <string name="actions_picker_delete" formatted="false">मेटाउनुहोस्</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">यसअनुसार क्रमबद्ध गर्नुहोस्</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">वर्णानुक्रम</string>+ <string name="your_library_sort_order_creator" formatted="false">सर्जक</string>+ <string name="your_library_sort_order_custom" formatted="false">आफ्नो इच्छाअनुसार क्रमबद्ध गर्नुहोस्</string>+ <string name="settings_item_version_title" formatted="false">संस्करण</string>+ <string name="context_menu_go_to_song_radio" formatted="false">गीतको रेडियोमा जानुहोस्</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">मनपरेका गीतहरूमा फेला पार्नुहोस्</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">प्लेलिस्टमा फेला पार्नुहोस्</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\" फेला पार्न सकिएन</string>+</resources>diff --git a/base/app/src/main/res/values-night/themes.xml b/base/app/src/main/res/values-night/themes.xmlnew file mode 100644index 00000000..73d86fdf--- /dev/null+++ b/base/app/src/main/res/values-night/themes.xml@@ -0,0 +1,36 @@+<resources xmlns:tools="http://schemas.android.com/tools">+ <!-- Base application theme. Material 3 + Spotify (Night) -->+ <style name="Theme.Myspoti" parent="Theme.Material3.DayNight.NoActionBar">+ <!-- Material 3 Primary -->+ <item name="colorPrimary">@color/primary</item>+ <item name="colorOnPrimary">@color/on_primary</item>+ <item name="colorPrimaryContainer">@color/primary_container</item>+ <item name="colorOnPrimaryContainer">@color/on_primary_container</item>++ <!-- Material 3 Surface -->+ <item name="colorSurface">@color/surface</item>+ <item name="colorOnSurface">@color/on_surface</item>+ <item name="colorSurfaceVariant">@color/surface_variant</item>+ <item name="colorOnSurfaceVariant">@color/on_surface_variant</item>++ <!-- Material 3 Background -->+ <item name="android:colorBackground">@color/background</item>+ <item name="colorOnBackground">@color/on_background</item>++ <!-- Status bar -->+ <item name="android:statusBarColor">@color/status_bar</item>+ <item name="android:navigationBarColor">@color/status_bar</item>++ <!-- Ensure edge-to-edge works -->+ <item name="android:windowTranslucentStatus">false</item>+ <item name="android:windowTranslucentNavigation">false</item>++ <!-- Launch screen: same background as the app (no black-to-grey flash). -->+ <item name="android:windowBackground">@color/app_background</item>+ <item name="android:windowSplashScreenBackground" tools:targetApi="31">@color/app_background</item>+ <item name="android:windowSplashScreenAnimatedIcon" tools:targetApi="31">@drawable/splash_icon</item>++ <!-- Light status bar icons (white icons on dark background) -->+ <item name="android:windowLightStatusBar">false</item>+ </style>+</resources>\ No newline at end of filediff --git a/base/app/src/main/res/values-nl/spotify_plurals.xml b/base/app/src/main/res/values-nl/spotify_plurals.xmlnew file mode 100644index 00000000..75889096--- /dev/null+++ b/base/app/src/main/res/values-nl/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d nummer</item>+ <item quantity="other">%1$d nummers</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d keer opgeslagen</item>+ <item quantity="other">%1$,d keer opgeslagen</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="other">%1$s playlists</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s nummer</item>+ <item quantity="other">%1$s nummers</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-nl/spotify_strings.xml b/base/app/src/main/res/values-nl/spotify_strings.xmlnew file mode 100644index 00000000..a1da475b--- /dev/null+++ b/base/app/src/main/res/values-nl/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Toevoegen aan je gelikete nummers</string>+ <string name="collection_liked_songs_title" formatted="false">Gelikete nummers</string>+ <string name="context_menu_add_to_playlist" formatted="false">Toevoegen aan playlist</string>+ <string name="context_menu_play_next" formatted="false">Als volgende afspelen</string>+ <string name="context_menu_add_to_queue" formatted="false">In wachtrij zetten</string>+ <string name="context_menu_go_to_queue" formatted="false">Naar wachtrij</string>+ <string name="context_menu_browse_album" formatted="false">Naar album gaan</string>+ <string name="context_menu_browse_artist" formatted="false">Naar artiest gaan</string>+ <string name="context_menu_share" formatted="false">Delen</string>+ <string name="context_menu_sleep_timer" formatted="false">Timer voor slaapstand</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Timer uitschakelen</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Einde van het nummer</string>+ <string name="snackbar_added_to_queue" formatted="false">Toegevoegd aan wachtrij</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Toegevoegd aan Gelikete nummers.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Verwijderd uit Gelikete nummers.</string>+ <string name="content_description_context_menu" formatted="false">Meer opties</string>+ <string name="close_button_content_description" formatted="false">Sluiten</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Opgeslagen in</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nieuwe playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Annuleren</string>+ <string name="create_playlist_create_button" formatted="false">Maken</string>+ <string name="lyrics_card_title" formatted="false">Songtekst</string>+ <string name="lyrics_card_title_preview" formatted="false">Voorbeeld van songtekst</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Songtekst weergeven</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Songtekst op volledig scherm openen</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Songteksten delen</string>+ <string name="lyrics_credential_note" formatted="false">Songtekst geleverd door %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Delen</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Vertalen</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Songtekst te sluiten</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Vertaal songtekst</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Te stoppen met het vertalen van songteksten</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Hier kennen we de songtekst niet van.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Deze songtekst loopt nog niet synchroon.</string>+ <string name="av_switch_to_video" formatted="false">Overschakelen naar video</string>+ <string name="av_switch_to_audio" formatted="false">Overschakelen naar audio</string>+ <string name="av_content_desc" formatted="false">Audio of juist video aanzetten</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Home</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Zoeken</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Bibliotheek</string>+ <string name="search_header_field_hint" formatted="false">Waar wil je naar luisteren?</string>+ <string name="filter_chip_all_label" formatted="false">Alles</string>+ <string name="recents_content_filter_music" formatted="false">Muziek</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasts</string>+ <string name="audiobooks_title" formatted="false">Luisterboeken</string>+ <string name="artist_popular_tracks" formatted="false">Populair</string>+ <string name="curation_button_follow_state_text" formatted="false">Volgen</string>+ <string name="curation_button_following_state_text" formatted="false">Volgend</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artiest</string>+ <string name="connect_phone_is_self" formatted="false">Deze telefoon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Korte, herhalende beelden wanneer een nummer wordt afgespeeld.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Niet nu</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Bijwerken</string>+ <string name="context_type_description_play_queue" formatted="false">Uit afspeelwachtrij afspelen</string>+ <string name="context_type_description_collection_your_library" formatted="false">Afspelen uit Bibliotheek</string>+ <string name="context_type_description_playlist" formatted="false">Afspelen vanuit afspeellijst</string>+ <string name="context_type_description_album" formatted="false">Afspelen van album</string>+ <string name="context_type_description_artist" formatted="false">Artiest wordt afgespeeld</string>+ <string name="context_type_description_show" formatted="false">Afspelen uit podcast</string>+ <string name="context_type_description_search" formatted="false">Afspelen vanuit zoeken</string>+ <string name="default_notification_channel_name" formatted="false">Wordt nu afgespeeld</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Apparaten</string>+ <string name="action_share_label" formatted="false">Delen</string>+ <string name="action_queue_label" formatted="false">Wachtrij</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 uur</string>+ <string name="curation_actions_edit_button_title" formatted="false">Bewerken</string>+ <string name="content_description_pause_button" formatted="false">Pauzeren</string>+ <string name="content_description_play_button" formatted="false">Afspelen</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Shuffle</string>+ <string name="np_content_desc_repeat" formatted="false">Herhalen</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Timer voor slaapstand</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Verwijderen</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Verplaatsen</string>+ <string name="bottom_actions_close" formatted="false">Sluiten</string>+ <string name="add_to_queue_action_content_description" formatted="false">Toevoegen aan wachtrij</string>+ <string name="curation_button_saved_text" formatted="false">Opgeslagen</string>+ <string name="np_content_desc_prev" formatted="false">Vorige</string>+ <string name="np_content_desc_next" formatted="false">Volgende</string>+ <string name="accessibility_navigate_back" formatted="false">Terug</string>+ <string name="monthly_listeners_text" formatted="false">%1$s luisteraars per maand</string>+ <string name="profile_bio_show_less" formatted="false">Minder weergeven</string>+ <string name="audiobook_series_see_more_button" formatted="false">Meer weergeven</string>+ <string name="popular_releases_section_title" formatted="false">Populaire releases</string>+ <string name="creator_biography_section_title" formatted="false">Meer informatie</string>+ <string name="fans_also_like_section_title" formatted="false">Fans houden ook van</string>+ <string name="appears_on_section_title" formatted="false">Is te horen op</string>+ <string name="composer_section_button_show_all" formatted="false">Alles weergeven</string>+ <string name="releases_title" formatted="false">Releases</string>+ <string name="artist_releases_albums" formatted="false">Albums</string>+ <string name="artist_releases_singles" formatted="false">Singles en EP\'s</string>+ <string name="latest_release_title" formatted="false">Nieuwste release</string>+ <string name="artist_subtitle" formatted="false">Artiest</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Recente zoekopdrachten</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Wissen</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasts</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Afleveringen</string>+ <string name="assisted_curation_search_song" formatted="false">Nummer</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profiel</string>+ <string name="connect_device_menu_logout" formatted="false">UITLOGGEN</string>+ <string name="library_search_text_hint" formatted="false">Bibliotheek doorzoeken</string>+ <string name="account_title" formatted="false">Account</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Gevolgde artiesten</string>+ <string name="settings_item_crossfade_title" formatted="false">Crossfade</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s.</string>+ <string name="local_files_title" formatted="false">Lokale bestanden</string>+ <string name="local_files_empty_section_title" formatted="false">Voeg je eigen audiobestanden toe aan je bibliotheek</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Heb je een nummer of persoonlijke podcast die niet op Spotify staat?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Je audiobestanden worden hier weergegeven</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Toegang geven</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Ga naar Instellingen</string>+ <string name="context_menu_download" formatted="false">Downloaden</string>+ <string name="context_menu_undownload" formatted="false">Download verwijderen</string>+ <string name="collection_downloaded" formatted="false">Gedownload</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Gedownload</string>+ <string name="download_badge_downloading_content_description" formatted="false">Downloaden</string>+ <string name="download_badge_error_content_description" formatted="false">Downloaden mislukt</string>+ <string name="download_notification_downloading" formatted="false">Downloaden…</string>+ <string name="toast_undownload" formatted="false">Download verwijderd.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Verwijderen uit downloads?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Je kunt dit niet afspelen in de offline modus.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Verwijderen</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Alle downloads verwijderen</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Alle downloads verwijderen?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Compilatie</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Populairst</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Nummers</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artiesten</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albums</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlists</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Filter wissen</string>+ <string name="ad_category_title_music" formatted="false">Muziek</string>+ <string name="made_for_you_hub_title" formatted="false">Speciaal voor jou.</string>+ <string name="settings_item_app_language_title" formatted="false">Taal van de app</string>+ <string name="create_menu_item_folder_title" formatted="false">Map</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nieuwe map</string>+ <string name="context_menu_rename_folder" formatted="false">Mapnaam wijzigen</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Mapnaam</string>+ <string name="create_playlist_content_description" formatted="false">Playlist maken</string>+ <string name="actions_picker_delete" formatted="false">Verwijderen</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sorteren op</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alfabetisch</string>+ <string name="your_library_sort_order_creator" formatted="false">Maker</string>+ <string name="your_library_sort_order_custom" formatted="false">Aangepaste volgorde</string>+ <string name="settings_item_version_title" formatted="false">Versie</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Ga naar nummerradio</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Zoeken in gelikete nummers</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Zoeken in playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Kan \'%1$s\' niet vinden</string>+</resources>diff --git a/base/app/src/main/res/values-or/spotify_plurals.xml b/base/app/src/main/res/values-or/spotify_plurals.xmlnew file mode 100644index 00000000..6f9b615c--- /dev/null+++ b/base/app/src/main/res/values-or/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$dଟି ଗୀତ</item>+ <item quantity="other">%1$dଟି ଗୀତ</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,dଟି ସେଭ୍</item>+ <item quantity="other">%1$,dଟି ସେଭ୍</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s ଟି ପ୍ଲେଲିଷ୍ଟ</item>+ <item quantity="other">%1$s ଟି ପ୍ଲେଲିଷ୍ଟ</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$sଟି ଗୀତ</item>+ <item quantity="other">%1$sଟି ଗୀତ</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-or/spotify_strings.xml b/base/app/src/main/res/values-or/spotify_strings.xmlnew file mode 100644index 00000000..e4bd257b--- /dev/null+++ b/base/app/src/main/res/values-or/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">ଲାଇକ୍ କରାଯାଇଥିବା ଗୀତରେ ଯୋଗ କରନ୍ତୁ</string>+ <string name="collection_liked_songs_title" formatted="false">ପସନ୍ଦର ଗୀତଗୁଡ଼ିକ</string>+ <string name="context_menu_add_to_playlist" formatted="false">ପ୍ଲେଲିଷ୍ଟରେ ଯୋଗ କରନ୍ତୁ</string>+ <string name="context_menu_play_next" formatted="false">ପରବର୍ତ୍ତୀ ଚାଳନ କରନ୍ତୁ</string>+ <string name="context_menu_add_to_queue" formatted="false">ଧାଡ଼ିରେ ଯୋଡ଼ନ୍ତୁ</string>+ <string name="context_menu_go_to_queue" formatted="false">ଧାଡ଼ିକୁ ଯାଆନ୍ତୁ</string>+ <string name="context_menu_browse_album" formatted="false">ଆଲବମକୁ ଯାଆନ୍ତୁ</string>+ <string name="context_menu_browse_artist" formatted="false">କଳାକାରକୁ ଯାଆନ୍ତୁ</string>+ <string name="context_menu_share" formatted="false">ସେୟାର୍ କରନ୍ତୁ</string>+ <string name="context_menu_sleep_timer" formatted="false">ସ୍ଲିପ୍ ଟାଇମର୍</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">ଟାଇମର୍ ଅଫ୍ କରନ୍ତୁ</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">ଟ୍ରାକର ଶେଷ</string>+ <string name="snackbar_added_to_queue" formatted="false">କ୍ୟୁରେ ଯୋଗ କରାଯାଇଛି</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">ଲାଇକ୍ ହୋଇଥିବା ଗୀତରେ ଯୋଡ଼ା ଯାଇଛି।</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">ଲାଇକ୍ ହୋଇଥିବା ଗୀତରୁ କାଢ଼ି ଦିଆଯାଇଛି।</string>+ <string name="content_description_context_menu" formatted="false">ଅଧିକ ବିକଳ୍ପ</string>+ <string name="close_button_content_description" formatted="false">ବନ୍ଦ କରନ୍ତୁ</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">ଏଥିରେ ସେଭ୍ କରାଯାଇଛି</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">ନୂଆ ପ୍ଲେଲିଷ୍ଟ</string>+ <string name="add_to_playlist_button_cancel" formatted="false">ବାତିଲ୍ କରନ୍ତୁ</string>+ <string name="create_playlist_create_button" formatted="false">ତିଆରି କରନ୍ତୁ</string>+ <string name="lyrics_card_title" formatted="false">ଲିରିକ୍ସ</string>+ <string name="lyrics_card_title_preview" formatted="false">ଲିରିକ୍ସର ପ୍ରିଭ୍ୟୁ</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">ଲିରିକ୍ସ ଦେଖାନ୍ତୁ</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">ପୂର୍ଣ୍ଣ ସ୍କ୍ରିନ୍ ଲିରିକ୍ସ ଖୋଲନ୍ତୁ</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">ଲିରିକ୍ ଅଂଶୀଦାର କରନ୍ତୁ</string>+ <string name="lyrics_credential_note" formatted="false">%1$s ଦ୍ୱାରା ପ୍ରଦାନ କରାଯାଇଥିବା ଲିରିକ୍ସ</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">ସେୟାର୍</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">ଅନୁବାଦ କର</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">ଲିରିକ୍ସ ବନ୍ଦ କରନ୍ତୁ</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">ଲିରିକ୍ସ ଅନୁବାଦ କର</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">ଲିରିକ୍ସ ଅନୁବାଦ କରିବା ସ୍ଥଗିତ କରନ୍ତୁ</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">ହଁ। ଆମେ ଏହାର ଲିରିକ୍ସ ଜାଣିନାହୁଁ।</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">ଏହି ଲିରିକ୍ସ୍ ଏପର୍ଯ୍ୟନ୍ତ ସମୟ-ସିଙ୍କ୍ ହୋଇନାହିଁ।</string>+ <string name="av_switch_to_video" formatted="false">ଭିଡିଓକୁ ସ୍ୱିଚ୍ କରନ୍ତୁ</string>+ <string name="av_switch_to_audio" formatted="false">ଅଡିଓକୁ ସ୍ୱିଚ୍ କରନ୍ତୁ</string>+ <string name="av_content_desc" formatted="false">ଅଡିଓ ଏବଂ ଭିଡିଓ ମଧ୍ୟରେ ଟୋଗଲ୍ କରନ୍ତୁ</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">ମୂଳପୃଷ୍ଠା</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">ସର୍ଚ୍ଚ କରନ୍ତୁ</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">ଆପଣଙ୍କ ଲାଇବ୍ରେରୀ</string>+ <string name="search_header_field_hint" formatted="false">ଆପଣ କଣ ଶୁଣିବାକୁ ଚାହାଁନ୍ତି?</string>+ <string name="filter_chip_all_label" formatted="false">ସମସ୍ତ</string>+ <string name="recents_content_filter_music" formatted="false">ମ୍ୟୁଜିକ୍</string>+ <string name="ad_category_title_podcasts" formatted="false">ପୋଡକାଷ୍ଟଗୁଡ଼ିକ</string>+ <string name="audiobooks_title" formatted="false">ଅଡିଓବୁକ୍ଗୁଡ଼ିକ</string>+ <string name="artist_popular_tracks" formatted="false">ଲୋକପ୍ରିୟ</string>+ <string name="curation_button_follow_state_text" formatted="false">ଅନୁସରଣ କରନ୍ତୁ</string>+ <string name="curation_button_following_state_text" formatted="false">ଅନୁସରଣ କରୁଛନ୍ତି</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">କଳାକାର</string>+ <string name="connect_phone_is_self" formatted="false">ଏହି ଫୋନ୍</string>+ <string name="settings_item_canvas_title" formatted="false">କାନଭାସ୍</string>+ <string name="video_settings_canvas_subtitle" formatted="false">ଏକ ଗୀତ ଚାଳନ ବେଳେ ଛୋଟ, ଲୁପିଂ ଭିଜୁଆଲ୍ ।</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">ବର୍ତ୍ତମାନ ନୁହେଁ</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">ଅପଡେଟ୍ କରନ୍ତୁ</string>+ <string name="context_type_description_play_queue" formatted="false">ଚାଳନ ଧାଡ଼ିରୁ ଚାଲୁଛି</string>+ <string name="context_type_description_collection_your_library" formatted="false">ଆପଣଙ୍କର ଲାଇବ୍ରେରୀରୁ ଚଲେଇବା</string>+ <string name="context_type_description_playlist" formatted="false">ପ୍ଲେଲିଷ୍ଟରୁ ଚଲେଇବା</string>+ <string name="context_type_description_album" formatted="false">ଆଲବମରୁ ଖେଳିବା</string>+ <string name="context_type_description_artist" formatted="false">କଳାକାରଙ୍କ ଠାରୁ ଖେଳିବା</string>+ <string name="context_type_description_show" formatted="false">ପୋଡକାଷ୍ଟରୁ ଚଲାନ୍ତୁ</string>+ <string name="context_type_description_search" formatted="false">ସନ୍ଧାନରୁ ଚଲେଇବା</string>+ <string name="default_notification_channel_name" formatted="false">ବର୍ତ୍ତମାନ ଚାଲୁଛି</string>+ <string name="label_bluetooth" formatted="false">ବ୍ଲୁଟୁଥ୍</string>+ <string name="mr_user_route_category_name" formatted="false">ଡିଭାଇସ୍</string>+ <string name="action_share_label" formatted="false">ସେୟାର୍ କରନ୍ତୁ</string>+ <string name="action_queue_label" formatted="false">ଧାଡ଼ି</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 ଘଣ୍ଟା</string>+ <string name="curation_actions_edit_button_title" formatted="false">ଏଡିଟ୍ କରନ୍ତୁ</string>+ <string name="content_description_pause_button" formatted="false">ପଜ୍ କରନ୍ତୁ</string>+ <string name="content_description_play_button" formatted="false">ଚଲାନ୍ତୁ</string>+ <string name="play_mode_item_shuffle_title" formatted="false">ସଫଲ୍ କରନ୍ତୁ</string>+ <string name="np_content_desc_repeat" formatted="false">ରିପିଟ୍ କରନ୍ତୁ</string>+ <string name="np_content_desc_sleep_timer" formatted="false">ସ୍ଲିପ୍ ଟାଇମର୍</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">କାଢ଼ି ଦିଅନ୍ତୁ</string>+ <string name="edit_playlist_items_move_chip" formatted="false">ଘୁଞ୍ଚାନ୍ତୁ</string>+ <string name="bottom_actions_close" formatted="false">ବନ୍ଦ କରନ୍ତୁ</string>+ <string name="add_to_queue_action_content_description" formatted="false">କ୍ୟୁରେ ଯୋଗ କରନ୍ତୁ</string>+ <string name="curation_button_saved_text" formatted="false">ସେଭ୍ ହୋଇଛି</string>+ <string name="np_content_desc_prev" formatted="false">ପୂର୍ବବର୍ତ୍ତୀ</string>+ <string name="np_content_desc_next" formatted="false">ପରବର୍ତ୍ତୀ</string>+ <string name="accessibility_navigate_back" formatted="false">ପଛକୁ ଫେରନ୍ତୁ</string>+ <string name="monthly_listeners_text" formatted="false">%1$s ଜଣ ମାସିକ ଶ୍ରୋତା</string>+ <string name="profile_bio_show_less" formatted="false">କମ୍ ଦେଖାନ୍ତୁ</string>+ <string name="audiobook_series_see_more_button" formatted="false">ଅଧିକ ଦେଖାନ୍ତୁ</string>+ <string name="popular_releases_section_title" formatted="false">ଲୋକପ୍ରିୟ ରିଲିଜଗୁଡ଼ିକ</string>+ <string name="creator_biography_section_title" formatted="false">ବିଷୟରେ</string>+ <string name="fans_also_like_section_title" formatted="false">ପ୍ରଶଂସକମାନେ ମଧ୍ୟ ଲାଇକ୍ କରନ୍ତି</string>+ <string name="appears_on_section_title" formatted="false">ଏଥିରେ ଦେଖାଯାଏ</string>+ <string name="composer_section_button_show_all" formatted="false">ସବୁ ଦେଖାନ୍ତୁ</string>+ <string name="releases_title" formatted="false">ରିଲିଜଗୁଡ଼ିକ</string>+ <string name="artist_releases_albums" formatted="false">ଆଲବମ୍ ଗୁଡ଼ିକ</string>+ <string name="artist_releases_singles" formatted="false">ଏକକ ଏବଂ EP</string>+ <string name="latest_release_title" formatted="false">ନବୀନତମ ରିଲିଜ୍</string>+ <string name="artist_subtitle" formatted="false">କଳାକାର</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">ବର୍ତ୍ତମାନର ସର୍ଚ୍ଚଗୁଡ଼ିକ</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">ଖାଲି କରନ୍ତୁ</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">ପୋଡକାଷ୍ଟଗୁଡ଼ିକ</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">ଏପିସୋଡଗୁଡ଼ିକ</string>+ <string name="assisted_curation_search_song" formatted="false">ଗୀତ</string>+ <string name="album" formatted="false">ଆଲବମ୍</string>+ <string name="album_type_podcast" formatted="false">ପୋଡକାଷ୍ଟ</string>+ <string name="recently_played_user_profile" formatted="false">ପ୍ରୋଫାଇଲ୍</string>+ <string name="connect_device_menu_logout" formatted="false">ଲଗ୍ ଆଉଟ୍ କରନ୍ତୁ</string>+ <string name="library_search_text_hint" formatted="false">ଆପଣଙ୍କ ଲାଇବ୍ରେରୀ ସନ୍ଧାନ କରନ୍ତୁ</string>+ <string name="account_title" formatted="false">ଆକାଉଣ୍ଟ</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">ଅନୁସରଣ କରାଯାଇଥିବା କଳାକାର</string>+ <string name="settings_item_crossfade_title" formatted="false">କ୍ରସଫେଡ୍</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d ସେ</string>+ <string name="local_files_title" formatted="false">ଲୋକାଲ୍ ଫାଇଲ୍</string>+ <string name="local_files_empty_section_title" formatted="false">ଆପଣଙ୍କ ଲାଇବ୍ରେରୀରେ ଆପଣଙ୍କର ନିଜର ଅଡିଓ ଫାଇଲ୍ ଯୋଗ କରନ୍ତୁ</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Spotifyରେ ନଥିବା ଏକ ଗୀତ କିମ୍ବା ବ୍ୟକ୍ତିଗତ ପୋଡକାଷ୍ଟ ପାଇଛନ୍ତି କି?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">ଆପଣଙ୍କ ଅଡିଓ ଫାଇଲଗୁଡ଼ିକ ଏଠାରେ ଦେଖାଯିବ</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">ଆକ୍ସେସ୍ ଦିଅନ୍ତୁ</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">ସେଟିଂସକୁ ଯାଆନ୍ତୁ</string>+ <string name="context_menu_download" formatted="false">ଡାଉନଲୋଡ୍ କରନ୍ତୁ</string>+ <string name="context_menu_undownload" formatted="false">ଡାଉନଲୋଡ୍ କାଢ଼ି ଦିଅନ୍ତୁ</string>+ <string name="collection_downloaded" formatted="false">ଡାଉନଲୋଡ୍ ହୋଇଛି</string>+ <string name="download_badge_downloaded_content_description" formatted="false">ଡାଉନଲୋଡ୍ ହୋଇଛି</string>+ <string name="download_badge_downloading_content_description" formatted="false">ଡାଉନଲୋଡ୍ କରୁଛି</string>+ <string name="download_badge_error_content_description" formatted="false">ଡାଉନଲୋଡ୍ ବିଫଳ ହେଲା</string>+ <string name="download_notification_downloading" formatted="false">ଡାଉନଲୋଡ୍ କରୁଛି…</string>+ <string name="toast_undownload" formatted="false">ଡାଉନଲୋଡ୍ ଅପସାରିତ କରାଯାଇଛି।</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">ଡାଉନଲୋଡରୁ କାଢ଼ିବେ କି?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">ଏହାକୁ ଅଫଲାଇନ୍ ଚଲାଇବାକୁ ଆପଣ ସମର୍ଥ ହେବେ ନାହିଁ।</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">କାଢ଼ି ଦିଅନ୍ତୁ</string>+ <string name="settings_item_remove_downloads_title" formatted="false">ସମସ୍ତ ଡାଉନଲୋଡକୁ ଅପସାରଣ କରନ୍ତୁ</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">ସମସ୍ତ ଡାଉନ୍ଲୋଡକୁ ଅପସାରଣ କରିବେ କି?</string>+ <string name="album_type_album" formatted="false">ଆଲବମ୍</string>+ <string name="album_type_single" formatted="false">ଏକକ</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">ସଂକଳନ</string>+ <string name="assisted_curation_search_playlist" formatted="false">ପ୍ଲେଲିଷ୍ଟ</string>+ <string name="assisted_curation_search_filter_top" formatted="false">ଶୀର୍ଷ</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">ଗୀତଗୁଡ଼ିକ</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">କଳାକାରମାନେ</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">ଆଲବମଗୁଡ଼ିକ</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">ପ୍ଲେଲିଷ୍ଟଗୁଡ଼ିକ</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">ଫିଲ୍ଟର୍ ଖାଲି କରନ୍ତୁ</string>+ <string name="ad_category_title_music" formatted="false">ମ୍ୟୁଜିକ୍</string>+ <string name="made_for_you_hub_title" formatted="false">ଆପଣଙ୍କ ପାଇଁ ପ୍ରସ୍ତୁତ</string>+ <string name="settings_item_app_language_title" formatted="false">ଆପର ଭାଷା</string>+ <string name="create_menu_item_folder_title" formatted="false">ଫୋଲ୍ଡର୍</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">ନୂତନ ଫୋଲ୍ଡର୍</string>+ <string name="context_menu_rename_folder" formatted="false">ଫୋଲ୍ଡର୍ ପୁନଃନାମ କରନ୍ତୁ</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">ଫୋଲ୍ଡର ନାମ</string>+ <string name="create_playlist_content_description" formatted="false">ପ୍ଲେଲିଷ୍ଟ ତିଆରି କରନ୍ତୁ</string>+ <string name="actions_picker_delete" formatted="false">ଡିଲିଟ୍ କରନ୍ତୁ</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">ଦ୍ୱାରା ସର୍ଟ କରନ୍ତୁ</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">ବର୍ଣ୍ଣାନୁକ୍ରମିକ</string>+ <string name="your_library_sort_order_creator" formatted="false">କ୍ରିଏଟର୍</string>+ <string name="your_library_sort_order_custom" formatted="false">ଅର୍ଡର କଷ୍ଟମ୍ କରନ୍ତୁ</string>+ <string name="settings_item_version_title" formatted="false">ସଂସ୍କରଣ</string>+ <string name="context_menu_go_to_song_radio" formatted="false">ଗୀତ ରେଡିଓକୁ ଯାଆନ୍ତୁ</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">ପସନ୍ଦର ଗୀତଗୁଡ଼ିକରେ ଖୋଜନ୍ତୁ</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">ପ୍ଲେଲିଷ୍ଟରେ ପାଆନ୍ତୁ</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\" ମିଳିଲା ନାହିଁ</string>+</resources>diff --git a/base/app/src/main/res/values-pa-rIN/spotify_plurals.xml b/base/app/src/main/res/values-pa-rIN/spotify_plurals.xmlnew file mode 100644index 00000000..ac39c783--- /dev/null+++ b/base/app/src/main/res/values-pa-rIN/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d ਗਾਣਾ</item>+ <item quantity="other">%1$d ਗਾਣੇ</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d ਵਾਰ ਸੁਰੱਖਿਅਤ ਕੀਤਾ</item>+ <item quantity="other">%1$,d ਵਾਰ ਸੁਰੱਖਿਅਤ ਕੀਤਾ</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s ਪਲੇਲਿਸਟ</item>+ <item quantity="other">%1$s ਪਲੇਲਿਸਟਾਂ</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s ਗਾਣਾ</item>+ <item quantity="other">%1$s ਗਾਣੇ</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-pa-rIN/spotify_strings.xml b/base/app/src/main/res/values-pa-rIN/spotify_strings.xmlnew file mode 100644index 00000000..b7d59cdd--- /dev/null+++ b/base/app/src/main/res/values-pa-rIN/spotify_strings.xml@@ -0,0 +1,159 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">ਪਸੰਦ ਕੀਤੇ ਗਾਣਿਆਂ ਵਿੱਚ ਸ਼ਾਮਲ ਕਰੋ</string>+ <string name="collection_liked_songs_title" formatted="false">ਪਸੰਦ ਕੀਤੇ ਗਾਣੇ</string>+ <string name="context_menu_add_to_playlist" formatted="false">ਪਲੇਲਿਸਟ ਵਿੱਚ ਸ਼ਾਮਲ ਕਰੋ</string>+ <string name="context_menu_play_next" formatted="false">ਅਗਲਾ ਚਲਾਓ</string>+ <string name="context_menu_add_to_queue" formatted="false">ਕਤਾਰ ਵਿੱਚ ਸ਼ਾਮਲ ਕਰੋ</string>+ <string name="context_menu_go_to_queue" formatted="false">ਕਤਾਰ \'ਤੇ ਜਾਓ</string>+ <string name="context_menu_browse_album" formatted="false">ਐਲਬਮ \'ਤੇ ਜਾਓ</string>+ <string name="context_menu_browse_artist" formatted="false">ਕਲਾਕਾਰ \'ਤੇ ਜਾਓ</string>+ <string name="context_menu_share" formatted="false">ਸਾਂਝਾ ਕਰੋ</string>+ <string name="context_menu_sleep_timer" formatted="false">ਸਲੀਪ ਟਾਈਮਰ</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">ਟਾਈਮਰ ਨੂੰ ਬੰਦ ਕਰੋ</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">ਟਰੈਕ ਦਾ ਅੰਤ</string>+ <string name="snackbar_added_to_queue" formatted="false">ਕਤਾਰ ਵਿੱਚ ਸ਼ਾਮਲ ਕੀਤਾ ਗਿਆ</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">ਪਸੰਦ ਕੀਤੇ ਗਾਣਿਆਂ ਵਿੱਚ ਸ਼ਾਮਲ ਕੀਤਾ ਗਿਆ।</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">ਪਸੰਦ ਕੀਤੇ ਗਾਣਿਆਂ ਵਿੱਚੋਂ ਹਟਾ ਦਿੱਤਾ ਗਿਆ।</string>+ <string name="content_description_context_menu" formatted="false">ਹੋਰ ਵਿਕਲਪ</string>+ <string name="close_button_content_description" formatted="false">ਬੰਦ ਕਰੋ</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">ਇਸ ਵਿੱਚ ਸੁਰੱਖਿਅਤ ਕੀਤਾ ਹੋਇਆ ਹੈ</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">ਨਵੀਂ ਪਲੇਲਿਸਟ</string>+ <string name="add_to_playlist_button_cancel" formatted="false">ਰੱਦ ਕਰੋ</string>+ <string name="create_playlist_create_button" formatted="false">ਬਣਾਓ</string>+ <string name="lyrics_card_title" formatted="false">ਗਾਣੇ ਦੇ ਬੋਲ</string>+ <string name="lyrics_card_title_preview" formatted="false">ਗਾਣੇ ਦੇ ਬੋਲਾਂ ਦੀ ਪੂਰਵ-ਝਲਕ</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">ਗਾਣੇ ਦੇ ਬੋਲ ਦਿਖਾਓ</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">ਪੂਰੀ ਸਕ੍ਰੀਨ \'ਤੇ ਗਾਣੇ ਦੇ ਬੋਲ ਖੋਲ੍ਹੋ</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">ਬੋਲ ਸਾਂਝੇ ਕਰੋ</string>+ <string name="lyrics_credential_note" formatted="false">ਗਾਣੇ ਦੇ ਬੋਲ %1$s ਨੇ ਪ੍ਰਦਾਨ ਕੀਤੇ ਹਨ</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">ਸਾਂਝਾ ਕਰੋ</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">ਅਨੁਵਾਦ ਕਰੋ</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">ਗਾਣੇ ਦੇ ਬੋਲ ਬੰਦ ਕਰੋ</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">ਗਾਣੇ ਦੇ ਬੋਲਾਂ ਦਾ ਅਨੁਵਾਦ ਕਰੋ</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">ਗਾਣੇ ਦੇ ਬੋਲਾਂ ਦਾ ਅਨੁਵਾਦ ਕਰਨਾ ਬੰਦ ਕਰੋ</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">ਓਹੋ। ਸਾਡੇ ਕੋਲ ਇਸ ਗਾਣੇ ਦੇ ਬੋਲ ਨਹੀਂ ਹਨ।</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">ਗਾਣੇ ਦੇ ਬੋਲ ਹਾਲੇ ਤੱਕ ਸਮੇਂ ਦੇ ਨਾਲ ਸਿੰਕ ਨਹੀਂ ਹੋਏ ਹਨ।</string>+ <string name="av_switch_to_video" formatted="false">ਵੀਡੀਓ \'ਤੇ ਸਵਿੱਚ ਕਰੋ</string>+ <string name="av_switch_to_audio" formatted="false">ਆਡੀਓ \'ਤੇ ਸਵਿੱਚ ਕਰੋ</string>+ <string name="av_content_desc" formatted="false">ਆਡੀਓ ਅਤੇ ਵੀਡੀਓ ਵਿਚਕਾਰ ਟੌਗਲ ਕਰੋ</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">ਹੋਮ</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">ਖੋਜੋ</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">ਤੁਹਾਡੀ ਲਾਇਬ੍ਰੇਰੀ</string>+ <string name="search_header_field_hint" formatted="false">ਤੁਸੀਂ ਕੀ ਸੁਣਨਾ ਚਾਹੁੰਦੇ ਹੋ?</string>+ <string name="filter_chip_all_label" formatted="false">ਸਾਰੇ</string>+ <string name="recents_content_filter_music" formatted="false">ਸੰਗੀਤ</string>+ <string name="ad_category_title_podcasts" formatted="false">ਪੋਡਕਾਸਟ</string>+ <string name="audiobooks_title" formatted="false">ਆਡੀਓਬੁੱਕ</string>+ <string name="artist_popular_tracks" formatted="false">ਪ੍ਰਸਿੱਧ</string>+ <string name="curation_button_follow_state_text" formatted="false">ਫਾਲੋ ਕਰੋ</string>+ <string name="curation_button_following_state_text" formatted="false">ਫਾਲੋ ਕੀਤਾ ਜਾ ਰਿਹਾ ਹੈ</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">ਕਲਾਕਾਰ</string>+ <string name="connect_phone_is_self" formatted="false">ਇਸ ਫ਼ੋਨ \'ਤੇ</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">ਗਾਣਾ ਚੱਲਣ ਦੌਰਾਨ ਛੋਟੇ, ਲੂਪਿੰਗ ਵਿਜ਼ੂਅਲ।</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">ਅਜੇ ਨਹੀਂ</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">ਅੱਪਡੇਟ ਕਰੋ</string>+ <string name="context_type_description_play_queue" formatted="false">ਕਤਾਰ ਚਲਾਓ ਤੋਂ ਚਲਾਇਆ ਜਾ ਰਿਹਾ ਹੈ</string>+ <string name="context_type_description_collection_your_library" formatted="false">ਤੁਹਾਡੀ ਲਾਇਬ੍ਰੇਰੀ ਤੋਂ ਚਲਾਇਆ ਜਾ ਰਿਹਾ ਹੈ</string>+ <string name="context_type_description_playlist" formatted="false">ਪਲੇਲਿਸਟ ਤੋਂ ਚਲਾਇਆ ਜਾ ਰਿਹਾ ਹੈ</string>+ <string name="context_type_description_album" formatted="false">ਐਲਬਮ ਤੋਂ ਚਲਾਇਆ ਜਾ ਰਿਹਾ ਹੈ</string>+ <string name="context_type_description_artist" formatted="false">ਕਲਾਕਾਰ ਤੋਂ ਚਲਾਇਆ ਜਾ ਰਿਹਾ ਹੈ</string>+ <string name="context_type_description_show" formatted="false">ਪੋਡਕਾਸਟ ਤੋਂ ਚਲਾਉਣਾ</string>+ <string name="context_type_description_search" formatted="false">ਖੋਜੋ ਤੋਂ ਚਲਾਇਆ ਜਾ ਰਿਹਾ ਹੈ</string>+ <string name="default_notification_channel_name" formatted="false">Spotify</string>+ <string name="label_bluetooth" formatted="false">ਬਲੂਟੁੱਥ</string>+ <string name="action_share_label" formatted="false">ਸਾਂਝਾ ਕਰੋ</string>+ <string name="action_queue_label" formatted="false">ਕਤਾਰ</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 ਘੰਟਾ</string>+ <string name="curation_actions_edit_button_title" formatted="false">ਸੰਪਾਦਨ ਕਰੋ</string>+ <string name="content_description_pause_button" formatted="false">ਰੋਕੋ</string>+ <string name="content_description_play_button" formatted="false">ਚਲਾਓ</string>+ <string name="play_mode_item_shuffle_title" formatted="false">ਸ਼ਫਲ ਕਰੋ</string>+ <string name="np_content_desc_repeat" formatted="false">ਰਿਪੀਟ ਕਰੋ</string>+ <string name="np_content_desc_sleep_timer" formatted="false">ਸਲੀਪ ਟਾਈਮਰ</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">ਹਟਾਓ</string>+ <string name="edit_playlist_items_move_chip" formatted="false">ਮੂਵ ਕਰੋ</string>+ <string name="bottom_actions_close" formatted="false">ਬੰਦ ਕਰੋ</string>+ <string name="add_to_queue_action_content_description" formatted="false">ਕਤਾਰ ਵਿੱਚ ਸ਼ਾਮਲ ਕਰੋ</string>+ <string name="curation_button_saved_text" formatted="false">ਸੁਰੱਖਿਅਤ ਕੀਤਾ ਗਿਆ</string>+ <string name="np_content_desc_prev" formatted="false">ਪਿਛਲਾ</string>+ <string name="np_content_desc_next" formatted="false">ਅਗਲਾ</string>+ <string name="accessibility_navigate_back" formatted="false">ਪਿੱਛੇ ਜਾਓ</string>+ <string name="monthly_listeners_text" formatted="false">%1$s ਮਹੀਨਾਵਾਰ ਸਰੋਤੇ</string>+ <string name="profile_bio_show_less" formatted="false">ਘੱਟ ਦਿਖਾਓ</string>+ <string name="audiobook_series_see_more_button" formatted="false">ਹੋਰ ਦਿਖਾਓ</string>+ <string name="popular_releases_section_title" formatted="false">ਪ੍ਰਸਿੱਧ ਰਿਲੀਜ਼</string>+ <string name="creator_biography_section_title" formatted="false">ਇਸ ਬਾਰੇ ਜਾਣਕਾਰੀ</string>+ <string name="fans_also_like_section_title" formatted="false">ਫ਼ੈਨਸ ਨੂੰ ਇਹ ਵੀ ਪਸੰਦ ਹੈ</string>+ <string name="appears_on_section_title" formatted="false">ਇਹਨਾਂ ਵਿੱਚ ਦੇਖੇ ਗਏ ਹਨ</string>+ <string name="composer_section_button_show_all" formatted="false">ਸਭ ਦਿਖਾਓ</string>+ <string name="releases_title" formatted="false">ਰਿਲੀਜ਼</string>+ <string name="artist_releases_albums" formatted="false">ਐਲਬਮਾਂ</string>+ <string name="artist_releases_singles" formatted="false">ਇਕਹਿਰੇ ਅਤੇ EPs</string>+ <string name="latest_release_title" formatted="false">ਨਵੀਨਤਮ ਰਿਲੀਜ਼</string>+ <string name="artist_subtitle" formatted="false">ਕਲਾਕਾਰ</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">ਹਾਲ ਹੀ ਦੀਆਂ ਖੋਜਾਂ</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">ਸਾਫ਼ ਕਰੋ</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">ਪੋਡਕਾਸਟ</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">ਐਪੀਸੋਡ</string>+ <string name="assisted_curation_search_song" formatted="false">ਗਾਣਾ</string>+ <string name="album" formatted="false">ਐਲਬਮ</string>+ <string name="album_type_podcast" formatted="false">ਪੋਡਕਾਸਟ</string>+ <string name="recently_played_user_profile" formatted="false">ਪ੍ਰੋਫਾਈਲ</string>+ <string name="connect_device_menu_logout" formatted="false">ਲੌਗ-ਆਉਟ ਕਰੋ</string>+ <string name="library_search_text_hint" formatted="false">\'ਤੁਹਾਡੀ ਲਾਇਬ੍ਰੇਰੀ\' ਖੋਜੋ</string>+ <string name="account_title" formatted="false">ਖਾਤਾ</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">ਕਲਾਕਾਰਾਂ ਨੂੰ ਫਾਲੋ ਕੀਤਾ ਗਿਆ</string>+ <string name="settings_item_crossfade_title" formatted="false">ਕ੍ਰਾਸਫੇਡ</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d ਸਕਿੰਟ</string>+ <string name="local_files_title" formatted="false">ਸਥਾਨਕ ਫਾਈਲਾਂ</string>+ <string name="local_files_empty_section_title" formatted="false">ਆਪਣੀ ਲਾਇਬ੍ਰੇਰੀ ਵਿੱਚ ਆਪਣੀਆਂ ਖੁਦ ਦੀਆਂ ਆਡੀਓ ਫਾਈਲਾਂ ਸ਼ਾਮਲ ਕਰੋ</string>+ <string name="local_files_empty_section_subtitle" formatted="false">ਕੀ ਤੁਹਾਡੇ ਕੋਲ ਕੋਈ ਅਜਿਹਾ ਗਾਣਾ ਜਾਂ ਨਿੱਜੀ ਪੋਡਕਾਸਟ ਹੈ ਜੋ Spotify \'ਤੇ ਮੌਜੂਦ ਨਹੀਂ ਹੈ?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">ਤੁਹਾਡੀਆਂ ਆਡੀਓ ਫਾਈਲਾਂ ਇੱਥੇ ਦਿਖਾਈ ਦੇਣਗੀਆਂ</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">ਪਹੁੰਚ ਦਿਓ</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">ਸੈਟਿੰਗਾਂ \'ਤੇ ਜਾਓ</string>+ <string name="context_menu_download" formatted="false">ਡਾਊਨਲੋਡ ਕਰੋ</string>+ <string name="context_menu_undownload" formatted="false">ਡਾਊਨਲੋਡ ਹਟਾਓ</string>+ <string name="collection_downloaded" formatted="false">ਡਾਊਨਲੋਡ ਕੀਤਾ ਗਿਆ</string>+ <string name="download_badge_downloaded_content_description" formatted="false">ਡਾਊਨਲੋਡ ਕੀਤੇ ਹੋਏ</string>+ <string name="download_badge_downloading_content_description" formatted="false">ਡਾਊਨਲੋਡ ਕੀਤੇ ਜਾ ਰਹੇ ਹਨ</string>+ <string name="download_badge_error_content_description" formatted="false">ਡਾਊਨਲੋਡ ਕਰਨਾ ਅਸਫਲ ਰਿਹਾ</string>+ <string name="download_notification_downloading" formatted="false">ਡਾਊਨਲੋਡ ਕਰ ਰਿਹਾ ਹੈ…</string>+ <string name="toast_undownload" formatted="false">ਡਾਊਨਲੋਡ ਨੂੰ ਹਟਾ ਦਿੱਤਾ ਗਿਆ ਹੈ।</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">ਡਾਊਨਲੋਡਾਂ ਵਿੱਚੋਂ ਹਟਾਉਣਾ ਹੈ?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">ਤੁਸੀਂ ਇਸਨੂੰ ਆਫਲਾਈਨ ਨਹੀਂ ਚਲਾ ਸਕੋਗੇ।</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">ਹਟਾਓ</string>+ <string name="settings_item_remove_downloads_title" formatted="false">ਡਾਊਨਲੋਡ ਕੀਤੀ ਸਾਰੀ ਸਮੱਗਰੀ ਹਟਾਓ</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">ਕੀ ਡਾਊਨਲੋਡ ਕੀਤੀ ਸਾਰੀ ਸਮੱਗਰੀ ਹਟਾਉਣੀ ਹੈ?</string>+ <string name="album_type_album" formatted="false">ਐਲਬਮ</string>+ <string name="album_type_single" formatted="false">ਸਿੰਗਲ</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">ਸੰਗ੍ਰਹਿ</string>+ <string name="assisted_curation_search_playlist" formatted="false">ਪਲੇਲਿਸਟ</string>+ <string name="assisted_curation_search_filter_top" formatted="false">ਸਭ ਤੋਂ ਪ੍ਰਸਿੱਧ</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">ਗਾਣੇ</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">ਕਲਾਕਾਰ</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">ਐਲਬਮਾਂ</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">ਪਲੇਲਿਸਟਾਂ</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">ਫਿਲਟਰ ਹਟਾਓ</string>+ <string name="ad_category_title_music" formatted="false">ਸੰਗੀਤ</string>+ <string name="made_for_you_hub_title" formatted="false">ਤੁਹਾਡੇ ਲਈ ਬਣਾਈ ਪਲੇਲਿਸਟ</string>+ <string name="settings_item_app_language_title" formatted="false">ਐਪ ਦੀ ਭਾਸ਼ਾ</string>+ <string name="create_menu_item_folder_title" formatted="false">ਫੋਲਡਰ</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">ਨਵਾਂ ਫੋਲਡਰ</string>+ <string name="context_menu_rename_folder" formatted="false">ਫੋਲਡਰ ਦਾ ਨਾਮ ਬਦਲੋ</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">ਫੋਲਡਰ ਦਾ ਨਾਮ</string>+ <string name="create_playlist_content_description" formatted="false">ਪਲੇਲਿਸਟ ਬਣਾਓ</string>+ <string name="actions_picker_delete" formatted="false">ਮਿਟਾਓ</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">ਇਸ ਅਨੁਸਾਰ ਛਾਂਟੀ ਕਰੋ</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">ਵਰਣਮਾਲਾ ਅਨੁਸਾਰ</string>+ <string name="your_library_sort_order_creator" formatted="false">ਕ੍ਰਿਏਟਰ</string>+ <string name="your_library_sort_order_custom" formatted="false">ਕਸਟਮ ਕ੍ਰਮ</string>+ <string name="settings_item_version_title" formatted="false">ਵਰਜਨ</string>+ <string name="context_menu_go_to_song_radio" formatted="false">ਗਾਣਿਆਂ ਵਾਲੇ ਰੇਡੀਓ \'ਤੇ ਜਾਓ</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">ਪਸੰਦ ਕੀਤੇ ਗਾਣਿਆਂ ਵਿੱਚ ਲੱਭੋ</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">ਪਲੇਲਿਸਟ ਵਿੱਚ ਲੱਭੋ</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\" ਨੂੰ ਲੱਭ ਨਹੀਂ ਸਕੇ</string>+</resources>diff --git a/base/app/src/main/res/values-pa-rPK/spotify_plurals.xml b/base/app/src/main/res/values-pa-rPK/spotify_plurals.xmlnew file mode 100644index 00000000..b8894016--- /dev/null+++ b/base/app/src/main/res/values-pa-rPK/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d گانا</item>+ <item quantity="other">%1$d گانے</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d محفوظ کیتا</item>+ <item quantity="other">%1$,d محفوظ کیتے</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s پلے لسٹ</item>+ <item quantity="other">%1$s پلے لسٹاں</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s گانا</item>+ <item quantity="other">%1$s گانے</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-pa-rPK/spotify_strings.xml b/base/app/src/main/res/values-pa-rPK/spotify_strings.xmlnew file mode 100644index 00000000..a4234ca0--- /dev/null+++ b/base/app/src/main/res/values-pa-rPK/spotify_strings.xml@@ -0,0 +1,159 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">پسند کیتے گانیاں اچ شامل کرو</string>+ <string name="collection_liked_songs_title" formatted="false">لائیک کیتے گانے</string>+ <string name="context_menu_add_to_playlist" formatted="false">پلے لسٹ وچ شامل کرو</string>+ <string name="context_menu_play_next" formatted="false">اگلا چلاؤ</string>+ <string name="context_menu_add_to_queue" formatted="false">قطار وچ شامل کرو</string>+ <string name="context_menu_go_to_queue" formatted="false">قطار اچ جاؤ</string>+ <string name="context_menu_browse_album" formatted="false">البم تے جاؤ</string>+ <string name="context_menu_browse_artist" formatted="false">آرٹسٹ تے جاؤ</string>+ <string name="context_menu_share" formatted="false">شئیر کرو</string>+ <string name="context_menu_sleep_timer" formatted="false">سلیپ ٹائمر</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">ٹائمر نوں آف کردیو</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">ٹریک دا اختتام</string>+ <string name="snackbar_added_to_queue" formatted="false">قطار وچ شامل ہو گیا</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">لائیک کردہ گانیاں وچ شامل ہو گیا۔</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">لائیک کردہ گانیاں توں ہٹا دتا گیا۔</string>+ <string name="content_description_context_menu" formatted="false">ہور اختیارات</string>+ <string name="close_button_content_description" formatted="false">بند کرو</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">ایہدے وچ محفوظ کیتا گیا</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">نویں پلے لسٹ</string>+ <string name="add_to_playlist_button_cancel" formatted="false">منسوخ کرو</string>+ <string name="create_playlist_create_button" formatted="false">بناؤ</string>+ <string name="lyrics_card_title" formatted="false">بول</string>+ <string name="lyrics_card_title_preview" formatted="false">بولاں دا پیش نظارہ</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">بول وکھاؤ</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">پوری اسکرین اتے بول کھولو</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">بول شئیر کرو</string>+ <string name="lyrics_credential_note" formatted="false">%1$s دے دِتے گانیاں دے بول</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">شئیر کرو</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">ترجمہ کرو</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">بول بند کرو</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">بول دا ترجمہ کرو</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">بولاں دا ترجمہ کرنا بند کرو</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">ہمم۔ سانوں ایدے بول دا نہیں پتا۔</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">ایہہ بول ہلے وقت دے لحاظ نال سنک نہیں ہین۔</string>+ <string name="av_switch_to_video" formatted="false">ویڈیو وچ سوئچ کرو</string>+ <string name="av_switch_to_audio" formatted="false">آڈیو وچ سوئچ کرو</string>+ <string name="av_content_desc" formatted="false">آڈیو تے ویڈیو دے وچکار ٹوگل کرو</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">ہوم</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">تلاش کرو</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">تہاڈی لائبریری</string>+ <string name="search_header_field_hint" formatted="false">تسی کیہ سننا چاہندے او؟</string>+ <string name="filter_chip_all_label" formatted="false">سارے</string>+ <string name="recents_content_filter_music" formatted="false">موسیقی</string>+ <string name="ad_category_title_podcasts" formatted="false">پوڈکاسٹس</string>+ <string name="audiobooks_title" formatted="false">آڈیو بکس</string>+ <string name="artist_popular_tracks" formatted="false">مقبول</string>+ <string name="curation_button_follow_state_text" formatted="false">فالو کرو</string>+ <string name="curation_button_following_state_text" formatted="false">فالو کر رئیے او</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">آرٹسٹ</string>+ <string name="connect_phone_is_self" formatted="false">ایہہ فون</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">جدوں کوئی گانا چل رہیا ہوندا اے تے مختصر، لوپنگ بصریات۔</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">ہجے نہیں</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">اپ ڈیٹ کرو</string>+ <string name="context_type_description_play_queue" formatted="false">قطار چلاؤ توں چلا رئیا اے</string>+ <string name="context_type_description_collection_your_library" formatted="false">تہاڈی لائبریری توں چلا رئیا اے</string>+ <string name="context_type_description_playlist" formatted="false">پلے لسٹ توں چلا رئیا اے</string>+ <string name="context_type_description_album" formatted="false">البم توں چلا رئیا اے</string>+ <string name="context_type_description_artist" formatted="false">آرٹسٹ توں چلا رئیا اے</string>+ <string name="context_type_description_show" formatted="false">پوڈ کاسٹ توں چلا رئیا اے</string>+ <string name="context_type_description_search" formatted="false">تلاش توں چلا رئیا اے</string>+ <string name="default_notification_channel_name" formatted="false">Spotify</string>+ <string name="label_bluetooth" formatted="false">بلوٹوتھ</string>+ <string name="action_share_label" formatted="false">شئیر کرو</string>+ <string name="action_queue_label" formatted="false">قطار</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 گھنٹہ</string>+ <string name="curation_actions_edit_button_title" formatted="false">ترمیم کرو</string>+ <string name="content_description_pause_button" formatted="false">روکو</string>+ <string name="content_description_play_button" formatted="false">چلاؤ</string>+ <string name="play_mode_item_shuffle_title" formatted="false">شفل کرو</string>+ <string name="np_content_desc_repeat" formatted="false">دہراؤ</string>+ <string name="np_content_desc_sleep_timer" formatted="false">سلیپ ٹائمر</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">ہٹاؤ</string>+ <string name="edit_playlist_items_move_chip" formatted="false">ودھو</string>+ <string name="bottom_actions_close" formatted="false">بند کرو</string>+ <string name="add_to_queue_action_content_description" formatted="false">قطار وچ شامل کرو</string>+ <string name="curation_button_saved_text" formatted="false">محفوظ شدہ</string>+ <string name="np_content_desc_prev" formatted="false">پچھلا</string>+ <string name="np_content_desc_next" formatted="false">اگلا</string>+ <string name="accessibility_navigate_back" formatted="false">واپس جاؤ</string>+ <string name="monthly_listeners_text" formatted="false">%1$s ماہانہ سُنن والے</string>+ <string name="profile_bio_show_less" formatted="false">گھٹ وکھاؤ</string>+ <string name="audiobook_series_see_more_button" formatted="false">ہور وکھاؤ</string>+ <string name="popular_releases_section_title" formatted="false">مقبول ریلیزاں</string>+ <string name="creator_biography_section_title" formatted="false">متعلق</string>+ <string name="fans_also_like_section_title" formatted="false">فینز نوں ایہہ وی پسند اے</string>+ <string name="appears_on_section_title" formatted="false">ایہناں وچ اے</string>+ <string name="composer_section_button_show_all" formatted="false">سارے وکھاؤ</string>+ <string name="releases_title" formatted="false">ریلیزاں</string>+ <string name="artist_releases_albums" formatted="false">البمز</string>+ <string name="artist_releases_singles" formatted="false">سنگلز اتے EPs</string>+ <string name="latest_release_title" formatted="false">نویں نکور ریلیز</string>+ <string name="artist_subtitle" formatted="false">آرٹسٹ</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">حالیہ تلاشاں</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">مٹاؤ</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">پوڈکاسٹس</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">قسطاں</string>+ <string name="assisted_curation_search_song" formatted="false">گانا</string>+ <string name="album" formatted="false">البم</string>+ <string name="album_type_podcast" formatted="false">پوڈکاسٹ</string>+ <string name="recently_played_user_profile" formatted="false">پروفائل</string>+ <string name="connect_device_menu_logout" formatted="false">لاگ آؤٹ کرو</string>+ <string name="library_search_text_hint" formatted="false">اپنی لائبریری تلاش کرو</string>+ <string name="account_title" formatted="false">اکاؤنٹ</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">فالو کیتے ہوئے آرٹسٹ</string>+ <string name="settings_item_crossfade_title" formatted="false">کراس فیڈ</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">مقامی فائلاں</string>+ <string name="local_files_empty_section_title" formatted="false">آپنی ذاتی آڈیو فائلاں آپنی لائبریری وچ شامل کرو</string>+ <string name="local_files_empty_section_subtitle" formatted="false">اک ایہوجیہا گانا یا ذاتی پوڈکاسٹ ملی اے جیہڑی Spotify تے نہیں اے؟</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">تہاڈی آڈیو فائلاں ایتھے ظاہر ہون گیاں</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">رسائی دوو</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">سیٹنگز اُتے جاؤ</string>+ <string name="context_menu_download" formatted="false">ڈاؤن لوڈ کرو</string>+ <string name="context_menu_undownload" formatted="false">ڈاؤن لوڈ ہٹاؤ</string>+ <string name="collection_downloaded" formatted="false">ڈاؤن لوڈ کیتا</string>+ <string name="download_badge_downloaded_content_description" formatted="false">ڈاؤن لوڈ ہو گیا</string>+ <string name="download_badge_downloading_content_description" formatted="false">ڈاؤن لوڈ ہو رئیا اے</string>+ <string name="download_badge_error_content_description" formatted="false">ڈاؤن لوڈ کرن وچ ناکام ہو گئے</string>+ <string name="download_notification_downloading" formatted="false">ڈاؤن لوڈ ہو رئیا اے…</string>+ <string name="toast_undownload" formatted="false">ڈاؤن لوڈ ہٹا دتی گئی۔</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">ڈاؤن لوڈز توں ہٹاؤ؟</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">تسی ایس نوں آف لائن نئیں چلا سکو گے۔</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">ہٹاؤ</string>+ <string name="settings_item_remove_downloads_title" formatted="false">سارے ڈاؤن لوڈز ہٹاؤ</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">سارے ڈاؤن لوڈ ہٹائیے؟</string>+ <string name="album_type_album" formatted="false">البم</string>+ <string name="album_type_single" formatted="false">سنگل</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">تالیف</string>+ <string name="assisted_curation_search_playlist" formatted="false">پلے لسٹ</string>+ <string name="assisted_curation_search_filter_top" formatted="false">ٹاپ</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">گانے</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">آرٹسٹس</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">البمز</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">پلے لسٹس</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">فلٹر ہٹاؤ</string>+ <string name="ad_category_title_music" formatted="false">موسیقی</string>+ <string name="made_for_you_hub_title" formatted="false">تہاڈے لئی بنیا</string>+ <string name="settings_item_app_language_title" formatted="false">ایپ دی زبان</string>+ <string name="create_menu_item_folder_title" formatted="false">فولڈر</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">نواں فولڈر</string>+ <string name="context_menu_rename_folder" formatted="false">فولڈر دا ناں بدلو</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">فولڈر ناں</string>+ <string name="create_playlist_content_description" formatted="false">پلے لسٹ بناؤ</string>+ <string name="actions_picker_delete" formatted="false">ڈیلیٹ کرو</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">ترتیب دو بلحاظ</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">حروف تہجی نال</string>+ <string name="your_library_sort_order_creator" formatted="false">تخلیق کار</string>+ <string name="your_library_sort_order_custom" formatted="false">مخصوص آرڈر</string>+ <string name="settings_item_version_title" formatted="false">ورژن</string>+ <string name="context_menu_go_to_song_radio" formatted="false">گانیاں دے ریڈیو تے جاؤ</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">پسند کیتے گانیاں وچ لبھو</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">پلے لسٹ وچ لبھو</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\" نوں نئیں لبھ سکیا</string>+</resources>diff --git a/base/app/src/main/res/values-pa/spotify_strings.xml b/base/app/src/main/res/values-pa/spotify_strings.xmlnew file mode 100644index 00000000..c1377a8f--- /dev/null+++ b/base/app/src/main/res/values-pa/spotify_strings.xml@@ -0,0 +1,6 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="default_notification_channel_name" formatted="false">ਹੁਣੇ ਚੱਲ ਰਿਹਾ ਹੈ</string>+ <string name="mr_user_route_category_name" formatted="false">ਡੀਵਾਈਸਾਂ</string>+</resources>diff --git a/base/app/src/main/res/values-pl/spotify_plurals.xml b/base/app/src/main/res/values-pl/spotify_plurals.xmlnew file mode 100644index 00000000..9afcc898--- /dev/null+++ b/base/app/src/main/res/values-pl/spotify_plurals.xml@@ -0,0 +1,28 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d utwór</item>+ <item quantity="few">%1$d utwory</item>+ <item quantity="many">%1$d utworów</item>+ <item quantity="other">%1$d utworu</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d zapis</item>+ <item quantity="few">%1$,d zapisy</item>+ <item quantity="many">%1$,d zapisów</item>+ <item quantity="other">%1$,d zapisu</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlista</item>+ <item quantity="few">%1$s playlisty</item>+ <item quantity="many">%1$s playlist</item>+ <item quantity="other">%1$s playlisty</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s utwór</item>+ <item quantity="few">%1$s utwory</item>+ <item quantity="many">%1$s utworów</item>+ <item quantity="other">%1$s utworu</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-pl/spotify_strings.xml b/base/app/src/main/res/values-pl/spotify_strings.xmlnew file mode 100644index 00000000..f1b0c2cd--- /dev/null+++ b/base/app/src/main/res/values-pl/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Dodaj do Polubionych utworów</string>+ <string name="collection_liked_songs_title" formatted="false">Polubione utwory</string>+ <string name="context_menu_add_to_playlist" formatted="false">Dodaj do playlisty</string>+ <string name="context_menu_play_next" formatted="false">Odtwórz jako następny</string>+ <string name="context_menu_add_to_queue" formatted="false">Dodaj do kolejki</string>+ <string name="context_menu_go_to_queue" formatted="false">Przejdź do kolejki</string>+ <string name="context_menu_browse_album" formatted="false">Przejdź do albumu</string>+ <string name="context_menu_browse_artist" formatted="false">Przejdź do wykonawcy</string>+ <string name="context_menu_share" formatted="false">Udostępnij</string>+ <string name="context_menu_sleep_timer" formatted="false">Wyłącznik czasowy</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Wyłącz wyłącznik czasowy</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Koniec utworu</string>+ <string name="snackbar_added_to_queue" formatted="false">Dodano do kolejki</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Dodano do Polubionych utworów.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Usunięto z Polubionych utworów.</string>+ <string name="content_description_context_menu" formatted="false">Więcej opcji</string>+ <string name="close_button_content_description" formatted="false">Zamknij</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Zapisane</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nowa playlista</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Anuluj</string>+ <string name="create_playlist_create_button" formatted="false">Utwórz</string>+ <string name="lyrics_card_title" formatted="false">Teksty</string>+ <string name="lyrics_card_title_preview" formatted="false">Podgląd tekstu</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Pokaż tekst</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Otwórz tekst w widoku pełnoekranowym</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Udostępnij tekst</string>+ <string name="lyrics_credential_note" formatted="false">Tekst udostępniony przez: %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Udostępnij</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Przetłumacz</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Zamknąć widok tekstu</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Przetłumacz tekst</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Zatrzymać tłumaczenie tekstu</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmmm. My też nie znamy tekstu.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Tekst utworu nie jest jeszcze zsynchronizowany czasowo.</string>+ <string name="av_switch_to_video" formatted="false">Przełącz na wideo</string>+ <string name="av_switch_to_audio" formatted="false">Przełącz na audio</string>+ <string name="av_content_desc" formatted="false">Przełączanie formatu między audio a wideo</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Home</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Wyszukaj</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Biblioteka</string>+ <string name="search_header_field_hint" formatted="false">Czego chcesz posłuchać?</string>+ <string name="filter_chip_all_label" formatted="false">Wszystko</string>+ <string name="recents_content_filter_music" formatted="false">Muzyka</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasty</string>+ <string name="audiobooks_title" formatted="false">Audiobooki</string>+ <string name="artist_popular_tracks" formatted="false">Popularne</string>+ <string name="curation_button_follow_state_text" formatted="false">Obserwuj</string>+ <string name="curation_button_following_state_text" formatted="false">Obserwujesz</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Wykonawca</string>+ <string name="connect_phone_is_self" formatted="false">Ten telefon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Krótkie, zapętlone wizualizacje wyświetlane podczas odtwarzania utworu.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Nie teraz</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Aktualizacja</string>+ <string name="context_type_description_play_queue" formatted="false">Odtwarzanie z katalogu Kolejka odtwarzania</string>+ <string name="context_type_description_collection_your_library" formatted="false">Odtwarzanie z Biblioteki</string>+ <string name="context_type_description_playlist" formatted="false">Odtwarzanie z playlisty</string>+ <string name="context_type_description_album" formatted="false">Odtwarzanie z albumu</string>+ <string name="context_type_description_artist" formatted="false">Odtwarzanie ze strony wykonawcy</string>+ <string name="context_type_description_show" formatted="false">Odtwarzanie z podcastu</string>+ <string name="context_type_description_search" formatted="false">Odtwarzanie z wyników wyszukiwania</string>+ <string name="default_notification_channel_name" formatted="false">Odtwarzam teraz</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Urządzenia</string>+ <string name="action_share_label" formatted="false">Udostępnij</string>+ <string name="action_queue_label" formatted="false">Kolejka</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 godzina</string>+ <string name="curation_actions_edit_button_title" formatted="false">Edytuj</string>+ <string name="content_description_pause_button" formatted="false">Pauza</string>+ <string name="content_description_play_button" formatted="false">Odtwarzaj</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Losowo</string>+ <string name="np_content_desc_repeat" formatted="false">Powtórz</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Wyłącznik czasowy</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Usuń</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Przenieś</string>+ <string name="bottom_actions_close" formatted="false">Zamknij</string>+ <string name="add_to_queue_action_content_description" formatted="false">Dodaj do kolejki</string>+ <string name="curation_button_saved_text" formatted="false">Zapisane</string>+ <string name="np_content_desc_prev" formatted="false">Wstecz</string>+ <string name="np_content_desc_next" formatted="false">Dalej</string>+ <string name="accessibility_navigate_back" formatted="false">Wstecz</string>+ <string name="monthly_listeners_text" formatted="false">%1$s słuchaczy w miesiącu</string>+ <string name="profile_bio_show_less" formatted="false">Pokaż mniej</string>+ <string name="audiobook_series_see_more_button" formatted="false">Pokaż więcej</string>+ <string name="popular_releases_section_title" formatted="false">Popularne wydania</string>+ <string name="creator_biography_section_title" formatted="false">Informacje</string>+ <string name="fans_also_like_section_title" formatted="false">Fani lubią też</string>+ <string name="appears_on_section_title" formatted="false">Pojawia się na</string>+ <string name="composer_section_button_show_all" formatted="false">Pokaż wszystko</string>+ <string name="releases_title" formatted="false">Wydania</string>+ <string name="artist_releases_albums" formatted="false">Albumy</string>+ <string name="artist_releases_singles" formatted="false">Single i EP</string>+ <string name="latest_release_title" formatted="false">Ostatnie wydanie</string>+ <string name="artist_subtitle" formatted="false">Wykonawca</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Ostatnie wyszukiwania</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Wyczyść</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasty</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Odcinki</string>+ <string name="assisted_curation_search_song" formatted="false">Utwór</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Wyloguj</string>+ <string name="library_search_text_hint" formatted="false">Wyszukaj w Bibliotece</string>+ <string name="account_title" formatted="false">Konto</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Obserwowani wykonawcy</string>+ <string name="settings_item_crossfade_title" formatted="false">Płynne przejście</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d sek.</string>+ <string name="local_files_title" formatted="false">Pliki lokalne</string>+ <string name="local_files_empty_section_title" formatted="false">Dodaj własne pliki audio do Biblioteki</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Masz na dysku utwór lub podcast, który jest niedostępny w Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Twoje pliki audio będą widoczne w tym miejscu</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Przyznaj dostęp</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Przejdź do Ustawień</string>+ <string name="context_menu_download" formatted="false">Pobierz</string>+ <string name="context_menu_undownload" formatted="false">Usuń pobrane</string>+ <string name="collection_downloaded" formatted="false">Pobrane</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Pobrane</string>+ <string name="download_badge_downloading_content_description" formatted="false">Pobieranie</string>+ <string name="download_badge_error_content_description" formatted="false">Pobieranie się nie powiodło</string>+ <string name="download_notification_downloading" formatted="false">Pobieranie…</string>+ <string name="toast_undownload" formatted="false">Usunięto z pobranych.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Usunąć z Pobranych?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Nie będzie można odtworzyć tego w trybie offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Usuń</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Usuwanie pobranych utworów</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Usunąć wszystkie pobrane utwory?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Singiel</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Kompilacja</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlista</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Najtrafniejsze</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Utwory</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Wykonawcy</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albumy</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlisty</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Wyczyść filtr</string>+ <string name="ad_category_title_music" formatted="false">Muzyka</string>+ <string name="made_for_you_hub_title" formatted="false">Przygotowane dla Ciebie</string>+ <string name="settings_item_app_language_title" formatted="false">Język aplikacji</string>+ <string name="create_menu_item_folder_title" formatted="false">Folder</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nowy folder</string>+ <string name="context_menu_rename_folder" formatted="false">Zmień nazwę folderu</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Nazwa folderu</string>+ <string name="create_playlist_content_description" formatted="false">Utwórz playlistę</string>+ <string name="actions_picker_delete" formatted="false">Usuń</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sortuj wg</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alfabetycznie</string>+ <string name="your_library_sort_order_creator" formatted="false">Twórca</string>+ <string name="your_library_sort_order_custom" formatted="false">Kolejność własna</string>+ <string name="settings_item_version_title" formatted="false">Wersja</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Przejdź do radia utworu</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Wyszukaj w Polubionych utworach</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Wyszukaj w playliście</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Nie znaleziono „%1$s”</string>+</resources>diff --git a/base/app/src/main/res/values-pt-rPT/spotify_plurals.xml b/base/app/src/main/res/values-pt-rPT/spotify_plurals.xmlnew file mode 100644index 00000000..fd944249--- /dev/null+++ b/base/app/src/main/res/values-pt-rPT/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d música</item>+ <item quantity="other">%1$d músicas</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">Guardada %1$,d vez</item>+ <item quantity="other">Guardada %1$,d vezes</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="other">%1$s playlists</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s música</item>+ <item quantity="other">%1$s músicas</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-pt-rPT/spotify_strings.xml b/base/app/src/main/res/values-pt-rPT/spotify_strings.xmlnew file mode 100644index 00000000..f3ce3ead--- /dev/null+++ b/base/app/src/main/res/values-pt-rPT/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Adicionar às Músicas apreciadas</string>+ <string name="collection_liked_songs_title" formatted="false">Músicas de que gostaste</string>+ <string name="context_menu_add_to_playlist" formatted="false">Adicionar à playlist</string>+ <string name="context_menu_play_next" formatted="false">Reproduzir a seguir</string>+ <string name="context_menu_add_to_queue" formatted="false">Adicionar à fila</string>+ <string name="context_menu_go_to_queue" formatted="false">Ir para a fila</string>+ <string name="context_menu_browse_album" formatted="false">Ir para o álbum</string>+ <string name="context_menu_browse_artist" formatted="false">Ir para o artista</string>+ <string name="context_menu_share" formatted="false">Partilhar</string>+ <string name="context_menu_sleep_timer" formatted="false">Temporizador</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Desligar temporizador</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Fim da faixa</string>+ <string name="snackbar_added_to_queue" formatted="false">Adicionada à Fila</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Adicionada às Músicas apreciadas.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Removida das Músicas apreciadas.</string>+ <string name="content_description_context_menu" formatted="false">Mais opções</string>+ <string name="close_button_content_description" formatted="false">Fechar</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Guardado em:</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nova playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Cancelar</string>+ <string name="create_playlist_create_button" formatted="false">Criar</string>+ <string name="lyrics_card_title" formatted="false">Letra</string>+ <string name="lyrics_card_title_preview" formatted="false">Pré-visualização das letras</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Mostrar letra</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Abrir letra em ecrã cheio</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Partilhar a letra</string>+ <string name="lyrics_credential_note" formatted="false">Letra fornecida por %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Partilhar</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Traduzir</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Fechar letra</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Traduzir letra</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Parar de traduzir letra</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Pois é… Não sabemos a letra.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Esta letra ainda não está sincronizada.</string>+ <string name="av_switch_to_video" formatted="false">Mudar para vídeo</string>+ <string name="av_switch_to_audio" formatted="false">Mudar para áudio</string>+ <string name="av_content_desc" formatted="false">Alternar entre áudio e vídeo</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Início</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Procurar</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">A tua Biblioteca</string>+ <string name="search_header_field_hint" formatted="false">O que queres ouvir?</string>+ <string name="filter_chip_all_label" formatted="false">Tudo</string>+ <string name="recents_content_filter_music" formatted="false">Música</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasts</string>+ <string name="audiobooks_title" formatted="false">Audiolivros</string>+ <string name="artist_popular_tracks" formatted="false">Popular</string>+ <string name="curation_button_follow_state_text" formatted="false">Seguir</string>+ <string name="curation_button_following_state_text" formatted="false">A seguir</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artista</string>+ <string name="connect_phone_is_self" formatted="false">Este telemóvel</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Breves elementos visuais em loop quando uma música está a ser reproduzida.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Agora não</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Atualizar</string>+ <string name="context_type_description_play_queue" formatted="false">A reproduzir da Fila de reprodução</string>+ <string name="context_type_description_collection_your_library" formatted="false">A reproduzir de A tua Biblioteca</string>+ <string name="context_type_description_playlist" formatted="false">A reproduzir da playlist</string>+ <string name="context_type_description_album" formatted="false">A reproduzir do Álbum</string>+ <string name="context_type_description_artist" formatted="false">A reproduzir do Artista</string>+ <string name="context_type_description_show" formatted="false">A reproduzir do podcast</string>+ <string name="context_type_description_search" formatted="false">A reproduzir da Procura</string>+ <string name="default_notification_channel_name" formatted="false">A tocar</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Dispositivos</string>+ <string name="action_share_label" formatted="false">Partilhar</string>+ <string name="action_queue_label" formatted="false">Adicionar à fila</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 hora</string>+ <string name="curation_actions_edit_button_title" formatted="false">Editar</string>+ <string name="content_description_pause_button" formatted="false">Pausar</string>+ <string name="content_description_play_button" formatted="false">Reproduzir</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Modo aleatório</string>+ <string name="np_content_desc_repeat" formatted="false">Repetir</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Temporizador</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Remover</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Mover</string>+ <string name="bottom_actions_close" formatted="false">Fechar</string>+ <string name="add_to_queue_action_content_description" formatted="false">Adicionar à fila</string>+ <string name="curation_button_saved_text" formatted="false">Guardado</string>+ <string name="np_content_desc_prev" formatted="false">Anterior</string>+ <string name="np_content_desc_next" formatted="false">Seguinte</string>+ <string name="accessibility_navigate_back" formatted="false">Voltar</string>+ <string name="monthly_listeners_text" formatted="false">%1$s ouvintes por mês</string>+ <string name="profile_bio_show_less" formatted="false">Mostrar menos</string>+ <string name="audiobook_series_see_more_button" formatted="false">Mostrar mais</string>+ <string name="popular_releases_section_title" formatted="false">Lançamentos populares</string>+ <string name="creator_biography_section_title" formatted="false">Sobre</string>+ <string name="fans_also_like_section_title" formatted="false">Os fãs também gostam</string>+ <string name="appears_on_section_title" formatted="false">Aparece em</string>+ <string name="composer_section_button_show_all" formatted="false">Mostrar tudo</string>+ <string name="releases_title" formatted="false">Lançamentos</string>+ <string name="artist_releases_albums" formatted="false">Álbuns</string>+ <string name="artist_releases_singles" formatted="false">Singles e EP</string>+ <string name="latest_release_title" formatted="false">Últimos lançamentos</string>+ <string name="artist_subtitle" formatted="false">Artista</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Pesquisas recentes</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Limpar</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasts</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episódios</string>+ <string name="assisted_curation_search_song" formatted="false">Música</string>+ <string name="album" formatted="false">Álbum</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Perfil</string>+ <string name="connect_device_menu_logout" formatted="false">Terminar sessão</string>+ <string name="library_search_text_hint" formatted="false">Procurar em A tua Biblioteca</string>+ <string name="account_title" formatted="false">Conta</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Artistas seguidos</string>+ <string name="settings_item_crossfade_title" formatted="false">Transição gradual</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Ficheiros locais</string>+ <string name="local_files_empty_section_title" formatted="false">Adiciona os teus ficheiros de áudio à secção A tua Biblioteca</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Tens uma música ou um podcast pessoal que não esteja no Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Os teus ficheiros de áudio aparecem aqui</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Dar acesso</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Ir para Definições</string>+ <string name="context_menu_download" formatted="false">Transferir</string>+ <string name="context_menu_undownload" formatted="false">Remover transferência</string>+ <string name="collection_downloaded" formatted="false">Transferido</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Transferido</string>+ <string name="download_badge_downloading_content_description" formatted="false">A transferir</string>+ <string name="download_badge_error_content_description" formatted="false">A transferência falhou</string>+ <string name="download_notification_downloading" formatted="false">A transferir…</string>+ <string name="toast_undownload" formatted="false">Transferência removida.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Remover das transferências?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Não vais poder reproduzir isto offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Remover</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Remover todas as transferências</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Remover todas as transferências?</string>+ <string name="album_type_album" formatted="false">Álbum</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Compilação</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Melhores resultados</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Músicas</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artistas</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Álbuns</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlists</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Limpar filtro</string>+ <string name="ad_category_title_music" formatted="false">Música</string>+ <string name="made_for_you_hub_title" formatted="false">Feita para ti</string>+ <string name="settings_item_app_language_title" formatted="false">Idioma da app</string>+ <string name="create_menu_item_folder_title" formatted="false">Pasta</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nova pasta</string>+ <string name="context_menu_rename_folder" formatted="false">Mudar o nome da pasta</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Nome da pasta</string>+ <string name="create_playlist_content_description" formatted="false">Criar playlist</string>+ <string name="actions_picker_delete" formatted="false">Eliminar</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Ordenar por</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alfabética</string>+ <string name="your_library_sort_order_creator" formatted="false">Criador</string>+ <string name="your_library_sort_order_custom" formatted="false">Ordenação personalizada</string>+ <string name="settings_item_version_title" formatted="false">Versão</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Ir para a rádio da música</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Encontrar em Músicas apreciadas</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Encontrar na playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Não foi possível encontrar \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-pt/spotify_plurals.xml b/base/app/src/main/res/values-pt/spotify_plurals.xmlnew file mode 100644index 00000000..b9b6e0f9--- /dev/null+++ b/base/app/src/main/res/values-pt/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d música</item>+ <item quantity="other">%1$d músicas</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d salvamento</item>+ <item quantity="other">%1$,d salvamentos</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="other">%1$s playlists</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s música</item>+ <item quantity="other">%1$s músicas</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-pt/spotify_strings.xml b/base/app/src/main/res/values-pt/spotify_strings.xmlnew file mode 100644index 00000000..733b0e5e--- /dev/null+++ b/base/app/src/main/res/values-pt/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Adicionar a Músicas Curtidas</string>+ <string name="collection_liked_songs_title" formatted="false">Músicas Curtidas</string>+ <string name="context_menu_add_to_playlist" formatted="false">Adicionar à playlist</string>+ <string name="context_menu_play_next" formatted="false">Tocar a seguir</string>+ <string name="context_menu_add_to_queue" formatted="false">Adicionar à fila</string>+ <string name="context_menu_go_to_queue" formatted="false">Abrir a fila de reprodução</string>+ <string name="context_menu_browse_album" formatted="false">Ir para o álbum</string>+ <string name="context_menu_browse_artist" formatted="false">Ir para o artista</string>+ <string name="context_menu_share" formatted="false">Compartilhar</string>+ <string name="context_menu_sleep_timer" formatted="false">Timer</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Desligar o timer</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Quando a faixa terminar</string>+ <string name="snackbar_added_to_queue" formatted="false">Adicionada à fila</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Adicionada a Músicas Curtidas.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Removida das Músicas Curtidas.</string>+ <string name="content_description_context_menu" formatted="false">Mais opções</string>+ <string name="close_button_content_description" formatted="false">Fechar</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Conteúdo salvo em:</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nova playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Cancelar</string>+ <string name="create_playlist_create_button" formatted="false">Criar</string>+ <string name="lyrics_card_title" formatted="false">Letra</string>+ <string name="lyrics_card_title_preview" formatted="false">Prévia da letra</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Mostrar letra</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Abrir a letra em tela cheia</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Compartilhar letra</string>+ <string name="lyrics_credential_note" formatted="false">Letra disponibilizada por %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Compartilhar</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Traduzir</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Fechar letras</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Traduzir letra</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Parar de traduzir letras</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Parece que ainda não aprendemos esta letra.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Ainda não sincronizamos essa letra.</string>+ <string name="av_switch_to_video" formatted="false">Mudar para vídeo</string>+ <string name="av_switch_to_audio" formatted="false">Mudar para áudio</string>+ <string name="av_content_desc" formatted="false">Alternar entre áudio e vídeo</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Início</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Buscar</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Sua Biblioteca</string>+ <string name="search_header_field_hint" formatted="false">O que você quer ouvir?</string>+ <string name="filter_chip_all_label" formatted="false">Tudo</string>+ <string name="recents_content_filter_music" formatted="false">Músicas</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasts</string>+ <string name="audiobooks_title" formatted="false">Audiolivros</string>+ <string name="artist_popular_tracks" formatted="false">Populares</string>+ <string name="curation_button_follow_state_text" formatted="false">Seguir</string>+ <string name="curation_button_following_state_text" formatted="false">Seguindo</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artista</string>+ <string name="connect_phone_is_self" formatted="false">Este telefone</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Efeitos visuais curtos em loop quando uma música está tocando.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Agora não</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Atualizar</string>+ <string name="context_type_description_play_queue" formatted="false">Tocando Fila para tocar</string>+ <string name="context_type_description_collection_your_library" formatted="false">Tocando da Sua Biblioteca</string>+ <string name="context_type_description_playlist" formatted="false">Tocando da playlist</string>+ <string name="context_type_description_album" formatted="false">Tocando do álbum</string>+ <string name="context_type_description_artist" formatted="false">Tocando do Artista</string>+ <string name="context_type_description_show" formatted="false">Tocando podcast</string>+ <string name="context_type_description_search" formatted="false">Tocando da Busca</string>+ <string name="default_notification_channel_name" formatted="false">Tocando agora</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Dispositivos</string>+ <string name="action_share_label" formatted="false">Compartilhar</string>+ <string name="action_queue_label" formatted="false">Fila</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 hora</string>+ <string name="curation_actions_edit_button_title" formatted="false">Editar</string>+ <string name="content_description_pause_button" formatted="false">Pausar</string>+ <string name="content_description_play_button" formatted="false">Play</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Ordem aleatória</string>+ <string name="np_content_desc_repeat" formatted="false">Repetir</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Timer</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Remover</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Mover</string>+ <string name="bottom_actions_close" formatted="false">Fechar</string>+ <string name="add_to_queue_action_content_description" formatted="false">Adicionar à fila</string>+ <string name="curation_button_saved_text" formatted="false">Salvo</string>+ <string name="np_content_desc_prev" formatted="false">Voltar</string>+ <string name="np_content_desc_next" formatted="false">Avançar</string>+ <string name="accessibility_navigate_back" formatted="false">Voltar</string>+ <string name="monthly_listeners_text" formatted="false">%1$s ouvintes mensais</string>+ <string name="profile_bio_show_less" formatted="false">Mostrar menos</string>+ <string name="audiobook_series_see_more_button" formatted="false">Mostrar mais</string>+ <string name="popular_releases_section_title" formatted="false">Lançamentos populares</string>+ <string name="creator_biography_section_title" formatted="false">Sobre</string>+ <string name="fans_also_like_section_title" formatted="false">Os fãs também curtem</string>+ <string name="appears_on_section_title" formatted="false">Aparece em</string>+ <string name="composer_section_button_show_all" formatted="false">Mostrar tudo</string>+ <string name="releases_title" formatted="false">Lançamentos</string>+ <string name="artist_releases_albums" formatted="false">Álbuns</string>+ <string name="artist_releases_singles" formatted="false">Singles e EPs</string>+ <string name="latest_release_title" formatted="false">Último lançamento</string>+ <string name="artist_subtitle" formatted="false">Artista</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Buscas recentes</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Limpar</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasts</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episódios</string>+ <string name="assisted_curation_search_song" formatted="false">Música</string>+ <string name="album" formatted="false">Álbum</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Perfil</string>+ <string name="connect_device_menu_logout" formatted="false">Sair</string>+ <string name="library_search_text_hint" formatted="false">Busque na Sua Biblioteca</string>+ <string name="account_title" formatted="false">Conta</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Artistas seguidos</string>+ <string name="settings_item_crossfade_title" formatted="false">Transição gradual</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Arquivos locais</string>+ <string name="local_files_empty_section_title" formatted="false">Adicione seus próprios arquivos de áudio à Sua Biblioteca</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Tem uma música ou podcast pessoal que não está no Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Os arquivos de áudio vão aparecer aqui</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Permitir acesso</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Ir para as Configurações</string>+ <string name="context_menu_download" formatted="false">Baixar</string>+ <string name="context_menu_undownload" formatted="false">Remover download</string>+ <string name="collection_downloaded" formatted="false">Baixados</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Baixado</string>+ <string name="download_badge_downloading_content_description" formatted="false">Baixando</string>+ <string name="download_badge_error_content_description" formatted="false">Falha no download</string>+ <string name="download_notification_downloading" formatted="false">Baixando…</string>+ <string name="toast_undownload" formatted="false">Download removido.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Quer mesmo remover isso dos Downloads?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Você não poderá ouvir esse conteúdo quando estiver offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Remover</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Remover todos os downloads</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Remover todos os downloads?</string>+ <string name="album_type_album" formatted="false">Álbum</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Compilação</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Melhores resultados</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Músicas</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artistas</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Álbuns</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlists</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Limpar filtro</string>+ <string name="ad_category_title_music" formatted="false">Músicas</string>+ <string name="made_for_you_hub_title" formatted="false">Feito para você</string>+ <string name="settings_item_app_language_title" formatted="false">Idioma do app</string>+ <string name="create_menu_item_folder_title" formatted="false">Pasta</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nova pasta</string>+ <string name="context_menu_rename_folder" formatted="false">Renomear pasta</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Nome da pasta</string>+ <string name="create_playlist_content_description" formatted="false">Criar playlist</string>+ <string name="actions_picker_delete" formatted="false">Excluir</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Classificar por</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Ordem alfabética</string>+ <string name="your_library_sort_order_creator" formatted="false">Criador</string>+ <string name="your_library_sort_order_custom" formatted="false">Ordem personalizada</string>+ <string name="settings_item_version_title" formatted="false">Versão</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Ir para a rádio da música</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Procurar nas músicas curtidas</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Procurar nesta playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Não foi possível encontrar “%1$s”</string>+</resources>diff --git a/base/app/src/main/res/values-pt/strings.xml b/base/app/src/main/res/values-pt/strings.xmlnew file mode 100644index 00000000..74b60a0a--- /dev/null+++ b/base/app/src/main/res/values-pt/strings.xml@@ -0,0 +1,35 @@+<?xml version="1.0" encoding="utf-8"?>+<resources>+ <string name="app_name">Myspoti</string>+ <string name="aa_playlists">Playlists</string>+ <string name="aa_albums">Álbuns</string>+ <string name="aa_artists">Artistas</string>+ <string name="aa_podcasts">Podcasts</string>+ <string name="settings_amoled_theme">Tema AMOLED</string>+ <string name="settings_amoled_theme_subtitle">Fundo preto puro para economizar bateria</string>+ <string name="settings_lyrics_style_spotify_default">Spotify padrão</string>+ <string name="settings_lyrics_style_fullscreen">Tela cheia (cores do álbum)</string>+ <string name="settings_lyrics_style_compact">Compacto</string>+ <string name="settings_lyrics_style_karaoke">Karaokê</string>+ <string name="settings_lyrics_style_bold">Grande e em negrito</string>+ <string name="main_update_available">Uma nova atualização está disponível</string>+ <string name="notif_channel_media_name">Reprodução de mídia</string>+ <string name="notif_channel_media_description">Controles de reprodução de mídia do Myspoti</string>+ <string name="notif_action_previous">Anterior</string>+ <string name="notif_action_next">Próxima</string>+ <string name="notif_action_play">Tocar</string>+ <string name="notif_action_pause">Pausar</string>+ <string name="notif_shuffle_enable">Ativar reprodução aleatória</string>+ <string name="notif_shuffle_disable">Desativar reprodução aleatória</string>+ <string name="notif_shuffle_disable_smart">Desativar a reprodução aleatória inteligente</string>+ <string name="notif_action_like">Curtir</string>+ <string name="notif_action_unlike">Remover \'Curtir\'</string>+ <string name="notif_unknown_name">Desconhecido</string>+ <string name="notif_by_artist">por %1$s</string>+ <string name="notif_repeat_disable">Desativar repetição</string>+ <string name="notif_repeat_disable_one">Desativar repetir uma</string>+ <string name="notif_repeat_enable">Ativar repetição</string>+ <string name="bridge_player_unlocked">Reprodutor desbloqueado</string>+ <string name="bridge_reloading">Recarregando…</string>+ <string name="service_disabled_message">O serviço não está ativado</string>+</resources>diff --git a/base/app/src/main/res/values-ro/spotify_plurals.xml b/base/app/src/main/res/values-ro/spotify_plurals.xmlnew file mode 100644index 00000000..8b252c28--- /dev/null+++ b/base/app/src/main/res/values-ro/spotify_plurals.xml@@ -0,0 +1,24 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d melodie</item>+ <item quantity="few">%1$d melodii</item>+ <item quantity="other">%1$d de melodii</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d salvare</item>+ <item quantity="few">%1$,d salvări</item>+ <item quantity="other">%1$,d de salvări</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="few">%1$s playlisturi</item>+ <item quantity="other">%1$s de playlisturi</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s melodie</item>+ <item quantity="few">%1$s melodii</item>+ <item quantity="other">%1$s de melodii</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ro/spotify_strings.xml b/base/app/src/main/res/values-ro/spotify_strings.xmlnew file mode 100644index 00000000..efe2d01b--- /dev/null+++ b/base/app/src/main/res/values-ro/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Adaugă la Melodii apreciate</string>+ <string name="collection_liked_songs_title" formatted="false">Melodii apreciate</string>+ <string name="context_menu_add_to_playlist" formatted="false">Adaugă în playlist</string>+ <string name="context_menu_play_next" formatted="false">Adaugă la începutul cozii</string>+ <string name="context_menu_add_to_queue" formatted="false">Adaugă în coadă</string>+ <string name="context_menu_go_to_queue" formatted="false">Accesează coada</string>+ <string name="context_menu_browse_album" formatted="false">Mergi la album</string>+ <string name="context_menu_browse_artist" formatted="false">Mergi la artist</string>+ <string name="context_menu_share" formatted="false">Distribuie</string>+ <string name="context_menu_sleep_timer" formatted="false">Temporizator pentru somn</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Oprește cronometrul</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Sfârșitul piesei</string>+ <string name="snackbar_added_to_queue" formatted="false">Adăugat în coadă</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Adăugată în Melodii apreciate.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Eliminată din Melodii apreciate.</string>+ <string name="content_description_context_menu" formatted="false">Mai multe opțiuni</string>+ <string name="close_button_content_description" formatted="false">Închide</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Salvat în</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Playlist nou</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Anulează</string>+ <string name="create_playlist_create_button" formatted="false">Creează</string>+ <string name="lyrics_card_title" formatted="false">Versuri</string>+ <string name="lyrics_card_title_preview" formatted="false">Fragment versuri</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Afișează versurile</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Deschide versurile pe ecran complet</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Distribuie versurile</string>+ <string name="lyrics_credential_note" formatted="false">Versuri furnizate de %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Distribuie</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Tradu</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Închide versurile</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Tradu versurile</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Oprește traducerea versurilor</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Nu știm versurile acestei melodii.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Momentan, aceste versuri nu sunt sincronizate în timp.</string>+ <string name="av_switch_to_video" formatted="false">Comută la video</string>+ <string name="av_switch_to_audio" formatted="false">Comută la audio</string>+ <string name="av_content_desc" formatted="false">Comută între audio și video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Acasă</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Caută</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Biblioteca ta</string>+ <string name="search_header_field_hint" formatted="false">Ce dorești să asculți?</string>+ <string name="filter_chip_all_label" formatted="false">Tot</string>+ <string name="recents_content_filter_music" formatted="false">Muzică</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasturi</string>+ <string name="audiobooks_title" formatted="false">Cărți audio</string>+ <string name="artist_popular_tracks" formatted="false">Popular</string>+ <string name="curation_button_follow_state_text" formatted="false">Urmărește</string>+ <string name="curation_button_following_state_text" formatted="false">Urmărești</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artist</string>+ <string name="connect_phone_is_self" formatted="false">Acest telefon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Conținut video scurt, afișat în buclă în timpul redării unei melodii.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Nu acum</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Actualizează</string>+ <string name="context_type_description_play_queue" formatted="false">Se redă din Coada de redare</string>+ <string name="context_type_description_collection_your_library" formatted="false">Se redă din Biblioteca ta</string>+ <string name="context_type_description_playlist" formatted="false">Se redă din Playlist</string>+ <string name="context_type_description_album" formatted="false">Se redă de pe Album</string>+ <string name="context_type_description_artist" formatted="false">Se redă de la</string>+ <string name="context_type_description_show" formatted="false">Se redă din podcast</string>+ <string name="context_type_description_search" formatted="false">Se redă din Căutare</string>+ <string name="default_notification_channel_name" formatted="false">Se redă acum</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Dispozitive</string>+ <string name="action_share_label" formatted="false">Distribuie</string>+ <string name="action_queue_label" formatted="false">Adaugă în coadă</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 oră</string>+ <string name="curation_actions_edit_button_title" formatted="false">Editează</string>+ <string name="content_description_pause_button" formatted="false">Pauză</string>+ <string name="content_description_play_button" formatted="false">Redă</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Redă aleatoriu</string>+ <string name="np_content_desc_repeat" formatted="false">Repetă</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Temporizator pentru somn</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Elimină</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Mută</string>+ <string name="bottom_actions_close" formatted="false">Închide</string>+ <string name="add_to_queue_action_content_description" formatted="false">Adaugă în coadă</string>+ <string name="curation_button_saved_text" formatted="false">Salvat</string>+ <string name="np_content_desc_prev" formatted="false">Înapoi</string>+ <string name="np_content_desc_next" formatted="false">Înainte</string>+ <string name="accessibility_navigate_back" formatted="false">Înapoi</string>+ <string name="monthly_listeners_text" formatted="false">%1$s ascultători pe lună</string>+ <string name="profile_bio_show_less" formatted="false">Afișează mai puțin</string>+ <string name="audiobook_series_see_more_button" formatted="false">Afișează mai multe</string>+ <string name="popular_releases_section_title" formatted="false">Lansări populare</string>+ <string name="creator_biography_section_title" formatted="false">Despre</string>+ <string name="fans_also_like_section_title" formatted="false">Fanii apreciază și</string>+ <string name="appears_on_section_title" formatted="false">Apare în</string>+ <string name="composer_section_button_show_all" formatted="false">Afișează tot</string>+ <string name="releases_title" formatted="false">Lansări</string>+ <string name="artist_releases_albums" formatted="false">Albume</string>+ <string name="artist_releases_singles" formatted="false">Single-uri și EP-uri</string>+ <string name="latest_release_title" formatted="false">Cea mai recentă lansare</string>+ <string name="artist_subtitle" formatted="false">Artist</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Căutări recente</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Elimină</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasturi</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episoade</string>+ <string name="assisted_curation_search_song" formatted="false">Melodie</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Deconectează-te</string>+ <string name="library_search_text_hint" formatted="false">Caută în Biblioteca ta</string>+ <string name="account_title" formatted="false">Cont</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Artiști urmăriți</string>+ <string name="settings_item_crossfade_title" formatted="false">Trecere progresivă între melodii</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Fișiere locale</string>+ <string name="local_files_empty_section_title" formatted="false">Adaugă propriile fișiere audio în Biblioteca ta</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Ai o melodie sau un podcast personal care nu este pe Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Fișierele tale audio vor apărea aici</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Permite accesul</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Mergi la Setări</string>+ <string name="context_menu_download" formatted="false">Descarcă</string>+ <string name="context_menu_undownload" formatted="false">Elimină descărcarea</string>+ <string name="collection_downloaded" formatted="false">Descărcate</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Descărcată</string>+ <string name="download_badge_downloading_content_description" formatted="false">Se descarcă</string>+ <string name="download_badge_error_content_description" formatted="false">Descărcarea nu a reușit</string>+ <string name="download_notification_downloading" formatted="false">Se descarcă…</string>+ <string name="toast_undownload" formatted="false">Descărcare eliminată.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Elimini din Descărcări?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Nu-l vei putea reda offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Elimină</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Elimină toate descărcările</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Elimini toate melodiile descărcate?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP-uri</string>+ <string name="album_type_compilation" formatted="false">Compilație</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Cele mai relevante</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Melodii</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artiști</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albume</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlisturi</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Șterge filtrul</string>+ <string name="ad_category_title_music" formatted="false">Muzică</string>+ <string name="made_for_you_hub_title" formatted="false">Realizat pentru tine</string>+ <string name="settings_item_app_language_title" formatted="false">Limba aplicației</string>+ <string name="create_menu_item_folder_title" formatted="false">Folder</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Folder nou</string>+ <string name="context_menu_rename_folder" formatted="false">Redenumește folderul</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Numele folderului</string>+ <string name="create_playlist_content_description" formatted="false">Creează un playlist</string>+ <string name="actions_picker_delete" formatted="false">Șterge</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sortează după</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alfabetic</string>+ <string name="your_library_sort_order_creator" formatted="false">Autor</string>+ <string name="your_library_sort_order_custom" formatted="false">Ordine personalizată</string>+ <string name="settings_item_version_title" formatted="false">Versiunea</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Mergi la radioul sursă</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Caută în Melodii apreciate</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Caută în playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Nu am putut găsi „%1$s”</string>+</resources>diff --git a/base/app/src/main/res/values-ru/spotify_plurals.xml b/base/app/src/main/res/values-ru/spotify_plurals.xmlnew file mode 100644index 00000000..8a4a3573--- /dev/null+++ b/base/app/src/main/res/values-ru/spotify_plurals.xml@@ -0,0 +1,28 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d трек</item>+ <item quantity="few">%1$d трека</item>+ <item quantity="many">%1$d треков</item>+ <item quantity="other">%1$d трека</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d сохранение</item>+ <item quantity="few">%1$,d сохранения</item>+ <item quantity="many">%1$,d сохранений</item>+ <item quantity="other">%1$,d сохранения</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s плейлист</item>+ <item quantity="few">%1$s плейлиста</item>+ <item quantity="many">%1$s плейлистов</item>+ <item quantity="other">%1$s плейлиста</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s трек</item>+ <item quantity="few">%1$s трека</item>+ <item quantity="many">%1$s треков</item>+ <item quantity="other">%1$s трека</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ru/spotify_strings.xml b/base/app/src/main/res/values-ru/spotify_strings.xmlnew file mode 100644index 00000000..c7b11699--- /dev/null+++ b/base/app/src/main/res/values-ru/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Добавить в любимые треки</string>+ <string name="collection_liked_songs_title" formatted="false">Любимые треки</string>+ <string name="context_menu_add_to_playlist" formatted="false">Добавить в плейлист</string>+ <string name="context_menu_play_next" formatted="false">Включить следующим</string>+ <string name="context_menu_add_to_queue" formatted="false">Добавить в очередь</string>+ <string name="context_menu_go_to_queue" formatted="false">Очередь</string>+ <string name="context_menu_browse_album" formatted="false">Перейти к альбому</string>+ <string name="context_menu_browse_artist" formatted="false">Перейти к исполнителю</string>+ <string name="context_menu_share" formatted="false">Поделиться</string>+ <string name="context_menu_sleep_timer" formatted="false">Таймер сна</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Отключить таймер</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Когда закончится</string>+ <string name="snackbar_added_to_queue" formatted="false">Добавлено в очередь</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Добавлено в любимые треки</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Удалено из любимых треков</string>+ <string name="content_description_context_menu" formatted="false">Другие варианты</string>+ <string name="close_button_content_description" formatted="false">Закрыть</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Сохранено в плейлистах</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Создать плейлист</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Отмена</string>+ <string name="create_playlist_create_button" formatted="false">Создать</string>+ <string name="lyrics_card_title" formatted="false">Текст</string>+ <string name="lyrics_card_title_preview" formatted="false">Предпросмотр текста</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Показать текст</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Развернуть текст на весь экран</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Поделись текстом</string>+ <string name="lyrics_credential_note" formatted="false">С разрешения: %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Поделиться</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Перевести</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Закрыть текст</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Перевести текст</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Отключить перевод текста</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Вот так да! Мы не знаем текста этой песни.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Текст пока не синхронизирован с музыкой.</string>+ <string name="av_switch_to_video" formatted="false">Переключиться на видео</string>+ <string name="av_switch_to_audio" formatted="false">Переключиться на аудио</string>+ <string name="av_content_desc" formatted="false">Переключиться между аудио и видео</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Главная</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Поиск</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Моя медиатека</string>+ <string name="search_header_field_hint" formatted="false">Что хочешь послушать?</string>+ <string name="filter_chip_all_label" formatted="false">Все</string>+ <string name="recents_content_filter_music" formatted="false">Музыка</string>+ <string name="ad_category_title_podcasts" formatted="false">Подкасты</string>+ <string name="audiobooks_title" formatted="false">Аудиокниги</string>+ <string name="artist_popular_tracks" formatted="false">Популярное</string>+ <string name="curation_button_follow_state_text" formatted="false">Подписаться</string>+ <string name="curation_button_following_state_text" formatted="false">Подписки</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Исполнитель</string>+ <string name="connect_phone_is_self" formatted="false">Этот телефон</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Показывать короткие зацикленные заставки на экране «Сейчас играет».</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Не сейчас</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Обновить</string>+ <string name="context_type_description_play_queue" formatted="false">Из очереди</string>+ <string name="context_type_description_collection_your_library" formatted="false">Из медиатеки</string>+ <string name="context_type_description_playlist" formatted="false">Из плейлиста</string>+ <string name="context_type_description_album" formatted="false">Из альбома</string>+ <string name="context_type_description_artist" formatted="false">Из треков исполнителя</string>+ <string name="context_type_description_show" formatted="false">Из подкаста</string>+ <string name="context_type_description_search" formatted="false">Из поиска</string>+ <string name="default_notification_channel_name" formatted="false">Играет сейчас</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Устройства</string>+ <string name="action_share_label" formatted="false">Поделиться</string>+ <string name="action_queue_label" formatted="false">Очередь</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 час</string>+ <string name="curation_actions_edit_button_title" formatted="false">Изменить</string>+ <string name="content_description_pause_button" formatted="false">Поставить на паузу</string>+ <string name="content_description_play_button" formatted="false">Слушать</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Перемешать</string>+ <string name="np_content_desc_repeat" formatted="false">Повторять</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Таймер сна</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Удалить</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Переместить</string>+ <string name="bottom_actions_close" formatted="false">Закрыть</string>+ <string name="add_to_queue_action_content_description" formatted="false">Добавить в очередь</string>+ <string name="curation_button_saved_text" formatted="false">Сохранено</string>+ <string name="np_content_desc_prev" formatted="false">Назад</string>+ <string name="np_content_desc_next" formatted="false">Далее</string>+ <string name="accessibility_navigate_back" formatted="false">Назад</string>+ <string name="monthly_listeners_text" formatted="false">Слушателей за месяц: %1$s</string>+ <string name="profile_bio_show_less" formatted="false">Свернуть</string>+ <string name="audiobook_series_see_more_button" formatted="false">Еще</string>+ <string name="popular_releases_section_title" formatted="false">Популярные релизы</string>+ <string name="creator_biography_section_title" formatted="false">Инфо</string>+ <string name="fans_also_like_section_title" formatted="false">Поклонникам также нравится</string>+ <string name="appears_on_section_title" formatted="false">Еще с этим исполнителем</string>+ <string name="composer_section_button_show_all" formatted="false">Показать все</string>+ <string name="releases_title" formatted="false">Релизы</string>+ <string name="artist_releases_albums" formatted="false">Альбомы</string>+ <string name="artist_releases_singles" formatted="false">Синглы и мини-альбомы</string>+ <string name="latest_release_title" formatted="false">Последний релиз</string>+ <string name="artist_subtitle" formatted="false">Исполнитель</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">История поиска</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Очистить</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Подкасты</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Выпуски</string>+ <string name="assisted_curation_search_song" formatted="false">Трек</string>+ <string name="album" formatted="false">Альбом</string>+ <string name="album_type_podcast" formatted="false">Подкаст</string>+ <string name="recently_played_user_profile" formatted="false">Профиль</string>+ <string name="connect_device_menu_logout" formatted="false">Выйти</string>+ <string name="library_search_text_hint" formatted="false">Поиск в медиатеке</string>+ <string name="account_title" formatted="false">Аккаунт</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Подписки на исполнителей</string>+ <string name="settings_item_crossfade_title" formatted="false">Плавный переход между треками</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d сек.</string>+ <string name="local_files_title" formatted="false">Добавленные файлы</string>+ <string name="local_files_empty_section_title" formatted="false">Добавь файлы со своего устройства в медиатеку</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Хочешь добавить трек или подкаст, которого нет в Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Аудиофайлы появятся здесь</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Разрешить доступ</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Перейти в настройки</string>+ <string name="context_menu_download" formatted="false">Скачать</string>+ <string name="context_menu_undownload" formatted="false">Удалить скачанный файл</string>+ <string name="collection_downloaded" formatted="false">Скачанные</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Скачивание завершено</string>+ <string name="download_badge_downloading_content_description" formatted="false">Выполняется скачивание</string>+ <string name="download_badge_error_content_description" formatted="false">Ошибка скачивания</string>+ <string name="download_notification_downloading" formatted="false">Скачивание…</string>+ <string name="toast_undownload" formatted="false">Удалено из скачанного</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Удалить из скачанных?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Ты больше не сможешь слушать этот плейлист офлайн.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Удалить</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Удалить весь скачанный контент</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Удалить весь скачанный контент?</string>+ <string name="album_type_album" formatted="false">Альбом</string>+ <string name="album_type_single" formatted="false">Сингл</string>+ <string name="album_type_ep" formatted="false">Мини-альбом</string>+ <string name="album_type_compilation" formatted="false">Сборник</string>+ <string name="assisted_curation_search_playlist" formatted="false">Плейлист</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Топ</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Треки</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Исполнители</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Альбомы</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Плейлисты</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Удалить фильтр</string>+ <string name="ad_category_title_music" formatted="false">Музыка</string>+ <string name="made_for_you_hub_title" formatted="false">Для тебя</string>+ <string name="settings_item_app_language_title" formatted="false">Язык приложения</string>+ <string name="create_menu_item_folder_title" formatted="false">Папка</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Новая папка</string>+ <string name="context_menu_rename_folder" formatted="false">Переименовать папку</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Название папки</string>+ <string name="create_playlist_content_description" formatted="false">Создать плейлист</string>+ <string name="actions_picker_delete" formatted="false">Удалить</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Сортировка</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">По алфавиту</string>+ <string name="your_library_sort_order_creator" formatted="false">По автору</string>+ <string name="your_library_sort_order_custom" formatted="false">В своем порядке</string>+ <string name="settings_item_version_title" formatted="false">Версия</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Перейти к радио по треку</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Поиск по любимым трекам</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Поиск в плейлисте</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">По запросу «%1$s» ничего нет</string>+</resources>diff --git a/base/app/src/main/res/values-ru/strings.xml b/base/app/src/main/res/values-ru/strings.xmlnew file mode 100644index 00000000..9bab7c38--- /dev/null+++ b/base/app/src/main/res/values-ru/strings.xml@@ -0,0 +1,35 @@+<?xml version="1.0" encoding="utf-8"?>+<resources>+ <string name="app_name">Myspoti</string>+ <string name="aa_playlists">Плейлисты</string>+ <string name="aa_albums">Альбомы</string>+ <string name="aa_artists">Исполнители</string>+ <string name="aa_podcasts">Подкасты</string>+ <string name="settings_amoled_theme">Тема AMOLED</string>+ <string name="settings_amoled_theme_subtitle">Чистый чёрный фон для экономии заряда</string>+ <string name="settings_lyrics_style_spotify_default">Стандартный Spotify</string>+ <string name="settings_lyrics_style_fullscreen">На весь экран (цвета альбома)</string>+ <string name="settings_lyrics_style_compact">Компактный</string>+ <string name="settings_lyrics_style_karaoke">Караоке</string>+ <string name="settings_lyrics_style_bold">Крупный жирный</string>+ <string name="main_update_available">Доступно новое обновление</string>+ <string name="notif_channel_media_name">Воспроизведение медиа</string>+ <string name="notif_channel_media_description">Управление воспроизведением Myspoti</string>+ <string name="notif_action_previous">Предыдущий</string>+ <string name="notif_action_next">Следующий</string>+ <string name="notif_action_play">Воспроизвести</string>+ <string name="notif_action_pause">Пауза</string>+ <string name="notif_shuffle_enable">Включить перемешивание</string>+ <string name="notif_shuffle_disable">Выключить перемешивание</string>+ <string name="notif_shuffle_disable_smart">Выключить умное перемешивание</string>+ <string name="notif_action_like">Нравится</string>+ <string name="notif_action_unlike">Убрать «Нравится»</string>+ <string name="notif_unknown_name">Неизвестно</string>+ <string name="notif_by_artist">от %1$s</string>+ <string name="notif_repeat_disable">Выключить повтор</string>+ <string name="notif_repeat_disable_one">Выключить повтор одного трека</string>+ <string name="notif_repeat_enable">Включить повтор</string>+ <string name="bridge_player_unlocked">Плеер разблокирован</string>+ <string name="bridge_reloading">Перезагрузка…</string>+ <string name="service_disabled_message">Сервис не включён</string>+</resources>diff --git a/base/app/src/main/res/values-sk/spotify_plurals.xml b/base/app/src/main/res/values-sk/spotify_plurals.xmlnew file mode 100644index 00000000..8b883d36--- /dev/null+++ b/base/app/src/main/res/values-sk/spotify_plurals.xml@@ -0,0 +1,24 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d skladba</item>+ <item quantity="few">%1$d skladby</item>+ <item quantity="other">%1$d skladieb</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d uloženie</item>+ <item quantity="few">%1$,d uloženia</item>+ <item quantity="other">%1$,d uložení</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="few">%1$s playlisty</item>+ <item quantity="other">%1$s playlistov</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s skladba</item>+ <item quantity="few">%1$s skladby</item>+ <item quantity="other">%1$s skladieb</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-sk/spotify_strings.xml b/base/app/src/main/res/values-sk/spotify_strings.xmlnew file mode 100644index 00000000..46ba5042--- /dev/null+++ b/base/app/src/main/res/values-sk/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Pridať medzi obľúbené skladby</string>+ <string name="collection_liked_songs_title" formatted="false">Obľúbené skladby</string>+ <string name="context_menu_add_to_playlist" formatted="false">Pridať do playlistu</string>+ <string name="context_menu_play_next" formatted="false">Prehrať ďalšiu</string>+ <string name="context_menu_add_to_queue" formatted="false">Pridať do zoznamu</string>+ <string name="context_menu_go_to_queue" formatted="false">Otvoriť zoznam</string>+ <string name="context_menu_browse_album" formatted="false">Prejsť na album</string>+ <string name="context_menu_browse_artist" formatted="false">Prejsť na interpreta</string>+ <string name="context_menu_share" formatted="false">Zdieľať</string>+ <string name="context_menu_sleep_timer" formatted="false">Časovač vypnutia</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Vypnúť časovač</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Koniec nahrávky</string>+ <string name="snackbar_added_to_queue" formatted="false">Pridané do zoznamu</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Pridané medzi obľúbené skladby.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Odstránené z obľúbených skladieb.</string>+ <string name="content_description_context_menu" formatted="false">Viac možností</string>+ <string name="close_button_content_description" formatted="false">Zavrieť</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Uložené do</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nový playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Zrušiť</string>+ <string name="create_playlist_create_button" formatted="false">Vytvoriť</string>+ <string name="lyrics_card_title" formatted="false">Text</string>+ <string name="lyrics_card_title_preview" formatted="false">Ukážka textu</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Zobraziť text</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Otvoriť text na celej obrazovke</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Zdieľať text</string>+ <string name="lyrics_credential_note" formatted="false">Text ti prináša: %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Zdieľať</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Preložiť</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Zavrieť text</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Preložiť text</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">zastavíš preklad textu</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Text tejto skladby zatiaľ nevieme.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Tento text zatiaľ nie je synchronizovaný so zvukom.</string>+ <string name="av_switch_to_video" formatted="false">Prepnúť na video</string>+ <string name="av_switch_to_audio" formatted="false">Prepnúť na zvuk</string>+ <string name="av_content_desc" formatted="false">Prepnúť medzi zvukom a videom</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Domov</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Hľadať</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Tvoja knižnica</string>+ <string name="search_header_field_hint" formatted="false">Čo chceš počúvať?</string>+ <string name="filter_chip_all_label" formatted="false">Všetky</string>+ <string name="recents_content_filter_music" formatted="false">Hudba</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasty</string>+ <string name="audiobooks_title" formatted="false">Audioknihy</string>+ <string name="artist_popular_tracks" formatted="false">Obľúbené</string>+ <string name="curation_button_follow_state_text" formatted="false">Sledovať</string>+ <string name="curation_button_following_state_text" formatted="false">Sleduješ</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Interpret</string>+ <string name="connect_phone_is_self" formatted="false">Tento telefón</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Krátke videoslučky pri prehrávaní skladby.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Teraz nie</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Aktualizovať</string>+ <string name="context_type_description_play_queue" formatted="false">Prehrávanie zo zoznamu</string>+ <string name="context_type_description_collection_your_library" formatted="false">Prehrávanie z tvojej knižnice</string>+ <string name="context_type_description_playlist" formatted="false">Prehrávanie z playlistu</string>+ <string name="context_type_description_album" formatted="false">Prehrávanie z albumu</string>+ <string name="context_type_description_artist" formatted="false">Prehrávanie od interpreta</string>+ <string name="context_type_description_show" formatted="false">Prehrávanie z podcastu</string>+ <string name="context_type_description_search" formatted="false">Prehrávanie z hľadania</string>+ <string name="default_notification_channel_name" formatted="false">Prehráva sa</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Zariadenia</string>+ <string name="action_share_label" formatted="false">Zdieľať</string>+ <string name="action_queue_label" formatted="false">Zoznam</string>+ <string name="mute_chat_duration_one_hour" formatted="false">Na 1 hodinu</string>+ <string name="curation_actions_edit_button_title" formatted="false">Upraviť</string>+ <string name="content_description_pause_button" formatted="false">Pozastaviť</string>+ <string name="content_description_play_button" formatted="false">Prehrať</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Náhodné poradie</string>+ <string name="np_content_desc_repeat" formatted="false">Opakovať</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Časovač vypnutia</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Odstrániť</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Presunúť</string>+ <string name="bottom_actions_close" formatted="false">Zavrieť</string>+ <string name="add_to_queue_action_content_description" formatted="false">Pridať do zoznamu</string>+ <string name="curation_button_saved_text" formatted="false">Uložené</string>+ <string name="np_content_desc_prev" formatted="false">Predchádzajúce</string>+ <string name="np_content_desc_next" formatted="false">Ďalej</string>+ <string name="accessibility_navigate_back" formatted="false">Späť</string>+ <string name="monthly_listeners_text" formatted="false">Poslucháči mesačne: %1$s</string>+ <string name="profile_bio_show_less" formatted="false">Zobraziť menej</string>+ <string name="audiobook_series_see_more_button" formatted="false">Zobraziť viac</string>+ <string name="popular_releases_section_title" formatted="false">Obľúbené nahrávky</string>+ <string name="creator_biography_section_title" formatted="false">Informácie</string>+ <string name="fans_also_like_section_title" formatted="false">Fanúšikom sa páči aj</string>+ <string name="appears_on_section_title" formatted="false">Objavuje sa aj tu</string>+ <string name="composer_section_button_show_all" formatted="false">Zobraziť všetko</string>+ <string name="releases_title" formatted="false">Nahrávky</string>+ <string name="artist_releases_albums" formatted="false">Albumy</string>+ <string name="artist_releases_singles" formatted="false">Single a platne</string>+ <string name="latest_release_title" formatted="false">Najnovšia nahrávka</string>+ <string name="artist_subtitle" formatted="false">Interpret</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Nedávne vyhľadávania</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Vymazať</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasty</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Epizódy</string>+ <string name="assisted_curation_search_song" formatted="false">Skladba</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Odhlásiť sa</string>+ <string name="library_search_text_hint" formatted="false">Hľadaj vo svojej knižnici</string>+ <string name="account_title" formatted="false">Konto</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Sledovaní interpreti</string>+ <string name="settings_item_crossfade_title" formatted="false">Prelínanie</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Lokálne súbory</string>+ <string name="local_files_empty_section_title" formatted="false">Pridaj si do knižnice vlastné zvukové súbory</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Máš skladbu alebo osobný podcast, ktoré nie sú na Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Tu sa zobrazia tvoje zvukové súbory</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Povoliť prístup</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Prejsť do nastavení</string>+ <string name="context_menu_download" formatted="false">Stiahnuť</string>+ <string name="context_menu_undownload" formatted="false">Odstrániť stiahnuté</string>+ <string name="collection_downloaded" formatted="false">Stiahnuté</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Stiahnuté</string>+ <string name="download_badge_downloading_content_description" formatted="false">Sťahuje sa</string>+ <string name="download_badge_error_content_description" formatted="false">Sťahovanie zlyhalo</string>+ <string name="download_notification_downloading" formatted="false">Sťahuje sa…</string>+ <string name="toast_undownload" formatted="false">Stiahnutá položka bola odstránená.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Odstrániť zo stiahnutých?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Tento playlist nebudeš môcť prehrávať offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Odstrániť</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Odstrániť všetky stiahnuté skladby</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Odstrániť všetky stiahnuté súbory?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Singel</string>+ <string name="album_type_ep" formatted="false">Platňa</string>+ <string name="album_type_compilation" formatted="false">Kompilácia</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Najlepšie výsledky</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Skladby</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Interpreti</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albumy</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlisty</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Vymazať filter</string>+ <string name="ad_category_title_music" formatted="false">Hudba</string>+ <string name="made_for_you_hub_title" formatted="false">Len pre teba</string>+ <string name="settings_item_app_language_title" formatted="false">Jazyk apky</string>+ <string name="create_menu_item_folder_title" formatted="false">Priečinok</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nový priečinok</string>+ <string name="context_menu_rename_folder" formatted="false">Premenovať priečinok</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Názov priečinka</string>+ <string name="create_playlist_content_description" formatted="false">Vytvoriť playlist</string>+ <string name="actions_picker_delete" formatted="false">Odstrániť</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Zoradiť podľa</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Podľa abecedy</string>+ <string name="your_library_sort_order_creator" formatted="false">Autor</string>+ <string name="your_library_sort_order_custom" formatted="false">Vlastné poradie</string>+ <string name="settings_item_version_title" formatted="false">Verzia</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Prejsť na rádio skladby</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Nájsť medzi obľúbenými skladbami</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Nájsť v playliste</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Výraz „%1$s“ sa nenašiel</string>+</resources>diff --git a/base/app/src/main/res/values-sl/spotify_plurals.xml b/base/app/src/main/res/values-sl/spotify_plurals.xmlnew file mode 100644index 00000000..9ece4df0--- /dev/null+++ b/base/app/src/main/res/values-sl/spotify_plurals.xml@@ -0,0 +1,28 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d skladba</item>+ <item quantity="two">%1$d skladbi</item>+ <item quantity="few">%1$d skladbe</item>+ <item quantity="other">%1$d skladb</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d-krat shranjeno</item>+ <item quantity="two">%1$,d-krat shranjeno</item>+ <item quantity="few">%1$,d-krat shranjeno</item>+ <item quantity="other">%1$,d-krat shranjeno</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s seznam predvajanja</item>+ <item quantity="two">%1$s seznama predvajanja</item>+ <item quantity="few">%1$s seznami predvajanja</item>+ <item quantity="other">%1$s seznamov predvajanja</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s skladba</item>+ <item quantity="two">%1$s skladbi</item>+ <item quantity="few">%1$s skladbe</item>+ <item quantity="other">%1$s skladb</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-sl/spotify_strings.xml b/base/app/src/main/res/values-sl/spotify_strings.xmlnew file mode 100644index 00000000..2ceffa98--- /dev/null+++ b/base/app/src/main/res/values-sl/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Dodaj med všečkane skladbe</string>+ <string name="collection_liked_songs_title" formatted="false">Všečkane skladbe</string>+ <string name="context_menu_add_to_playlist" formatted="false">Dodaj na seznam predvajanja</string>+ <string name="context_menu_play_next" formatted="false">Predvajaj naslednjo</string>+ <string name="context_menu_add_to_queue" formatted="false">Dodaj v čakalno vrsto</string>+ <string name="context_menu_go_to_queue" formatted="false">Odpri čakalno vrsto</string>+ <string name="context_menu_browse_album" formatted="false">Pojdi na album</string>+ <string name="context_menu_browse_artist" formatted="false">Pojdi na izvajalca</string>+ <string name="context_menu_share" formatted="false">Deli</string>+ <string name="context_menu_sleep_timer" formatted="false">Časovnik izklopa</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Izklopi časovnik</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Ob koncu skladbe</string>+ <string name="snackbar_added_to_queue" formatted="false">Dodano v čakalno vrsto.</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Dodano všečkanim skladbam.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Odstranjeno iz všečkanih skladb.</string>+ <string name="content_description_context_menu" formatted="false">Več možnosti</string>+ <string name="close_button_content_description" formatted="false">Zapri</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Shranjeno v</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nov seznam predvajanja</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Prekliči</string>+ <string name="create_playlist_create_button" formatted="false">Ustvari</string>+ <string name="lyrics_card_title" formatted="false">Besedilo</string>+ <string name="lyrics_card_title_preview" formatted="false">Predogled besedila</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Pokaži besedilo</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Odpri celozaslonsko besedilo</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Deli besedilo</string>+ <string name="lyrics_credential_note" formatted="false">Besedila zagotavlja %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Deli</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Prevedi</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Zapri besedilo</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Prevedi besedilo</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Nehaj prevajati besedilo</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Tudi mi ne poznamo besedila te skladbe.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Ta besedila še niso časovno sinhronizirana.</string>+ <string name="av_switch_to_video" formatted="false">Preklopi na videoposnetek</string>+ <string name="av_switch_to_audio" formatted="false">Preklopi na zvok</string>+ <string name="av_content_desc" formatted="false">Preklop med zvokom in videoposnetkom</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Domov</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Iskanje</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Moja zbirka</string>+ <string name="search_header_field_hint" formatted="false">Kaj želiš poslušati?</string>+ <string name="filter_chip_all_label" formatted="false">Vse</string>+ <string name="recents_content_filter_music" formatted="false">Glasba</string>+ <string name="ad_category_title_podcasts" formatted="false">Podkasti</string>+ <string name="audiobooks_title" formatted="false">Zvočne knjige</string>+ <string name="artist_popular_tracks" formatted="false">Priljubljeno</string>+ <string name="curation_button_follow_state_text" formatted="false">Spremljaj</string>+ <string name="curation_button_following_state_text" formatted="false">Spremljaš</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Izvajalec</string>+ <string name="connect_phone_is_self" formatted="false">Ta telefon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Kratke vizualne vsebine v zanki med predvajanjem skladbe.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Ne zdaj</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Posodobi</string>+ <string name="context_type_description_play_queue" formatted="false">Predvajanje iz predvajaj čakalno vrsto</string>+ <string name="context_type_description_collection_your_library" formatted="false">Predvajanje iz tvoje zbirke</string>+ <string name="context_type_description_playlist" formatted="false">Predvajanje iz seznama predvajanja</string>+ <string name="context_type_description_album" formatted="false">Predvajanje iz albuma</string>+ <string name="context_type_description_artist" formatted="false">Predvajanje iz izvajalca</string>+ <string name="context_type_description_show" formatted="false">Predvajanje iz podkasta</string>+ <string name="context_type_description_search" formatted="false">Predvajanje iz iskanja</string>+ <string name="default_notification_channel_name" formatted="false">Zdaj se predvaja</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Naprave</string>+ <string name="action_share_label" formatted="false">Deli</string>+ <string name="action_queue_label" formatted="false">Čakalna vrsta</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 ura</string>+ <string name="curation_actions_edit_button_title" formatted="false">Uredi</string>+ <string name="content_description_pause_button" formatted="false">Ustavi</string>+ <string name="content_description_play_button" formatted="false">Predvajaj</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Naključno predvajanje</string>+ <string name="np_content_desc_repeat" formatted="false">Ponovi</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Časovnik izklopa</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Odstrani</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Premakni</string>+ <string name="bottom_actions_close" formatted="false">Zapri</string>+ <string name="add_to_queue_action_content_description" formatted="false">Dodaj v čakalno vrsto</string>+ <string name="curation_button_saved_text" formatted="false">Shranjeno</string>+ <string name="np_content_desc_prev" formatted="false">Prejšnja</string>+ <string name="np_content_desc_next" formatted="false">Naprej</string>+ <string name="accessibility_navigate_back" formatted="false">Nazaj</string>+ <string name="monthly_listeners_text" formatted="false">Št. mesečnih poslušalcev: %1$s</string>+ <string name="profile_bio_show_less" formatted="false">Pokaži manj</string>+ <string name="audiobook_series_see_more_button" formatted="false">Pokaži več</string>+ <string name="popular_releases_section_title" formatted="false">Priljubljene izdaje</string>+ <string name="creator_biography_section_title" formatted="false">Več informacij</string>+ <string name="fans_also_like_section_title" formatted="false">Ljubiteljem je všeč tudi</string>+ <string name="appears_on_section_title" formatted="false">Najdeš na</string>+ <string name="composer_section_button_show_all" formatted="false">Prikaži vse</string>+ <string name="releases_title" formatted="false">Izdaje</string>+ <string name="artist_releases_albums" formatted="false">Albumi</string>+ <string name="artist_releases_singles" formatted="false">Singli in EP-ji</string>+ <string name="latest_release_title" formatted="false">Najnovejša izdaja</string>+ <string name="artist_subtitle" formatted="false">Izvajalec</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Nedavna iskanja</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Počisti</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podkasti</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Epizode</string>+ <string name="assisted_curation_search_song" formatted="false">Skladba</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podkast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Odjava</string>+ <string name="library_search_text_hint" formatted="false">Preišči svojo zbirko</string>+ <string name="account_title" formatted="false">Račun</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Spremljani izvajalci</string>+ <string name="settings_item_crossfade_title" formatted="false">Postopen prehod</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Lokalne datoteke</string>+ <string name="local_files_empty_section_title" formatted="false">Dodaj lastne zvočne datoteke v svojo zbirko</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Imaš skladbo ali osebni podkast, ki ni na Spotifyu?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Tvoje zvočne datoteke bodo prikazane tukaj</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Omogoči dostop</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Pojdi na nastavitve</string>+ <string name="context_menu_download" formatted="false">Prenos</string>+ <string name="context_menu_undownload" formatted="false">Odstrani prenos</string>+ <string name="collection_downloaded" formatted="false">Preneseno</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Preneseno</string>+ <string name="download_badge_downloading_content_description" formatted="false">Prenašanje</string>+ <string name="download_badge_error_content_description" formatted="false">Prenos ni uspel</string>+ <string name="download_notification_downloading" formatted="false">Prenašanje …</string>+ <string name="toast_undownload" formatted="false">Prenos je odstranjen.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Želiš odstraniti iz prenosov?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Tega ne bo mogoče predvajati brez povezave.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Odstrani</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Odstrani vse prenose</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Želiš odstraniti vse prenose?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Singel</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Kompilacija</string>+ <string name="assisted_curation_search_playlist" formatted="false">Seznam predvajanja</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Najbolj priljubljeno</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Skladbe</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Izvajalci</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albumi</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Seznami predvajanja</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Počisti filter</string>+ <string name="ad_category_title_music" formatted="false">Glasba</string>+ <string name="made_for_you_hub_title" formatted="false">Izbrano zate</string>+ <string name="settings_item_app_language_title" formatted="false">Jezik aplikacije</string>+ <string name="create_menu_item_folder_title" formatted="false">Mapa</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Nova mapa</string>+ <string name="context_menu_rename_folder" formatted="false">Preimenuj mapo</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Ime mape</string>+ <string name="create_playlist_content_description" formatted="false">Ustvari seznam predvajanja</string>+ <string name="actions_picker_delete" formatted="false">Izbriši</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Razvrsti po</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Po abecedi</string>+ <string name="your_library_sort_order_creator" formatted="false">Ustvarjalec</string>+ <string name="your_library_sort_order_custom" formatted="false">Zaporedje po meri</string>+ <string name="settings_item_version_title" formatted="false">Različica</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Odpri radio skladbe</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Poišči v všečkanih skladbah</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Poišči na seznamu predvajanja</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">»%1$s« ni mogoče najti</string>+</resources>diff --git a/base/app/src/main/res/values-sr/spotify_plurals.xml b/base/app/src/main/res/values-sr/spotify_plurals.xmlnew file mode 100644index 00000000..d483ebba--- /dev/null+++ b/base/app/src/main/res/values-sr/spotify_plurals.xml@@ -0,0 +1,24 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d pesma</item>+ <item quantity="few">%1$d pesme</item>+ <item quantity="other">%1$d pesama</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d čuvanje</item>+ <item quantity="few">%1$,d čuvanja</item>+ <item quantity="other">%1$,d čuvanja</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s plejlista</item>+ <item quantity="few">%1$s plejliste</item>+ <item quantity="other">%1$s plejlista</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s pesma</item>+ <item quantity="few">%1$s pesme</item>+ <item quantity="other">%1$s pesama</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-sr/spotify_strings.xml b/base/app/src/main/res/values-sr/spotify_strings.xmlnew file mode 100644index 00000000..1b51f08d--- /dev/null+++ b/base/app/src/main/res/values-sr/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Dodaj u lajkovane pesme</string>+ <string name="collection_liked_songs_title" formatted="false">Lajkovane pesme</string>+ <string name="context_menu_add_to_playlist" formatted="false">Dodaj na plejlistu</string>+ <string name="context_menu_play_next" formatted="false">Pusti sledeće</string>+ <string name="context_menu_add_to_queue" formatted="false">Dodaj u redosled</string>+ <string name="context_menu_go_to_queue" formatted="false">Otvori redosled</string>+ <string name="context_menu_browse_album" formatted="false">Idite na album</string>+ <string name="context_menu_browse_artist" formatted="false">Idite na izvođača</string>+ <string name="context_menu_share" formatted="false">Deli</string>+ <string name="context_menu_sleep_timer" formatted="false">Tajmer za spavanje</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Isključi tajmer</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Kraj numere</string>+ <string name="snackbar_added_to_queue" formatted="false">Dodato je u redosled</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Dodali ste u lajkovane pesme.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Uklonili ste iz lajkovanih pesama.</string>+ <string name="content_description_context_menu" formatted="false">Još opcija</string>+ <string name="close_button_content_description" formatted="false">Zatvori</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Sačuvano u</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Nova plejlista</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Otkaži</string>+ <string name="create_playlist_create_button" formatted="false">Napravi</string>+ <string name="lyrics_card_title" formatted="false">Tekst</string>+ <string name="lyrics_card_title_preview" formatted="false">Pregled teksta</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Prikaži tekst</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Otvorite tekst preko celog ekrana</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Delite tekst</string>+ <string name="lyrics_credential_note" formatted="false">Autor teksta %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Deli</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Prevedite</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Zatvori tekst</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Prevedite tekst</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">prestali da prevodite tekst</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hm. Ne znamo tekst za ovu pesmu.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Ovaj tekst još nije vremenski sinhronizovan.</string>+ <string name="av_switch_to_video" formatted="false">Pređi na video sadržaj</string>+ <string name="av_switch_to_audio" formatted="false">Pređi na audio sadržaj</string>+ <string name="av_content_desc" formatted="false">Pređite sa videa na audio i obratno</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Početna</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Pretraga</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Moja biblioteka</string>+ <string name="search_header_field_hint" formatted="false">Šta želite da slušate?</string>+ <string name="filter_chip_all_label" formatted="false">Sve</string>+ <string name="recents_content_filter_music" formatted="false">Muzika</string>+ <string name="ad_category_title_podcasts" formatted="false">Podkasti</string>+ <string name="audiobooks_title" formatted="false">Audio-knjige</string>+ <string name="artist_popular_tracks" formatted="false">Popularno</string>+ <string name="curation_button_follow_state_text" formatted="false">Zaprati</string>+ <string name="curation_button_following_state_text" formatted="false">Pratite</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Izvođač</string>+ <string name="connect_phone_is_self" formatted="false">ovom telefonu</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Kratki vizuelni elementi u petlji kada se pesma reprodukuje.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Ne sada</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Ažurirajte</string>+ <string name="context_type_description_play_queue" formatted="false">Pušta se iz redosleda puštanja</string>+ <string name="context_type_description_collection_your_library" formatted="false">Pušta se iz vaše biblioteke</string>+ <string name="context_type_description_playlist" formatted="false">Pušta se iz plejliste</string>+ <string name="context_type_description_album" formatted="false">Pušta se iz albuma</string>+ <string name="context_type_description_artist" formatted="false">Pušta se iz izvođača</string>+ <string name="context_type_description_show" formatted="false">Pušta se iz podkasta</string>+ <string name="context_type_description_search" formatted="false">Pušta se iz pretrage</string>+ <string name="default_notification_channel_name" formatted="false">Тренутно свира</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Уређаји</string>+ <string name="action_share_label" formatted="false">Delite</string>+ <string name="action_queue_label" formatted="false">Redosled</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 sat</string>+ <string name="curation_actions_edit_button_title" formatted="false">Izmeni</string>+ <string name="content_description_pause_button" formatted="false">Pauzirajte</string>+ <string name="content_description_play_button" formatted="false">Pustite</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Pusti nasumično</string>+ <string name="np_content_desc_repeat" formatted="false">Ponovi</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Tajmer za spavanje</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Uklonite</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Premesti</string>+ <string name="bottom_actions_close" formatted="false">Zatvorite</string>+ <string name="add_to_queue_action_content_description" formatted="false">Dodaj u redosled</string>+ <string name="curation_button_saved_text" formatted="false">Sačuvano</string>+ <string name="np_content_desc_prev" formatted="false">Prethodno</string>+ <string name="np_content_desc_next" formatted="false">Sledeće</string>+ <string name="accessibility_navigate_back" formatted="false">Nazad</string>+ <string name="monthly_listeners_text" formatted="false">Mesečnih slušalaca: %1$s</string>+ <string name="profile_bio_show_less" formatted="false">Prikaži manje</string>+ <string name="audiobook_series_see_more_button" formatted="false">Prikaži više</string>+ <string name="popular_releases_section_title" formatted="false">Popularna izdanja</string>+ <string name="creator_biography_section_title" formatted="false">Osnovni podaci</string>+ <string name="fans_also_like_section_title" formatted="false">Fanovima se sviđa i</string>+ <string name="appears_on_section_title" formatted="false">Pojavljuje se na</string>+ <string name="composer_section_button_show_all" formatted="false">Prikaži sve</string>+ <string name="releases_title" formatted="false">Izdanja</string>+ <string name="artist_releases_albums" formatted="false">Albumi</string>+ <string name="artist_releases_singles" formatted="false">Singlovi i EP-ovi</string>+ <string name="latest_release_title" formatted="false">Najnovije izdanje</string>+ <string name="artist_subtitle" formatted="false">Izvođač</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Nedavne pretrage</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Obriši</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podkasti</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Epizode</string>+ <string name="assisted_curation_search_song" formatted="false">Pesma</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podkast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Odjavite se</string>+ <string name="library_search_text_hint" formatted="false">Pretražite svoju biblioteku</string>+ <string name="account_title" formatted="false">Nalog</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Izvođači koje pratite</string>+ <string name="settings_item_crossfade_title" formatted="false">Postepen prelaz</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d sek</string>+ <string name="local_files_title" formatted="false">Lokalni fajlovi</string>+ <string name="local_files_empty_section_title" formatted="false">Dodajte svoje audio fajlove u Moju biblioteku</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Imate pesmu ili lični podkast koji nisu u usluzi Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Audio fajlovi će se prikazati ovde</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Daj pristup</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Otvori podešavanja</string>+ <string name="context_menu_download" formatted="false">Preuzmi</string>+ <string name="context_menu_undownload" formatted="false">Ukloni preuzimanje</string>+ <string name="collection_downloaded" formatted="false">Preuzeto je</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Preuzeto je</string>+ <string name="download_badge_downloading_content_description" formatted="false">Preuzima se</string>+ <string name="download_badge_error_content_description" formatted="false">Preuzimanje nije uspelo</string>+ <string name="download_notification_downloading" formatted="false">Preuzima se…</string>+ <string name="toast_undownload" formatted="false">Uklonili ste preuzimanje.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Želite li da uklonite iz preuzimanja?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Nećete moći da pustite ovo oflajn.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Ukloni</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Ukloni sva preuzimanja</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Želite li da uklonite sva preuzimanja?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Singl</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Kompilacija</string>+ <string name="assisted_curation_search_playlist" formatted="false">Plejlista</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Najbolje</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Pesme</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Izvođači</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albumi</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Plejliste</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Obrišite filter</string>+ <string name="ad_category_title_music" formatted="false">Muzika</string>+ <string name="made_for_you_hub_title" formatted="false">Napravljeno za vas</string>+ <string name="settings_item_app_language_title" formatted="false">Jezik aplikacije</string>+ <string name="create_menu_item_folder_title" formatted="false">Folder</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Novi folder</string>+ <string name="context_menu_rename_folder" formatted="false">Preimenujte folder</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Naziv foldera</string>+ <string name="create_playlist_content_description" formatted="false">Napravi plejlistu</string>+ <string name="actions_picker_delete" formatted="false">Izbriši</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sortirajte prema:</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Abecedno</string>+ <string name="your_library_sort_order_creator" formatted="false">Autor</string>+ <string name="your_library_sort_order_custom" formatted="false">Prilagođen raspored</string>+ <string name="settings_item_version_title" formatted="false">Verzija</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Idi na radio pesme</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Potražite u lajkovanim pesmama</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Pronađite na plejlisti</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Nismo uspeli da pronađemo „%1$s“</string>+</resources>diff --git a/base/app/src/main/res/values-sv/spotify_plurals.xml b/base/app/src/main/res/values-sv/spotify_plurals.xmlnew file mode 100644index 00000000..fbb1e578--- /dev/null+++ b/base/app/src/main/res/values-sv/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d låt</item>+ <item quantity="other">%1$d låtar</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d sparning</item>+ <item quantity="other">%1$,d sparningar</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s spellista</item>+ <item quantity="other">%1$s spellistor</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s låt</item>+ <item quantity="other">%1$s låtar</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-sv/spotify_strings.xml b/base/app/src/main/res/values-sv/spotify_strings.xmlnew file mode 100644index 00000000..350eccb8--- /dev/null+++ b/base/app/src/main/res/values-sv/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Lägg till i Gillade låtar</string>+ <string name="collection_liked_songs_title" formatted="false">Gillade låtar</string>+ <string name="context_menu_add_to_playlist" formatted="false">Lägg till i spellista</string>+ <string name="context_menu_play_next" formatted="false">Spela upp härnäst</string>+ <string name="context_menu_add_to_queue" formatted="false">Lägg till i kön</string>+ <string name="context_menu_go_to_queue" formatted="false">Gå till kön</string>+ <string name="context_menu_browse_album" formatted="false">Gå till album</string>+ <string name="context_menu_browse_artist" formatted="false">Gå till artisten</string>+ <string name="context_menu_share" formatted="false">Dela</string>+ <string name="context_menu_sleep_timer" formatted="false">Insomningstimer</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Stäng av timer</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Låtens slut</string>+ <string name="snackbar_added_to_queue" formatted="false">Tillagd i kön</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Tillagd till Gillade låtar.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Borttagen från Gillade Låtar.</string>+ <string name="content_description_context_menu" formatted="false">Fler alternativ</string>+ <string name="close_button_content_description" formatted="false">Stäng</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Sparad i</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Ny spellista</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Avbryt</string>+ <string name="create_playlist_create_button" formatted="false">Skapa</string>+ <string name="lyrics_card_title" formatted="false">Låttexter</string>+ <string name="lyrics_card_title_preview" formatted="false">Förhandsgranskning av låttexter</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Visa låttexter</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Öppna låttexten i helskärm</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Dela låttext</string>+ <string name="lyrics_credential_note" formatted="false">Låttexten tillhandahålls av %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Dela</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Översätt</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Stäng låttext</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Översätt låttexten</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Sluta översätta låttext</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Vi kan inte den här låttexten.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">De här låttexterna är inte tidssynkroniserade än.</string>+ <string name="av_switch_to_video" formatted="false">Växla till video</string>+ <string name="av_switch_to_audio" formatted="false">Växla till ljud</string>+ <string name="av_content_desc" formatted="false">Växla mellan ljud och video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Hem</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Sök</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Ditt bibliotek</string>+ <string name="search_header_field_hint" formatted="false">Vad vill du lyssna på?</string>+ <string name="filter_chip_all_label" formatted="false">Alla</string>+ <string name="recents_content_filter_music" formatted="false">Musik</string>+ <string name="ad_category_title_podcasts" formatted="false">Poddar</string>+ <string name="audiobooks_title" formatted="false">Ljudböcker</string>+ <string name="artist_popular_tracks" formatted="false">Populära</string>+ <string name="curation_button_follow_state_text" formatted="false">Följ</string>+ <string name="curation_button_following_state_text" formatted="false">Följer</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artist</string>+ <string name="connect_phone_is_self" formatted="false">Den här telefonen</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Korta visuella loopar när en låt spelas upp.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Inte nu</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Uppdatering</string>+ <string name="context_type_description_play_queue" formatted="false">Spelar från uppspelningskön</string>+ <string name="context_type_description_collection_your_library" formatted="false">Spelar upp från ditt bibliotek</string>+ <string name="context_type_description_playlist" formatted="false">Spelar upp från spellista</string>+ <string name="context_type_description_album" formatted="false">Spelar upp från album</string>+ <string name="context_type_description_artist" formatted="false">Spelar upp från artist</string>+ <string name="context_type_description_show" formatted="false">Spelar upp från podd</string>+ <string name="context_type_description_search" formatted="false">Spelar upp från sökning</string>+ <string name="default_notification_channel_name" formatted="false">Nu spelas</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Enheter</string>+ <string name="action_share_label" formatted="false">Dela</string>+ <string name="action_queue_label" formatted="false">Köa</string>+ <string name="mute_chat_duration_one_hour" formatted="false">En timme</string>+ <string name="curation_actions_edit_button_title" formatted="false">Redigera</string>+ <string name="content_description_pause_button" formatted="false">Pausa</string>+ <string name="content_description_play_button" formatted="false">Spela upp</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Shuffle</string>+ <string name="np_content_desc_repeat" formatted="false">Repetera</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Insomningstimer</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Ta bort</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Flytta</string>+ <string name="bottom_actions_close" formatted="false">Stäng</string>+ <string name="add_to_queue_action_content_description" formatted="false">Lägg till i kön</string>+ <string name="curation_button_saved_text" formatted="false">Sparad</string>+ <string name="np_content_desc_prev" formatted="false">Föregående</string>+ <string name="np_content_desc_next" formatted="false">Nästa</string>+ <string name="accessibility_navigate_back" formatted="false">Tillbaka</string>+ <string name="monthly_listeners_text" formatted="false">%1$s lyssnare i månaden</string>+ <string name="profile_bio_show_less" formatted="false">Visa mindre</string>+ <string name="audiobook_series_see_more_button" formatted="false">Visa mer</string>+ <string name="popular_releases_section_title" formatted="false">Populära releaser</string>+ <string name="creator_biography_section_title" formatted="false">Om</string>+ <string name="fans_also_like_section_title" formatted="false">Fans gillar även</string>+ <string name="appears_on_section_title" formatted="false">Medverkar på</string>+ <string name="composer_section_button_show_all" formatted="false">Visa alla</string>+ <string name="releases_title" formatted="false">Releaser</string>+ <string name="artist_releases_albums" formatted="false">Album</string>+ <string name="artist_releases_singles" formatted="false">Singlar och EP</string>+ <string name="latest_release_title" formatted="false">Nya releaser</string>+ <string name="artist_subtitle" formatted="false">Artist</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Sökhistorik</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Rensa</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Poddar</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Avsnitt</string>+ <string name="assisted_curation_search_song" formatted="false">Låt</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podd</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Logga ut</string>+ <string name="library_search_text_hint" formatted="false">Sök i Ditt bibliotek</string>+ <string name="account_title" formatted="false">Konto</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Följda artister</string>+ <string name="settings_item_crossfade_title" formatted="false">Crossfade</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Lokala filer</string>+ <string name="local_files_empty_section_title" formatted="false">Lägga till egna ljudfiler i Ditt bibliotek</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Har du en låt eller egen podd som inte finns på Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Dina ljudfiler visas här</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Ge åtkomst</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Gå till Inställningar</string>+ <string name="context_menu_download" formatted="false">Ladda ned</string>+ <string name="context_menu_undownload" formatted="false">Ta bort nedladdningen</string>+ <string name="collection_downloaded" formatted="false">Nedladdade</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Nedladdat</string>+ <string name="download_badge_downloading_content_description" formatted="false">Laddar ned</string>+ <string name="download_badge_error_content_description" formatted="false">Nedladdningen misslyckades</string>+ <string name="download_notification_downloading" formatted="false">Laddar ned …</string>+ <string name="toast_undownload" formatted="false">Nedladdningen har tagits bort.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Vill du ta bort det här från Nedladdningar?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Du kommer inte kunna spela upp det här offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Ta bort</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Ta bort alla nedladdningar</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Vill du ta bort alla nedladdningar?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Singel</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Samling</string>+ <string name="assisted_curation_search_playlist" formatted="false">Spellista</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Bästa resultat</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Låtar</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artister</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Album</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Spellistor</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Rensa filter</string>+ <string name="ad_category_title_music" formatted="false">Musik</string>+ <string name="made_for_you_hub_title" formatted="false">Skapad för dig</string>+ <string name="settings_item_app_language_title" formatted="false">Appspråk</string>+ <string name="create_menu_item_folder_title" formatted="false">Mapp</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Ny mapp</string>+ <string name="context_menu_rename_folder" formatted="false">Byt namn på mappen</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Mappnamn</string>+ <string name="create_playlist_content_description" formatted="false">Skapa spellista</string>+ <string name="actions_picker_delete" formatted="false">Radera</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sortera efter</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alfabetiskt</string>+ <string name="your_library_sort_order_creator" formatted="false">Upphovsperson</string>+ <string name="your_library_sort_order_custom" formatted="false">Anpassad ordning</string>+ <string name="settings_item_version_title" formatted="false">Version</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Gå till låtradio</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Hitta i Gillade låtar</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Hitta i spellista</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Kunde inte hitta ”%1$s”</string>+</resources>diff --git a/base/app/src/main/res/values-sw/spotify_plurals.xml b/base/app/src/main/res/values-sw/spotify_plurals.xmlnew file mode 100644index 00000000..82d47533--- /dev/null+++ b/base/app/src/main/res/values-sw/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">Wimbo %1$d</item>+ <item quantity="other">Nyimbo %1$d</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">Imehifadhiwa mara %1$,d</item>+ <item quantity="other">Imehifadhiwa mara %1$,d</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">Orodha %1$s ya kucheza</item>+ <item quantity="other">Orodha %1$s za kucheza</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">Wimbo %1$s</item>+ <item quantity="other">Nyimbo %1$s</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-sw/spotify_strings.xml b/base/app/src/main/res/values-sw/spotify_strings.xmlnew file mode 100644index 00000000..3ef5b511--- /dev/null+++ b/base/app/src/main/res/values-sw/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Weka kwenye Nyimbo Zilizokupendeza</string>+ <string name="collection_liked_songs_title" formatted="false">Nyimbo Zilizokupendeza</string>+ <string name="context_menu_add_to_playlist" formatted="false">Weka kwenye orodha ya kucheza</string>+ <string name="context_menu_play_next" formatted="false">Cheza unaofuata</string>+ <string name="context_menu_add_to_queue" formatted="false">Ongeza kwenye Foleni</string>+ <string name="context_menu_go_to_queue" formatted="false">Fungua Foleni</string>+ <string name="context_menu_browse_album" formatted="false">Nenda kwenye albamu</string>+ <string name="context_menu_browse_artist" formatted="false">Nenda kwa Msanii</string>+ <string name="context_menu_share" formatted="false">Shiriki</string>+ <string name="context_menu_sleep_timer" formatted="false">Kipima muda wa kulala</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Zima kipima muda</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Mwishoni mwa wimbo</string>+ <string name="snackbar_added_to_queue" formatted="false">Umewekwa kwenye Foleni</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Imeongezwa kwenye Nyimbo Zilizokupendeza.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Imeondolewa kwenye Nyimbo Zilizokupendeza.</string>+ <string name="content_description_context_menu" formatted="false">Chaguo zaidi</string>+ <string name="close_button_content_description" formatted="false">Funga</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Yamehifadhiwa katika</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Orodha mpya ya kucheza</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Ghairi</string>+ <string name="create_playlist_create_button" formatted="false">Unda</string>+ <string name="lyrics_card_title" formatted="false">Mistari ya nyimbo</string>+ <string name="lyrics_card_title_preview" formatted="false">Kionjo cha mistari ya nyimbo</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Onyesha mistari ya nyimbo</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Fungua mistari ya nyimbo kwenye skrini nzima</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Shiriki mistari ya nyimbo</string>+ <string name="lyrics_credential_note" formatted="false">Mistari ya nyimbo imetolewa na %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Shiriki</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Tafsiri</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Funga mistari ya nyimbo</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Tafsiri mashairi</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Acha kutafsiri mistari ya nyimbo</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Lo! Hatufahamu mistari ya wimbo huu.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Mistari hii ya nyimbo bado haijasawazishwa na nyimbo.</string>+ <string name="av_switch_to_video" formatted="false">Badili utazame video</string>+ <string name="av_switch_to_audio" formatted="false">Badili usikilize sauti</string>+ <string name="av_content_desc" formatted="false">Badilisha kati ya sauti na video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Mwanzo</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Tafuta</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Maktaba Yako</string>+ <string name="search_header_field_hint" formatted="false">Ungependa kusikiliza nini?</string>+ <string name="filter_chip_all_label" formatted="false">Zote</string>+ <string name="recents_content_filter_music" formatted="false">Muziki</string>+ <string name="ad_category_title_podcasts" formatted="false">Podikasti</string>+ <string name="audiobooks_title" formatted="false">Vitabu vya kusikiliza</string>+ <string name="artist_popular_tracks" formatted="false">Maarufu</string>+ <string name="curation_button_follow_state_text" formatted="false">Fuatilia</string>+ <string name="curation_button_following_state_text" formatted="false">Unafuatilia</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Msanii</string>+ <string name="connect_phone_is_self" formatted="false">Simu hii</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Vielelezo vifupi vinavyorudiwa wakati wimbo unacheza.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Si sasa</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Sasisha</string>+ <string name="context_type_description_play_queue" formatted="false">Inacheza kutoka Foleni ya Kucheza</string>+ <string name="context_type_description_collection_your_library" formatted="false">Inacheza kutoka kwenye Maktaba Yako</string>+ <string name="context_type_description_playlist" formatted="false">Inacheza kwenye Orodha</string>+ <string name="context_type_description_album" formatted="false">Inacheza kutoka kwenye Albamu</string>+ <string name="context_type_description_artist" formatted="false">Inacheza kutoka kwa Msanii</string>+ <string name="context_type_description_show" formatted="false">Inacheza kwenye Podikasti</string>+ <string name="context_type_description_search" formatted="false">Inacheza kutoka kwenye Utafutaji</string>+ <string name="default_notification_channel_name" formatted="false">Inayocheza sasa</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Vifaa</string>+ <string name="action_share_label" formatted="false">Shiriki</string>+ <string name="action_queue_label" formatted="false">Foleni</string>+ <string name="mute_chat_duration_one_hour" formatted="false">Saa 1</string>+ <string name="curation_actions_edit_button_title" formatted="false">Badilisha</string>+ <string name="content_description_pause_button" formatted="false">Sitisha</string>+ <string name="content_description_play_button" formatted="false">Cheza</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Kuchanganya</string>+ <string name="np_content_desc_repeat" formatted="false">Kurudia</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Kipima muda wa kulala</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Ondoa</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Sogeza</string>+ <string name="bottom_actions_close" formatted="false">Funga</string>+ <string name="add_to_queue_action_content_description" formatted="false">Ongeza kwenye foleni</string>+ <string name="curation_button_saved_text" formatted="false">Imehifadhiwa</string>+ <string name="np_content_desc_prev" formatted="false">Iliyotangulia</string>+ <string name="np_content_desc_next" formatted="false">Inayofuata</string>+ <string name="accessibility_navigate_back" formatted="false">Rudi nyuma</string>+ <string name="monthly_listeners_text" formatted="false">Wasikilizaji %1$s kila mwezi</string>+ <string name="profile_bio_show_less" formatted="false">Onyesha chache</string>+ <string name="audiobook_series_see_more_button" formatted="false">Onyesha zaidi</string>+ <string name="popular_releases_section_title" formatted="false">Matoleo maarufu</string>+ <string name="creator_biography_section_title" formatted="false">Kuhusu</string>+ <string name="fans_also_like_section_title" formatted="false">Mashabiki pia wanapenda</string>+ <string name="appears_on_section_title" formatted="false">Huonekana kwenye</string>+ <string name="composer_section_button_show_all" formatted="false">Onyesha zote</string>+ <string name="releases_title" formatted="false">Matoleo</string>+ <string name="artist_releases_albums" formatted="false">Albamu</string>+ <string name="artist_releases_singles" formatted="false">Singo na EP</string>+ <string name="latest_release_title" formatted="false">Toleo jipya</string>+ <string name="artist_subtitle" formatted="false">Msanii</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Utafutaji wa majuzi</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Futa</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podikasti</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Vipindi</string>+ <string name="assisted_curation_search_song" formatted="false">Wimbo</string>+ <string name="album" formatted="false">Albamu</string>+ <string name="album_type_podcast" formatted="false">Podikasti</string>+ <string name="recently_played_user_profile" formatted="false">Wasifu</string>+ <string name="connect_device_menu_logout" formatted="false">Ondoka katika akaunti</string>+ <string name="library_search_text_hint" formatted="false">Tafuta Maktaba Yako</string>+ <string name="account_title" formatted="false">Akaunti</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Wasanii unaowafuatilia</string>+ <string name="settings_item_crossfade_title" formatted="false">Unganisha</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">Sek %1$d</string>+ <string name="local_files_title" formatted="false">Faili zilizo kwenye Kifaa</string>+ <string name="local_files_empty_section_title" formatted="false">Weka faili zako za sauti kwenye Maktaba Yako</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Una wimbo au podikasti ya binafsi ambayo haipo kwenye Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Faili zako za sauti zitaonekana hapa</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Toa idhini ya kufikia</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Nenda kwenye Mipangilio</string>+ <string name="context_menu_download" formatted="false">Pakua</string>+ <string name="context_menu_undownload" formatted="false">Ondoa kipakuliwa</string>+ <string name="collection_downloaded" formatted="false">Ulizopakua</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Imepakuliwa</string>+ <string name="download_badge_downloading_content_description" formatted="false">Inapakua</string>+ <string name="download_badge_error_content_description" formatted="false">Imeshindwa kupakua</string>+ <string name="download_notification_downloading" formatted="false">Inapakua…</string>+ <string name="toast_undownload" formatted="false">Kipakuliwa kimeondolewa.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Ungependa kuondoa kwenye vipakuliwa?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Hutaweza kucheza podikasti hii nje ya mtandao.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Ondoa</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Ondoa vipakuliwa vyote</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Ungependa kuondoa vipakuliwa vyote?</string>+ <string name="album_type_album" formatted="false">Albamu</string>+ <string name="album_type_single" formatted="false">Wimbo</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Mikusanyiko</string>+ <string name="assisted_curation_search_playlist" formatted="false">Orodha ya kucheza</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Maarufu</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Nyimbo</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Wasanii</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albamu</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Orodha za kucheza</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Futa kichujio</string>+ <string name="ad_category_title_music" formatted="false">Muziki</string>+ <string name="made_for_you_hub_title" formatted="false">Kwa Ajili Yako</string>+ <string name="settings_item_app_language_title" formatted="false">Lugha ya programu</string>+ <string name="create_menu_item_folder_title" formatted="false">Folda</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Folda mpya</string>+ <string name="context_menu_rename_folder" formatted="false">Badilisha jina la folda</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Jina la folda</string>+ <string name="create_playlist_content_description" formatted="false">Unda orodha ya kucheza</string>+ <string name="actions_picker_delete" formatted="false">Futa</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Panga kulingana na</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Mpangilio wa alfabeti</string>+ <string name="your_library_sort_order_creator" formatted="false">Mtayarishi</string>+ <string name="your_library_sort_order_custom" formatted="false">Mpangilio maalum</string>+ <string name="settings_item_version_title" formatted="false">Toleo</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Nenda kwenye redio ya nyimbo</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Tafuta katika Nyimbo Zilizokupendeza</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Tafuta katika orodha ya kucheza</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Haikupata \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-ta/spotify_plurals.xml b/base/app/src/main/res/values-ta/spotify_plurals.xmlnew file mode 100644index 00000000..098a06d6--- /dev/null+++ b/base/app/src/main/res/values-ta/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d பாடல்</item>+ <item quantity="other">%1$d பாடல்கள்</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d சேமிப்பு</item>+ <item quantity="other">%1$,d சேமிப்புகள்</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s பிளேலிஸ்ட்</item>+ <item quantity="other">%1$s பிளேலிஸ்ட்கள்</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s பாடல்</item>+ <item quantity="other">%1$s பாடல்கள்</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ta/spotify_strings.xml b/base/app/src/main/res/values-ta/spotify_strings.xmlnew file mode 100644index 00000000..f085e7a7--- /dev/null+++ b/base/app/src/main/res/values-ta/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">விரும்பிய பாடல்களில் சேர்க்கும்</string>+ <string name="collection_liked_songs_title" formatted="false">விரும்பிய பாடல்கள்</string>+ <string name="context_menu_add_to_playlist" formatted="false">பிளேலிஸ்ட்டில் சேர்</string>+ <string name="context_menu_play_next" formatted="false">அடுத்ததை இயக்கு</string>+ <string name="context_menu_add_to_queue" formatted="false">வரிசையில் சேர்</string>+ <string name="context_menu_go_to_queue" formatted="false">வரிசைக்குச் செல்</string>+ <string name="context_menu_browse_album" formatted="false">ஆல்பத்துக்குச் செல்</string>+ <string name="context_menu_browse_artist" formatted="false">கலைஞருக்குச் செல்</string>+ <string name="context_menu_share" formatted="false">பகிர்</string>+ <string name="context_menu_sleep_timer" formatted="false">ஸ்லீப் டைமர்</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">டைமரை முடக்கு</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">பாடலின் முடிவு</string>+ <string name="snackbar_added_to_queue" formatted="false">வரிசையில் சேர்க்கப்பட்டது</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">விரும்பிய பாடல்களில் சேர்க்கப்பட்டது.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">விரும்பிய பாடல்களிலிருந்து அகற்றப்பட்டது.</string>+ <string name="content_description_context_menu" formatted="false">மேலும் விருப்பங்கள்</string>+ <string name="close_button_content_description" formatted="false">மூடு</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">இவற்றில் சேமிக்கப்பட்டது</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">புதிய பிளேலிஸ்ட்</string>+ <string name="add_to_playlist_button_cancel" formatted="false">ரத்துசெய்</string>+ <string name="create_playlist_create_button" formatted="false">உருவாக்கு</string>+ <string name="lyrics_card_title" formatted="false">பாடல் வரிகள்</string>+ <string name="lyrics_card_title_preview" formatted="false">பாடல் வரிகளின் முன்னோட்டம்</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">பாடல் வரிகளைக் காட்டு</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">முழுத்திரையில் பாடல் வரிகளைத் திறக்கும்</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">பாடல் வரிகளைப் பகிரவும்</string>+ <string name="lyrics_credential_note" formatted="false">பாடல் வரிகளை வழங்குவது %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">பகிர்</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">மொழிபெயர்</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">பாடல் வரிகளை மூடும்</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">பாடல் வரிகளை மொழிபெயர்</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">பாடல் வரிகளை மொழிபெயர்ப்பதை நிறுத்தும்</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">ஹ்ம்ம். இந்தப் பாடலின் வரிகள் எங்களுக்குத் தெரியாது.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">இந்தப் பாடல் வரிகளுக்கு இன்னும் நேரம் ஒத்திசைக்கப்படவில்லை.</string>+ <string name="av_switch_to_video" formatted="false">வீடியோவுக்கு மாற்று</string>+ <string name="av_switch_to_audio" formatted="false">ஆடியோவுக்கு மாற்று</string>+ <string name="av_content_desc" formatted="false">ஆடியோவுக்கும் வீடியோவுக்கும் இடையே நிலைமாற்றும்</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">முகப்பு</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">தேடல்</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">உங்கள் லைப்ரரி</string>+ <string name="search_header_field_hint" formatted="false">நீங்கள் என்ன கேட்க விரும்புகிறீர்கள்?</string>+ <string name="filter_chip_all_label" formatted="false">அனைத்தும்</string>+ <string name="recents_content_filter_music" formatted="false">இசை</string>+ <string name="ad_category_title_podcasts" formatted="false">பாட்காஸ்ட்கள்</string>+ <string name="audiobooks_title" formatted="false">ஆடியோபுக்குகள்</string>+ <string name="artist_popular_tracks" formatted="false">பிரபலமானவை</string>+ <string name="curation_button_follow_state_text" formatted="false">பின்தொடர்</string>+ <string name="curation_button_following_state_text" formatted="false">பின்தொடர்கிறீர்கள்</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">கலைஞர்</string>+ <string name="connect_phone_is_self" formatted="false">இந்தத் தொலைபேசி</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">பாடல் பிளேயாகும்போது காட்டப்படும் சிறிய லூப் விஷுவல்கள்.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">இப்போது வேண்டாம்</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">புதுப்பிப்பு</string>+ <string name="context_type_description_play_queue" formatted="false">இயக்க வரிசையிலிருந்து பிளே செய்கிறது</string>+ <string name="context_type_description_collection_your_library" formatted="false">உங்கள் லைப்ரரியிலிருந்து பிளே செய்கிறது</string>+ <string name="context_type_description_playlist" formatted="false">பிளேலிஸ்ட்டிலிருந்து பிளே செய்கிறது</string>+ <string name="context_type_description_album" formatted="false">இந்த ஆல்பத்திலிருந்து பிளே செய்கிறது:</string>+ <string name="context_type_description_artist" formatted="false">இந்தக் கலைஞரிலிருந்து பிளே செய்கிறது:</string>+ <string name="context_type_description_show" formatted="false">பாட்காஸ்டிலிருந்து பிளே செய்கிறது</string>+ <string name="context_type_description_search" formatted="false">தேடலிலிருந்து பிளே செய்கிறது</string>+ <string name="default_notification_channel_name" formatted="false">இப்போது பிளே ஆவது</string>+ <string name="label_bluetooth" formatted="false">புளூடூத்</string>+ <string name="mr_user_route_category_name" formatted="false">சாதனங்கள்</string>+ <string name="action_share_label" formatted="false">பகிர்</string>+ <string name="action_queue_label" formatted="false">வரிசையில் சேர்</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 மணிநேரம்</string>+ <string name="curation_actions_edit_button_title" formatted="false">திருத்து</string>+ <string name="content_description_pause_button" formatted="false">இடைநிறுத்து</string>+ <string name="content_description_play_button" formatted="false">பிளே</string>+ <string name="play_mode_item_shuffle_title" formatted="false">ஷஃபில் செய்</string>+ <string name="np_content_desc_repeat" formatted="false">திரும்ப பிளே செய்யும்</string>+ <string name="np_content_desc_sleep_timer" formatted="false">ஸ்லீப் டைமர்</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">அகற்றுக</string>+ <string name="edit_playlist_items_move_chip" formatted="false">நகர்த்து</string>+ <string name="bottom_actions_close" formatted="false">மூடும்</string>+ <string name="add_to_queue_action_content_description" formatted="false">வரிசையில் சேர்க்கும்</string>+ <string name="curation_button_saved_text" formatted="false">சேமிக்கப்பட்டது</string>+ <string name="np_content_desc_prev" formatted="false">முந்தையது</string>+ <string name="np_content_desc_next" formatted="false">அடுத்தது</string>+ <string name="accessibility_navigate_back" formatted="false">பின்செல்லும்</string>+ <string name="monthly_listeners_text" formatted="false">%1$s மாதம்தோறும் கேட்பவர்கள்</string>+ <string name="profile_bio_show_less" formatted="false">குறைவாகக் காண்க</string>+ <string name="audiobook_series_see_more_button" formatted="false">மேலும் காண்க</string>+ <string name="popular_releases_section_title" formatted="false">பிரபலமான வெளியீடுகள்</string>+ <string name="creator_biography_section_title" formatted="false">அறிமுகம்</string>+ <string name="fans_also_like_section_title" formatted="false">ரசிகர்கள் இதையும் விரும்புகின்றனர்</string>+ <string name="appears_on_section_title" formatted="false">இதில் தோன்றுகிறது</string>+ <string name="composer_section_button_show_all" formatted="false">அனைத்தையும் காண்க</string>+ <string name="releases_title" formatted="false">வெளியீடுகள்</string>+ <string name="artist_releases_albums" formatted="false">ஆல்பங்கள்</string>+ <string name="artist_releases_singles" formatted="false">தனிப்பாடல்கள் மற்றும் EPகள்</string>+ <string name="latest_release_title" formatted="false">சமீபத்திய வெளியீடு</string>+ <string name="artist_subtitle" formatted="false">கலைஞர்</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">சமீபத்திய தேடல்கள்</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">அழி</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">பாட்காஸ்டுகள்</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">எபிசோடுகள்</string>+ <string name="assisted_curation_search_song" formatted="false">பாடல்</string>+ <string name="album" formatted="false">ஆல்பம்</string>+ <string name="album_type_podcast" formatted="false">பாட்காஸ்ட்</string>+ <string name="recently_played_user_profile" formatted="false">சுயவிவரம்</string>+ <string name="connect_device_menu_logout" formatted="false">வெளியேறு</string>+ <string name="library_search_text_hint" formatted="false">உங்கள் லைப்ரரியில் தேடவும்</string>+ <string name="account_title" formatted="false">கணக்கு</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">பின்தொடரும் கலைஞர்கள்</string>+ <string name="settings_item_crossfade_title" formatted="false">கிராஸ்ஃபேட்</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d வி</string>+ <string name="local_files_title" formatted="false">சாதனத்திலுள்ள கோப்புகள்</string>+ <string name="local_files_empty_section_title" formatted="false">உங்கள் லைப்ரரி பிரிவில் உங்களின் சொந்த ஆடியோ கோப்புகளைச் சேருங்கள்</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Spotifyயில் இல்லாத பாடலோ தனிப்பட்ட பாட்காஸ்ட்டோ உங்களிடம் உள்ளதா?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">உங்கள் ஆடியோ கோப்புகள் இங்கே காட்டப்படும்</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">அணுகலை வழங்கு</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">அமைப்புகளுக்குச் செல்</string>+ <string name="context_menu_download" formatted="false">பதிவிறக்கு</string>+ <string name="context_menu_undownload" formatted="false">பதிவிறக்கத்தை அகற்று</string>+ <string name="collection_downloaded" formatted="false">பதிவிறக்கப்பட்டது</string>+ <string name="download_badge_downloaded_content_description" formatted="false">பதிவிறக்கப்பட்டது</string>+ <string name="download_badge_downloading_content_description" formatted="false">பதிவிறக்குகிறது</string>+ <string name="download_badge_error_content_description" formatted="false">பதிவிறக்கம் தோல்வியடைந்தது</string>+ <string name="download_notification_downloading" formatted="false">பதிவிறக்குகிறது…</string>+ <string name="toast_undownload" formatted="false">பதிவிறக்கம் அகற்றப்பட்டது.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">பதிவிறக்கங்களிலிருந்து அகற்றவா?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">இதை ஆஃப்லைனில் இயக்க முடியாது.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">அகற்று</string>+ <string name="settings_item_remove_downloads_title" formatted="false">எல்லாப் பதிவிறக்கங்களையும் அகற்று</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">எல்லாப் பதிவிறக்கங்களையும் அகற்றவா?</string>+ <string name="album_type_album" formatted="false">ஆல்பம்</string>+ <string name="album_type_single" formatted="false">தனிப்பாடல்</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">தொகுப்பு</string>+ <string name="assisted_curation_search_playlist" formatted="false">பிளேலிஸ்ட்</string>+ <string name="assisted_curation_search_filter_top" formatted="false">சிறந்தவை</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">பாடல்கள்</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">கலைஞர்கள்</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">ஆல்பங்கள்</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">பிளேலிஸ்ட்கள்</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">வடிப்பானை அழிக்கும்</string>+ <string name="ad_category_title_music" formatted="false">இசை</string>+ <string name="made_for_you_hub_title" formatted="false">உங்களுக்காகவே உருவாக்கப்பட்டது</string>+ <string name="settings_item_app_language_title" formatted="false">செயலியின் மொழி</string>+ <string name="create_menu_item_folder_title" formatted="false">கோப்புறை</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">புதிய கோப்புறை</string>+ <string name="context_menu_rename_folder" formatted="false">கோப்புறையின் பெயரை மாற்று</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">கோப்புறையின் பெயர்</string>+ <string name="create_playlist_content_description" formatted="false">பிளேலிஸ்ட்டை உருவாக்கும்</string>+ <string name="actions_picker_delete" formatted="false">நீக்கு</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">இதன்படி வரிசைப்படுத்து</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">அகரவரிசை</string>+ <string name="your_library_sort_order_creator" formatted="false">உருவாக்கியவர்</string>+ <string name="your_library_sort_order_custom" formatted="false">தனிப்பயன் வரிசை</string>+ <string name="settings_item_version_title" formatted="false">பதிப்பு</string>+ <string name="context_menu_go_to_song_radio" formatted="false">பாடல் ரேடியோவிற்குச் செல்</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">விரும்பிய பாடல்களில் கண்டறியலாம்</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">பிளேலிஸ்ட்டில் கண்டறிக</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\"-ஐக் கண்டறிய முடியவில்லை</string>+</resources>diff --git a/base/app/src/main/res/values-te/spotify_plurals.xml b/base/app/src/main/res/values-te/spotify_plurals.xmlnew file mode 100644index 00000000..1495ecb6--- /dev/null+++ b/base/app/src/main/res/values-te/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d పాట</item>+ <item quantity="other">%1$d పాటలు</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d సేవ్</item>+ <item quantity="other">%1$,d సేవ్లు</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s ప్లేలిస్ట్</item>+ <item quantity="other">%1$s ప్లేలిస్ట్లు</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s పాట</item>+ <item quantity="other">%1$s పాటలు</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-te/spotify_strings.xml b/base/app/src/main/res/values-te/spotify_strings.xmlnew file mode 100644index 00000000..8b2ed24a--- /dev/null+++ b/base/app/src/main/res/values-te/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">ఇష్టపడిన పాటలకు జోడించండి</string>+ <string name="collection_liked_songs_title" formatted="false">ఇష్టపడిన పాటలు</string>+ <string name="context_menu_add_to_playlist" formatted="false">ప్లేలిస్ట్కు చేర్చండి</string>+ <string name="context_menu_play_next" formatted="false">తరువాత ప్లే చేయండి</string>+ <string name="context_menu_add_to_queue" formatted="false">క్యూకు జోడించండి</string>+ <string name="context_menu_go_to_queue" formatted="false">క్యూకు వెళ్ళండి</string>+ <string name="context_menu_browse_album" formatted="false">ఆల్బమ్కు వెళ్లండి</string>+ <string name="context_menu_browse_artist" formatted="false">ఆర్టిస్ట్కు వెళ్ళండి</string>+ <string name="context_menu_share" formatted="false">షేర్ చేయండి</string>+ <string name="context_menu_sleep_timer" formatted="false">స్లీప్ టైమర్</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">టైమర్ ఆఫ్ చేయండి</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">ట్రాక్ ముగింపు</string>+ <string name="snackbar_added_to_queue" formatted="false">క్యూకి చేర్చబడింది</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">లైక్ చేసిన పాటలకు జోడించబడింది.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">లైక్ చేసిన పాటల నుండి తీసివేయబడింది.</string>+ <string name="content_description_context_menu" formatted="false">మరిన్ని ఎంపికలు</string>+ <string name="close_button_content_description" formatted="false">మూసివేయండి</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">ఇందులో సేవ్ చేయబడింది</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">కొత్త ప్లేలిస్ట్</string>+ <string name="add_to_playlist_button_cancel" formatted="false">రద్దు చేయి</string>+ <string name="create_playlist_create_button" formatted="false">రూపొందించండి</string>+ <string name="lyrics_card_title" formatted="false">లిరిక్స్</string>+ <string name="lyrics_card_title_preview" formatted="false">లిరిక్స్ ప్రివ్యూ</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">లిరిక్స్ని చూపించండి</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">పూర్తి స్క్రీన్ లిరిక్స్ తెరవండి</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">లిరిక్స్ షేర్ చేయండి</string>+ <string name="lyrics_credential_note" formatted="false">%1$s ద్వారా లిరిక్స్ అందించబడ్డాయి</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">షేర్ చేయి</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">అనువదించు</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">లిరిక్స్ని మూసివేయండి</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">లిరిక్స్ను అనువదించండి</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">లిరిక్స్ను అనువదించడం ఆపివేయండి</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">అవును. దీని లిరిక్స్ మాకు తెలియవు.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">ఈ లిరిక్స్ ఇంకా టైమ్కి సింక్ కాలేదు.</string>+ <string name="av_switch_to_video" formatted="false">వీడియోకి మారండి</string>+ <string name="av_switch_to_audio" formatted="false">ఆడియోకి మారండి</string>+ <string name="av_content_desc" formatted="false">ఆడియో మరియు వీడియో మధ్య టోగుల్ చేయండి</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">హోమ్</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">శోధించండి</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">మీ లైబ్రెరీ</string>+ <string name="search_header_field_hint" formatted="false">మీరు ఏం వినాలనుకుంటున్నారు?</string>+ <string name="filter_chip_all_label" formatted="false">అన్నీ</string>+ <string name="recents_content_filter_music" formatted="false">మ్యూజిక్</string>+ <string name="ad_category_title_podcasts" formatted="false">పాడ్కాస్ట్లు</string>+ <string name="audiobooks_title" formatted="false">ఆడియోబుక్లు</string>+ <string name="artist_popular_tracks" formatted="false">జనాదరణ పొందిన</string>+ <string name="curation_button_follow_state_text" formatted="false">అనుసరించండి</string>+ <string name="curation_button_following_state_text" formatted="false">అనుసరిస్తున్నారు</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">ఆర్టిస్ట్</string>+ <string name="connect_phone_is_self" formatted="false">ఈ ఫోన్</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">పాట ప్లే అవుతున్నప్పుడు చిన్న, లూపింగ్ విజువల్స్.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">ఇప్పుడు కాదు</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">అప్డేట్ చేయండి</string>+ <string name="context_type_description_play_queue" formatted="false">ప్లే క్యూ నుండి ప్లే అవుతుంది</string>+ <string name="context_type_description_collection_your_library" formatted="false">మీ లైబ్రరీ నుండి ప్లే అవుతుంది</string>+ <string name="context_type_description_playlist" formatted="false">ప్లేలిస్ట్ నుండి ప్లే అవుతుంది</string>+ <string name="context_type_description_album" formatted="false">ఆల్బమ్ నుండి ప్లే అవుతుంది</string>+ <string name="context_type_description_artist" formatted="false">ఆర్టిస్ట్ నుండి ప్లే అవుతుంది</string>+ <string name="context_type_description_show" formatted="false">పాడ్కాస్ట్ నుండి ప్లే అవుతుంది</string>+ <string name="context_type_description_search" formatted="false">శోధన నుండి ప్లే అవుతుంది</string>+ <string name="default_notification_channel_name" formatted="false">ప్రస్తుతం ప్లే అవుతున్నది</string>+ <string name="label_bluetooth" formatted="false">బ్లూటూత్</string>+ <string name="mr_user_route_category_name" formatted="false">డివైజ్లు</string>+ <string name="action_share_label" formatted="false">షేర్ చేయండి</string>+ <string name="action_queue_label" formatted="false">క్యూలో చేర్చు</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 గంట</string>+ <string name="curation_actions_edit_button_title" formatted="false">ఎడిట్ చేయి</string>+ <string name="content_description_pause_button" formatted="false">పాజ్ చేయి</string>+ <string name="content_description_play_button" formatted="false">ప్లే చేయి</string>+ <string name="play_mode_item_shuffle_title" formatted="false">షఫుల్</string>+ <string name="np_content_desc_repeat" formatted="false">రిపీట్ చేయండి</string>+ <string name="np_content_desc_sleep_timer" formatted="false">స్లీప్ టైమర్</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">తీసివేయండి</string>+ <string name="edit_playlist_items_move_chip" formatted="false">తరలించు</string>+ <string name="bottom_actions_close" formatted="false">మూసివేయి</string>+ <string name="add_to_queue_action_content_description" formatted="false">క్యూకు చేర్చు</string>+ <string name="curation_button_saved_text" formatted="false">సేవ్ చేయబడినవి</string>+ <string name="np_content_desc_prev" formatted="false">మునుపటి</string>+ <string name="np_content_desc_next" formatted="false">తరువాత</string>+ <string name="accessibility_navigate_back" formatted="false">వెనుకకు</string>+ <string name="monthly_listeners_text" formatted="false">%1$s నెలవారీ శ్రోతలు</string>+ <string name="profile_bio_show_less" formatted="false">తక్కువ చూపించు</string>+ <string name="audiobook_series_see_more_button" formatted="false">మరిన్ని చూపించు</string>+ <string name="popular_releases_section_title" formatted="false">ప్రజాదరణ పొందిన రిలీజ్లు</string>+ <string name="creator_biography_section_title" formatted="false">గురించి</string>+ <string name="fans_also_like_section_title" formatted="false">అభిమానులు వీటిని కూడా ఇష్టపడుతున్నారు</string>+ <string name="appears_on_section_title" formatted="false">దీనిలో కనిపిస్తారు</string>+ <string name="composer_section_button_show_all" formatted="false">అన్నిటినీ చూపించు</string>+ <string name="releases_title" formatted="false">రిలీజ్లు</string>+ <string name="artist_releases_albums" formatted="false">ఆల్బమ్లు</string>+ <string name="artist_releases_singles" formatted="false">సింగిల్స్ మరియు EPలు</string>+ <string name="latest_release_title" formatted="false">తాజా విడుదల</string>+ <string name="artist_subtitle" formatted="false">ఆర్టిస్ట్</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">ఇటీవలి శోధనలు</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">క్లియర్ చేయి</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">పాడ్కాస్ట్లు</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">ఎపిసోడ్లు</string>+ <string name="assisted_curation_search_song" formatted="false">పాట</string>+ <string name="album" formatted="false">ఆల్బమ్</string>+ <string name="album_type_podcast" formatted="false">పాడ్కాస్ట్</string>+ <string name="recently_played_user_profile" formatted="false">ప్రొఫైల్</string>+ <string name="connect_device_menu_logout" formatted="false">లాగ్ అవుట్ చేయి</string>+ <string name="library_search_text_hint" formatted="false">మీ లైబ్రెరీలో వెతకండి</string>+ <string name="account_title" formatted="false">అకౌంట్</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">అనుసరించిన ఆర్టిస్ట్లు</string>+ <string name="settings_item_crossfade_title" formatted="false">క్రాస్ఫేడ్</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d సె</string>+ <string name="local_files_title" formatted="false">స్థానిక ఫైల్స్</string>+ <string name="local_files_empty_section_title" formatted="false">మీ స్వంత ఆడియో ఫైల్స్ను మీ లైబ్రరీకి చేర్చండి</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Spotifyలో లేని పాట లేదా వ్యక్తిగత పాడ్కాస్ట్ ఉందా?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">మీ ఆడియో ఫైల్స్ ఇక్కడ కనిపిస్తాయి</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">యాక్సెస్ ఇవ్వండి</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">సెట్టింగ్లకు వెళ్లండి</string>+ <string name="context_menu_download" formatted="false">డౌన్లోడ్</string>+ <string name="context_menu_undownload" formatted="false">డౌన్లోడ్ తొలగించండి</string>+ <string name="collection_downloaded" formatted="false">డౌన్లోడ్ చేయబడినవి</string>+ <string name="download_badge_downloaded_content_description" formatted="false">డౌన్లోడ్ చేయబడినవి</string>+ <string name="download_badge_downloading_content_description" formatted="false">డౌన్లోడ్ అవుతుంది</string>+ <string name="download_badge_error_content_description" formatted="false">డౌన్లోడ్ విఫలమైంది</string>+ <string name="download_notification_downloading" formatted="false">డౌన్లోడ్ అవుతుంది…</string>+ <string name="toast_undownload" formatted="false">డౌన్లోడ్ తీసివేయబడింది.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">డౌన్లోడ్ల నుండి తీసివేయాలా?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">మీరు దీనిని ఆఫ్లైన్లో ప్లే చేయలేరు.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">తీసివేయండి</string>+ <string name="settings_item_remove_downloads_title" formatted="false">అన్ని డౌన్లోడ్లను తీసివేయండి</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">అన్ని డౌన్లోడ్లను తీసివేయాలా?</string>+ <string name="album_type_album" formatted="false">ఆల్బమ్</string>+ <string name="album_type_single" formatted="false">సింగిల్</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">సంకలనం</string>+ <string name="assisted_curation_search_playlist" formatted="false">ప్లేలిస్ట్</string>+ <string name="assisted_curation_search_filter_top" formatted="false">టాప్</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">పాటలు</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">ఆర్టిస్ట్లు</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">ఆల్బమ్లు</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">ప్లేలిస్ట్లు</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">ఫిల్టర్ను క్లియర్ చేయండి</string>+ <string name="ad_category_title_music" formatted="false">మ్యూజిక్</string>+ <string name="made_for_you_hub_title" formatted="false">మీ కోసం రూపొందించబడింది</string>+ <string name="settings_item_app_language_title" formatted="false">యాప్ భాష</string>+ <string name="create_menu_item_folder_title" formatted="false">ఫోల్డర్</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">కొత్త ఫోల్డర్</string>+ <string name="context_menu_rename_folder" formatted="false">ఫోల్డర్ పేరు మార్చండి</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">ఫోల్డర్ పేరు</string>+ <string name="create_playlist_content_description" formatted="false">ఒక ప్లేలిస్ట్ రూపొందించండి</string>+ <string name="actions_picker_delete" formatted="false">తొలగించండి</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">వీటి ఆధారంగా క్రమబద్ధీకరించండి</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">ఆల్పాబెటికల్</string>+ <string name="your_library_sort_order_creator" formatted="false">క్రియేటర్</string>+ <string name="your_library_sort_order_custom" formatted="false">అనుకూల ఆర్డర్</string>+ <string name="settings_item_version_title" formatted="false">వెర్షన్</string>+ <string name="context_menu_go_to_song_radio" formatted="false">పాటల రేడియోకి వెళ్ళండి</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">లైక్ చేసిన పాటలలో కనుగొనండి</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">ప్లేలిస్ట్లో కనుగొనండి</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\"ను కనుగొనలేకపోయాము</string>+</resources>diff --git a/base/app/src/main/res/values-th/spotify_plurals.xml b/base/app/src/main/res/values-th/spotify_plurals.xmlnew file mode 100644index 00000000..79b8555e--- /dev/null+++ b/base/app/src/main/res/values-th/spotify_plurals.xml@@ -0,0 +1,16 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="other">%1$d เพลง</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="other">บันทึก %1$,d ครั้ง</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="other">%1$s เพลย์ลิสต์</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="other">%1$s เพลง</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-th/spotify_strings.xml b/base/app/src/main/res/values-th/spotify_strings.xmlnew file mode 100644index 00000000..1d4d7bff--- /dev/null+++ b/base/app/src/main/res/values-th/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">เพิ่มไปยัง \"เพลงที่ถูกใจ\"</string>+ <string name="collection_liked_songs_title" formatted="false">เพลงที่ถูกใจ</string>+ <string name="context_menu_add_to_playlist" formatted="false">เพิ่มเข้าเพลย์ลิสต์</string>+ <string name="context_menu_play_next" formatted="false">เล่นถัดไป</string>+ <string name="context_menu_add_to_queue" formatted="false">เพิ่มในคิว</string>+ <string name="context_menu_go_to_queue" formatted="false">ไปที่คิว</string>+ <string name="context_menu_browse_album" formatted="false">ไปที่อัลบั้ม</string>+ <string name="context_menu_browse_artist" formatted="false">ไปที่ศิลปิน</string>+ <string name="context_menu_share" formatted="false">แชร์</string>+ <string name="context_menu_sleep_timer" formatted="false">ตั้งเวลาหยุดเล่น</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">ปิดตัวตั้งเวลา</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">สิ้นสุดแทร็ก</string>+ <string name="snackbar_added_to_queue" formatted="false">เพิ่มในคิวแล้ว</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">เพิ่มไปยังเพลงที่ถูกใจแล้ว</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">ลบออกจาก \"เพลงที่ถูกใจ\" แล้ว</string>+ <string name="content_description_context_menu" formatted="false">ตัวเลือกเพิ่มเติม</string>+ <string name="close_button_content_description" formatted="false">ปิด</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">จำนวนการบันทึกใน</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">เพลย์ลิสต์ใหม่</string>+ <string name="add_to_playlist_button_cancel" formatted="false">ยกเลิก</string>+ <string name="create_playlist_create_button" formatted="false">สร้าง</string>+ <string name="lyrics_card_title" formatted="false">เนื้อเพลง</string>+ <string name="lyrics_card_title_preview" formatted="false">ตัวอย่างเนื้อเพลง</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">แสดงเนื้อเพลง</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">เปิดเนื้อเพลงแบบเต็มจอ</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">แชร์เนื้อเพลง</string>+ <string name="lyrics_credential_note" formatted="false">เนื้อเพลงโดย %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">แชร์</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">แปล</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">ปิดเนื้อเพลง</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">แปลเนื้อเพลง</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">หยุดการแปลเนื้อเพลง</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">อืมม เราไม่รู้เนื้อเพลงของเพลงนี้</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">เนื้อเพลงเหล่านี้ยังไม่ได้ซิงค์เวลา</string>+ <string name="av_switch_to_video" formatted="false">สลับเป็นวิดีโอ</string>+ <string name="av_switch_to_audio" formatted="false">สลับเป็นเสียง</string>+ <string name="av_content_desc" formatted="false">สลับระหว่างเสียงกับวิดีโอ</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">หน้าหลัก</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">ค้นหา</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">คอลเลกชันของคุณ</string>+ <string name="search_header_field_hint" formatted="false">คุณต้องการฟังอะไร</string>+ <string name="filter_chip_all_label" formatted="false">ทั้งหมด</string>+ <string name="recents_content_filter_music" formatted="false">เพลง</string>+ <string name="ad_category_title_podcasts" formatted="false">พอดแคสต์</string>+ <string name="audiobooks_title" formatted="false">หนังสือเสียง</string>+ <string name="artist_popular_tracks" formatted="false">ยอดนิยม</string>+ <string name="curation_button_follow_state_text" formatted="false">ติดตาม</string>+ <string name="curation_button_following_state_text" formatted="false">กำลังติดตาม</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">ศิลปิน</string>+ <string name="connect_phone_is_self" formatted="false">โทรศัพท์เครื่องนี้</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">ภาพวนซ้ำสั้นๆ ขณะที่เพลงกำลังเล่น</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">ไว้ทีหลัง</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">อัปเดต</string>+ <string name="context_type_description_play_queue" formatted="false">กำลังเล่นจากคิว</string>+ <string name="context_type_description_collection_your_library" formatted="false">กำลังเล่นจากคอลเลกชันของคุณ</string>+ <string name="context_type_description_playlist" formatted="false">กำลังเล่นจากเพลย์ลิสต์</string>+ <string name="context_type_description_album" formatted="false">กำลังเล่นจากอัลบั้ม</string>+ <string name="context_type_description_artist" formatted="false">กำลังเล่นจากศิลปิน</string>+ <string name="context_type_description_show" formatted="false">กำลังเล่นจากพอดแคสต์</string>+ <string name="context_type_description_search" formatted="false">กำลังเล่นจากการค้นหา</string>+ <string name="default_notification_channel_name" formatted="false">กำลังเล่น</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">อุปกรณ์</string>+ <string name="action_share_label" formatted="false">แชร์</string>+ <string name="action_queue_label" formatted="false">คิว</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 ชั่วโมง</string>+ <string name="curation_actions_edit_button_title" formatted="false">แก้ไข</string>+ <string name="content_description_pause_button" formatted="false">หยุดชั่วคราว</string>+ <string name="content_description_play_button" formatted="false">เล่น</string>+ <string name="play_mode_item_shuffle_title" formatted="false">เล่นแบบสุ่ม</string>+ <string name="np_content_desc_repeat" formatted="false">เล่นซ้ำ</string>+ <string name="np_content_desc_sleep_timer" formatted="false">ตั้งเวลาหยุดเล่น</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">ลบ</string>+ <string name="edit_playlist_items_move_chip" formatted="false">ย้าย</string>+ <string name="bottom_actions_close" formatted="false">ปิด</string>+ <string name="add_to_queue_action_content_description" formatted="false">เพิ่มในคิว</string>+ <string name="curation_button_saved_text" formatted="false">บันทึกแล้ว</string>+ <string name="np_content_desc_prev" formatted="false">ก่อนหน้า</string>+ <string name="np_content_desc_next" formatted="false">ถัดไป</string>+ <string name="accessibility_navigate_back" formatted="false">ย้อนกลับ</string>+ <string name="monthly_listeners_text" formatted="false">ผู้ฟังต่อเดือน %1$s คน</string>+ <string name="profile_bio_show_less" formatted="false">แสดงน้อยลง</string>+ <string name="audiobook_series_see_more_button" formatted="false">แสดงเพิ่มเติม</string>+ <string name="popular_releases_section_title" formatted="false">ผลงานยอดนิยม</string>+ <string name="creator_biography_section_title" formatted="false">เกี่ยวกับ</string>+ <string name="fans_also_like_section_title" formatted="false">แฟนๆ ยังชื่นชอบ</string>+ <string name="appears_on_section_title" formatted="false">มีผลงานใน</string>+ <string name="composer_section_button_show_all" formatted="false">แสดงทั้งหมด</string>+ <string name="releases_title" formatted="false">ผลงาน</string>+ <string name="artist_releases_albums" formatted="false">อัลบั้ม</string>+ <string name="artist_releases_singles" formatted="false">ซิงเกิลและ EP</string>+ <string name="latest_release_title" formatted="false">ผลงานล่าสุด</string>+ <string name="artist_subtitle" formatted="false">ศิลปิน</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">การค้นหาล่าสุด</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">ล้าง</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">พอดแคสต์</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">ตอน</string>+ <string name="assisted_curation_search_song" formatted="false">เพลง</string>+ <string name="album" formatted="false">อัลบั้ม</string>+ <string name="album_type_podcast" formatted="false">พอดแคสต์</string>+ <string name="recently_played_user_profile" formatted="false">โปรไฟล์</string>+ <string name="connect_device_menu_logout" formatted="false">ออกจากระบบ</string>+ <string name="library_search_text_hint" formatted="false">ค้นหาในคอลเลกชันของคุณ</string>+ <string name="account_title" formatted="false">บัญชี</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">ศิลปินที่ติดตาม</string>+ <string name="settings_item_crossfade_title" formatted="false">ครอสเฟด</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d วิ</string>+ <string name="local_files_title" formatted="false">ไฟล์ในเครื่อง</string>+ <string name="local_files_empty_section_title" formatted="false">เพิ่มไฟล์เสียงลงในคอลเลกชันของคุณ</string>+ <string name="local_files_empty_section_subtitle" formatted="false">หากอยากได้เพลงหรือพอดแคสต์ส่วนตัวที่ไม่มีบน Spotify</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">ไฟล์เสียงของคุณจะปรากฏที่นี่</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">อนุญาตการเข้าถึง</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">ไปที่การตั้งค่า</string>+ <string name="context_menu_download" formatted="false">ดาวน์โหลด</string>+ <string name="context_menu_undownload" formatted="false">ลบรายการดาวน์โหลด</string>+ <string name="collection_downloaded" formatted="false">ดาวน์โหลดแล้ว</string>+ <string name="download_badge_downloaded_content_description" formatted="false">ดาวน์โหลดแล้ว</string>+ <string name="download_badge_downloading_content_description" formatted="false">กำลังดาวน์โหลด</string>+ <string name="download_badge_error_content_description" formatted="false">ดาวน์โหลดไม่สำเร็จ</string>+ <string name="download_notification_downloading" formatted="false">กำลังดาวน์โหลด…</string>+ <string name="toast_undownload" formatted="false">ลบเนื้อหาที่ดาวน์โหลดออกแล้ว</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">ลบออกจากรายการดาวน์โหลดใช่ไหม</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">คุณจะไม่สามารถเล่นรายการนี้แบบออฟไลน์ได้</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">ลบ</string>+ <string name="settings_item_remove_downloads_title" formatted="false">ลบรายการดาวน์โหลดทั้งหมด</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">ลบรายการดาวน์โหลดทั้งหมดไหม</string>+ <string name="album_type_album" formatted="false">อัลบั้ม</string>+ <string name="album_type_single" formatted="false">ซิงเกิล</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">รวมเพลง</string>+ <string name="assisted_curation_search_playlist" formatted="false">เพลย์ลิสต์</string>+ <string name="assisted_curation_search_filter_top" formatted="false">ยอดนิยม</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">เพลง</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">ศิลปิน</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">อัลบั้ม</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">เพลย์ลิสต์</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">ล้างตัวกรอง</string>+ <string name="ad_category_title_music" formatted="false">เพลง</string>+ <string name="made_for_you_hub_title" formatted="false">จัดทำขึ้นเพื่อคุณ</string>+ <string name="settings_item_app_language_title" formatted="false">ภาษาของแอป</string>+ <string name="create_menu_item_folder_title" formatted="false">โฟลเดอร์</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">โฟลเดอร์ใหม่</string>+ <string name="context_menu_rename_folder" formatted="false">เปลี่ยนชื่อโฟลเดอร์</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">ชื่อโฟลเดอร์</string>+ <string name="create_playlist_content_description" formatted="false">สร้างเพลย์ลิสต์</string>+ <string name="actions_picker_delete" formatted="false">ลบ</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">เรียงตาม</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">เรียงตามลำดับอักษร</string>+ <string name="your_library_sort_order_creator" formatted="false">ครีเอเตอร์</string>+ <string name="your_library_sort_order_custom" formatted="false">การจัดเรียงที่กำหนดเอง</string>+ <string name="settings_item_version_title" formatted="false">เวอร์ชัน</string>+ <string name="context_menu_go_to_song_radio" formatted="false">ไปที่โหมดวิทยุของเพลง</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">หาในเพลงที่ถูกใจ</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">ค้นหาในเพลย์ลิสต์</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">ไม่พบ \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-tl/spotify_plurals.xml b/base/app/src/main/res/values-tl/spotify_plurals.xmlnew file mode 100644index 00000000..308c7f77--- /dev/null+++ b/base/app/src/main/res/values-tl/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d kanta</item>+ <item quantity="other">%1$d kanta</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d save</item>+ <item quantity="other">%1$,d save</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="other">%1$s playlist</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s kanta</item>+ <item quantity="other">%1$s kanta</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-tl/spotify_strings.xml b/base/app/src/main/res/values-tl/spotify_strings.xmlnew file mode 100644index 00000000..7c28eef4--- /dev/null+++ b/base/app/src/main/res/values-tl/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Idagdag sa Mga Ni-like na Kanta</string>+ <string name="collection_liked_songs_title" formatted="false">Mga Ni-like na Kanta</string>+ <string name="context_menu_add_to_playlist" formatted="false">Idagdag sa Playlist</string>+ <string name="context_menu_play_next" formatted="false">I-play ang susunod</string>+ <string name="context_menu_add_to_queue" formatted="false">Idagdag sa Queue</string>+ <string name="context_menu_go_to_queue" formatted="false">Pumunta sa Queue</string>+ <string name="context_menu_browse_album" formatted="false">Pumunta sa album</string>+ <string name="context_menu_browse_artist" formatted="false">Pumunta sa artist</string>+ <string name="context_menu_share" formatted="false">I-share</string>+ <string name="context_menu_sleep_timer" formatted="false">Sleep timer</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">I-off ang timer</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Katapusan ng track</string>+ <string name="snackbar_added_to_queue" formatted="false">Idinagdag sa Queue</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Idinagdag sa Mga Ni-like na Kanta.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Inalis sa mga Ni-like na Kanta.</string>+ <string name="content_description_context_menu" formatted="false">Iba pang option</string>+ <string name="close_button_content_description" formatted="false">Isara</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Naka-save sa</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Bagong playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">I-cancel</string>+ <string name="create_playlist_create_button" formatted="false">Gumawa</string>+ <string name="lyrics_card_title" formatted="false">Lyrics</string>+ <string name="lyrics_card_title_preview" formatted="false">Preview ng lyrics</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Ipakita ang lyrics</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Buksan ang full screen lyrics</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">I-share ang lyrics</string>+ <string name="lyrics_credential_note" formatted="false">Galing sa %1$s ang lyrics</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">I-share</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">I-translate</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Isara ang lyrics</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">I-translate ang lyrics</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Huwag nang i-translate ang lyrics</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Hindi namin alam ang lyrics ng isang ito.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Hindi pa time-synced ang lyrics na \'to.</string>+ <string name="av_switch_to_video" formatted="false">Lumipat sa video</string>+ <string name="av_switch_to_audio" formatted="false">Lumipat sa audio</string>+ <string name="av_content_desc" formatted="false">Mag-toggle sa audio at video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Home</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Maghanap</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Library Mo</string>+ <string name="search_header_field_hint" formatted="false">Ano\'ng gusto mong pakinggan?</string>+ <string name="filter_chip_all_label" formatted="false">Lahat</string>+ <string name="recents_content_filter_music" formatted="false">Music</string>+ <string name="ad_category_title_podcasts" formatted="false">Mga Podcast</string>+ <string name="audiobooks_title" formatted="false">Mga Audiobook</string>+ <string name="artist_popular_tracks" formatted="false">Sikat</string>+ <string name="curation_button_follow_state_text" formatted="false">I-follow</string>+ <string name="curation_button_following_state_text" formatted="false">Fina-follow</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artist</string>+ <string name="connect_phone_is_self" formatted="false">Phone na \'to</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Maiikli at naglo-loop na visual kapag may nagpe-play na kanta.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Hindi ngayon</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Mag-update</string>+ <string name="context_type_description_play_queue" formatted="false">Nagpe-play mula sa Play Queue</string>+ <string name="context_type_description_collection_your_library" formatted="false">Nagpe-play mula sa Library Mo</string>+ <string name="context_type_description_playlist" formatted="false">Nagpe-play mula sa Playlist</string>+ <string name="context_type_description_album" formatted="false">Nagpe-play mula sa Album</string>+ <string name="context_type_description_artist" formatted="false">Nagpe-play mula sa Artist</string>+ <string name="context_type_description_show" formatted="false">Nagpe-play mula sa Podcast</string>+ <string name="context_type_description_search" formatted="false">Nagpe-play mula sa Search</string>+ <string name="default_notification_channel_name" formatted="false">Nagpi-play ngayon</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Mga Device</string>+ <string name="action_share_label" formatted="false">I-share</string>+ <string name="action_queue_label" formatted="false">Queue</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 hour</string>+ <string name="curation_actions_edit_button_title" formatted="false">I-edit</string>+ <string name="content_description_pause_button" formatted="false">I-pause</string>+ <string name="content_description_play_button" formatted="false">I-play</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Mag-shuffle</string>+ <string name="np_content_desc_repeat" formatted="false">Ulitin</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Sleep timer</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Alisin</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Ilipat</string>+ <string name="bottom_actions_close" formatted="false">Isara</string>+ <string name="add_to_queue_action_content_description" formatted="false">Idagdag sa queue</string>+ <string name="curation_button_saved_text" formatted="false">Na-save</string>+ <string name="np_content_desc_prev" formatted="false">Nauna</string>+ <string name="np_content_desc_next" formatted="false">Susunod</string>+ <string name="accessibility_navigate_back" formatted="false">Bumalik</string>+ <string name="monthly_listeners_text" formatted="false">%1$s listener buwan-buwan</string>+ <string name="profile_bio_show_less" formatted="false">Bawasan ang ipinapakita</string>+ <string name="audiobook_series_see_more_button" formatted="false">Magpakita pa</string>+ <string name="popular_releases_section_title" formatted="false">Mga sikat na release</string>+ <string name="creator_biography_section_title" formatted="false">Tungkol Dito</string>+ <string name="fans_also_like_section_title" formatted="false">Gusto rin ng fans</string>+ <string name="appears_on_section_title" formatted="false">Maririnig din sa</string>+ <string name="composer_section_button_show_all" formatted="false">Ipakita lahat</string>+ <string name="releases_title" formatted="false">Mga Release</string>+ <string name="artist_releases_albums" formatted="false">Mga Album</string>+ <string name="artist_releases_singles" formatted="false">Mga Single at EP</string>+ <string name="latest_release_title" formatted="false">Pinakabagong release</string>+ <string name="artist_subtitle" formatted="false">Artist</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Mga kaka-search lang</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">I-clear</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Mga Podcast</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Mga Episode</string>+ <string name="assisted_curation_search_song" formatted="false">Kanta</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profile</string>+ <string name="connect_device_menu_logout" formatted="false">Mag-log out</string>+ <string name="library_search_text_hint" formatted="false">Maghanap sa Library Mo</string>+ <string name="account_title" formatted="false">Account</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Mga fina-follow na artist</string>+ <string name="settings_item_crossfade_title" formatted="false">Crossfade</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Mga Local File</string>+ <string name="local_files_empty_section_title" formatted="false">Magdagdag ng sarili mong mga audio file sa Library Mo</string>+ <string name="local_files_empty_section_subtitle" formatted="false">May kanta o personal na podcast na wala sa Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Dito lalabas ang mga audio file mo</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Bigyan ng access</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Pumunta sa Settings</string>+ <string name="context_menu_download" formatted="false">I-download</string>+ <string name="context_menu_undownload" formatted="false">Alisin ang download</string>+ <string name="collection_downloaded" formatted="false">Na-download</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Na-download</string>+ <string name="download_badge_downloading_content_description" formatted="false">Nagda-download</string>+ <string name="download_badge_error_content_description" formatted="false">Hindi na-download</string>+ <string name="download_notification_downloading" formatted="false">Nagda-download…</string>+ <string name="toast_undownload" formatted="false">Naalis ang download.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Alisin sa mga download?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Hindi mo \'to mape-play offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Alisin</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Alisin lahat ng download</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Alisin lahat ng download?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Compilation</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Top</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Mga Kanta</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Mga Artist</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Mga Album</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Mga Playlist</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">I-clear ang filter</string>+ <string name="ad_category_title_music" formatted="false">Music</string>+ <string name="made_for_you_hub_title" formatted="false">Para sa \'Yo</string>+ <string name="settings_item_app_language_title" formatted="false">Language ng app</string>+ <string name="create_menu_item_folder_title" formatted="false">Folder</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Bagong folder</string>+ <string name="context_menu_rename_folder" formatted="false">I-rename ang folder</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Pangalan ng folder</string>+ <string name="create_playlist_content_description" formatted="false">Gumawa ng playlist</string>+ <string name="actions_picker_delete" formatted="false">I-delete</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">I-sort ayon sa</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alphabetical</string>+ <string name="your_library_sort_order_creator" formatted="false">Creator</string>+ <string name="your_library_sort_order_custom" formatted="false">Custom na order</string>+ <string name="settings_item_version_title" formatted="false">Version</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Pumunta sa song radio</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Hanapin sa Mga Ni-like na Kanta</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Hanapin sa playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Hindi makita ang \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-tr/spotify_plurals.xml b/base/app/src/main/res/values-tr/spotify_plurals.xmlnew file mode 100644index 00000000..e838fd99--- /dev/null+++ b/base/app/src/main/res/values-tr/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d şarkı</item>+ <item quantity="other">%1$d şarkı</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d kaydetme</item>+ <item quantity="other">%1$,d kaydetme</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s çalma listesi</item>+ <item quantity="other">%1$s çalma listesi</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s şarkı</item>+ <item quantity="other">%1$s şarkı</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-tr/spotify_strings.xml b/base/app/src/main/res/values-tr/spotify_strings.xmlnew file mode 100644index 00000000..36e194e3--- /dev/null+++ b/base/app/src/main/res/values-tr/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Beğenilen Şarkılar\'a ekle</string>+ <string name="collection_liked_songs_title" formatted="false">Beğenilen Şarkılar</string>+ <string name="context_menu_add_to_playlist" formatted="false">Çalma listesine ekle</string>+ <string name="context_menu_play_next" formatted="false">Sonrakini çal</string>+ <string name="context_menu_add_to_queue" formatted="false">Sıraya Ekle</string>+ <string name="context_menu_go_to_queue" formatted="false">Çalma Sırasına git</string>+ <string name="context_menu_browse_album" formatted="false">Albüme git</string>+ <string name="context_menu_browse_artist" formatted="false">Sanatçıya git</string>+ <string name="context_menu_share" formatted="false">Paylaş</string>+ <string name="context_menu_sleep_timer" formatted="false">Otomatik kapatma</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Kronometreyi kapat</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Parça sonu</string>+ <string name="snackbar_added_to_queue" formatted="false">Sıraya eklendi</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Beğenilen Şarkılar\'a eklendi.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Beğenilen Şarkılar\'dan kaldırıldı.</string>+ <string name="content_description_context_menu" formatted="false">Diğer seçenekler</string>+ <string name="close_button_content_description" formatted="false">Kapat</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Kaydedildiği çalma listesi</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Yeni çalma listesi</string>+ <string name="add_to_playlist_button_cancel" formatted="false">İptal</string>+ <string name="create_playlist_create_button" formatted="false">Oluştur</string>+ <string name="lyrics_card_title" formatted="false">Şarkı sözleri</string>+ <string name="lyrics_card_title_preview" formatted="false">Şarkı Sözleri önizlemesi</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Şarkı sözlerini göster</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Şarkı sözlerini tam ekranda açar</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Şarkı sözlerini paylaş</string>+ <string name="lyrics_credential_note" formatted="false">Şarkı sözlerini sağlayan: %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Paylaş</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Çevir</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Şarkı sözlerini kapat</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Şarkı sözlerini çevir</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Şarkı sözlerini çevirmeyi durdur</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Maalesef bu şarkının sözlerini bilmiyoruz.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Bu şarkının sözleri henüz şarkıyla eş zamanlı değil.</string>+ <string name="av_switch_to_video" formatted="false">Videoya geç</string>+ <string name="av_switch_to_audio" formatted="false">Sese geç</string>+ <string name="av_content_desc" formatted="false">Ses ile video arasında geçiş yapar</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Ana sayfa</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Ara</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Kitaplığın</string>+ <string name="search_header_field_hint" formatted="false">Ne dinlemek istiyorsun?</string>+ <string name="filter_chip_all_label" formatted="false">Tümü</string>+ <string name="recents_content_filter_music" formatted="false">Müzik</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcast\'ler</string>+ <string name="audiobooks_title" formatted="false">Sesli kitaplar</string>+ <string name="artist_popular_tracks" formatted="false">Popüler</string>+ <string name="curation_button_follow_state_text" formatted="false">Takip Et</string>+ <string name="curation_button_following_state_text" formatted="false">Takip Ediliyor</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Sanatçı</string>+ <string name="connect_phone_is_self" formatted="false">Bu telefon</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Şarkı çalarken görüntülenen kısa, dönen görseller.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Şimdi değil</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Güncelle</string>+ <string name="context_type_description_play_queue" formatted="false">Çalma Sırası\'ndan Çalınıyor</string>+ <string name="context_type_description_collection_your_library" formatted="false">Kitaplığın\'dan çalınıyor</string>+ <string name="context_type_description_playlist" formatted="false">Çalma Listesinden çalınıyor</string>+ <string name="context_type_description_album" formatted="false">Albümden çalınıyor</string>+ <string name="context_type_description_artist" formatted="false">Sanatçıdan çalınıyor</string>+ <string name="context_type_description_show" formatted="false">Podcast\'ten Çalınıyor</string>+ <string name="context_type_description_search" formatted="false">Arama sonuçlarından çalınıyor</string>+ <string name="default_notification_channel_name" formatted="false">Şimdi oynatılıyor</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Cihazlar</string>+ <string name="action_share_label" formatted="false">Paylaş</string>+ <string name="action_queue_label" formatted="false">Sıraya ekle</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 saat</string>+ <string name="curation_actions_edit_button_title" formatted="false">Düzenle</string>+ <string name="content_description_pause_button" formatted="false">Duraklat</string>+ <string name="content_description_play_button" formatted="false">Çal</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Karışık Çal</string>+ <string name="np_content_desc_repeat" formatted="false">Tekrarla</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Uyku modu zamanlayıcı</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Kaldır</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Taşı</string>+ <string name="bottom_actions_close" formatted="false">Kapat</string>+ <string name="add_to_queue_action_content_description" formatted="false">Sıraya ekle</string>+ <string name="curation_button_saved_text" formatted="false">Kaydedildi</string>+ <string name="np_content_desc_prev" formatted="false">Önceki</string>+ <string name="np_content_desc_next" formatted="false">Sonraki</string>+ <string name="accessibility_navigate_back" formatted="false">Geri</string>+ <string name="monthly_listeners_text" formatted="false">Aylık %1$s dinleyici</string>+ <string name="profile_bio_show_less" formatted="false">Daha az göster</string>+ <string name="audiobook_series_see_more_button" formatted="false">Daha fazla göster</string>+ <string name="popular_releases_section_title" formatted="false">Popüler yayınlar</string>+ <string name="creator_biography_section_title" formatted="false">Hakkında</string>+ <string name="fans_also_like_section_title" formatted="false">Hayranların beğendiği diğer sanatçılar</string>+ <string name="appears_on_section_title" formatted="false">Yer aldığı albümler</string>+ <string name="composer_section_button_show_all" formatted="false">Tümünü göster</string>+ <string name="releases_title" formatted="false">Çıkanlar</string>+ <string name="artist_releases_albums" formatted="false">Albümler</string>+ <string name="artist_releases_singles" formatted="false">Single\'lar ve EP\'ler</string>+ <string name="latest_release_title" formatted="false">Son çıkan</string>+ <string name="artist_subtitle" formatted="false">Sanatçı</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Yakındaki aramalar</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Sil</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcast\'ler</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Bölümler</string>+ <string name="assisted_curation_search_song" formatted="false">Şarkı</string>+ <string name="album" formatted="false">Albüm</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profil</string>+ <string name="connect_device_menu_logout" formatted="false">Oturumu kapat</string>+ <string name="library_search_text_hint" formatted="false">Kitaplığın\'da Ara</string>+ <string name="account_title" formatted="false">Hesap</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Takip edilen sanatçılar</string>+ <string name="settings_item_crossfade_title" formatted="false">Sesi azaltarak geç</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d sn.</string>+ <string name="local_files_title" formatted="false">Yerel Dosyalar</string>+ <string name="local_files_empty_section_title" formatted="false">Kendi ses dosyalarını Kitaplığın\'a ekle</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Spotify\'da yer almayan bir şarkın veya kişisel podcast\'in mi var?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Ses dosyaların burada görünür</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Erişim ver</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Ayarlar\'a git</string>+ <string name="context_menu_download" formatted="false">İndir</string>+ <string name="context_menu_undownload" formatted="false">İndirilenlerden sil</string>+ <string name="collection_downloaded" formatted="false">İndirilenler</string>+ <string name="download_badge_downloaded_content_description" formatted="false">İndirilenler</string>+ <string name="download_badge_downloading_content_description" formatted="false">İndiriliyor</string>+ <string name="download_badge_error_content_description" formatted="false">İndirme başarısız</string>+ <string name="download_notification_downloading" formatted="false">İndiriliyor…</string>+ <string name="toast_undownload" formatted="false">İndirme silindi.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">İndirilenler silinsin mi?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Bunu çevrimdışı çalman mümkün olmayacak.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Kaldır</string>+ <string name="settings_item_remove_downloads_title" formatted="false">İndirilenlerin tümünü sil</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">İndirilenlerin tümü silinsin mi?</string>+ <string name="album_type_album" formatted="false">Albüm</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Derleme</string>+ <string name="assisted_curation_search_playlist" formatted="false">Çalma Listesi</string>+ <string name="assisted_curation_search_filter_top" formatted="false">En İyi Sonuçlar</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Şarkılar</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Sanatçılar</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albümler</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Çalma listeleri</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Filtreyi temizle</string>+ <string name="ad_category_title_music" formatted="false">Müzik</string>+ <string name="made_for_you_hub_title" formatted="false">Senin için hazırlandı</string>+ <string name="settings_item_app_language_title" formatted="false">Uygulama dili</string>+ <string name="create_menu_item_folder_title" formatted="false">Klasör</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Yeni klasör</string>+ <string name="context_menu_rename_folder" formatted="false">Klasörü yeniden adlandır</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Klasör adı</string>+ <string name="create_playlist_content_description" formatted="false">Çalma listesi oluşturur</string>+ <string name="actions_picker_delete" formatted="false">Sil</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Şuna göre sırala:</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alfabetik</string>+ <string name="your_library_sort_order_creator" formatted="false">Oluşturan</string>+ <string name="your_library_sort_order_custom" formatted="false">Özel sıralama</string>+ <string name="settings_item_version_title" formatted="false">Sürüm</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Şarkı radyosuna git</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Beğenilen Şarkılar\'da bul</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Çalma listesinde bul</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\"%1$s\" bulunamadı</string>+</resources>diff --git a/base/app/src/main/res/values-tr/strings.xml b/base/app/src/main/res/values-tr/strings.xmlnew file mode 100644index 00000000..ff0ad524--- /dev/null+++ b/base/app/src/main/res/values-tr/strings.xml@@ -0,0 +1,37 @@+<resources>+ <string name="app_name">Myspoti</string>+ <string name="aa_playlists">Çalma listeleri</string>+ <string name="aa_albums">Albümler</string>+ <string name="aa_artists">Sanatçılar</string>+ <string name="aa_podcasts">Podcast\'ler</string>+ <string name="settings_amoled_theme">AMOLED Teması</string>+ <string name="settings_amoled_theme_subtitle">Pil tasarrufu için tamamen siyah arka plan</string>+ <string name="settings_lyrics_style_spotify_default">Spotify Varsayılanı</string>+ <string name="settings_lyrics_style_fullscreen">Tam Ekran (Albüm Renkleri)</string>+ <string name="settings_lyrics_style_compact">Kompakt</string>+ <string name="settings_lyrics_style_karaoke">Karaoke</string>+ <string name="settings_lyrics_style_bold">Kalın Büyük</string>+ <string name="main_update_available">Yeni bir güncelleme mevcut</string>++ <string name="notif_channel_media_name">Medya Oynatma</string>+ <string name="notif_channel_media_description">Myspoti medya oynatma kontrolleri</string>+ <string name="notif_action_previous">Önceki</string>+ <string name="notif_action_next">Sonraki</string>+ <string name="notif_action_play">Oynat</string>+ <string name="notif_action_pause">Duraklat</string>+ <string name="notif_shuffle_enable">Karıştırmayı etkinleştir</string>+ <string name="notif_shuffle_disable">Karıştırmayı devre dışı bırak</string>+ <string name="notif_shuffle_disable_smart">Akıllı karıştırmayı devre dışı bırak</string>+ <string name="notif_action_like">Beğen</string>+ <string name="notif_action_unlike">Beğenmekten vazgeç</string>+ <string name="notif_unknown_name">Bilinmeyen</string>+ <string name="notif_by_artist">%1$s tarafından</string>+ <string name="notif_repeat_disable">Tekrarı devre dışı bırak</string>+ <string name="notif_repeat_disable_one">Birini tekrarlamayı devre dışı bırak</string>+ <string name="notif_repeat_enable">Tekrarı etkinleştir</string>++ <string name="bridge_player_unlocked">Oynatıcının kilidi açıldı</string>+ <string name="bridge_reloading">Yeniden yükleniyor…</string>++ <string name="service_disabled_message">Hizmet etkin değil</string>+</resources>diff --git a/base/app/src/main/res/values-uk/spotify_plurals.xml b/base/app/src/main/res/values-uk/spotify_plurals.xmlnew file mode 100644index 00000000..177d5cde--- /dev/null+++ b/base/app/src/main/res/values-uk/spotify_plurals.xml@@ -0,0 +1,28 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d пісня</item>+ <item quantity="few">%1$d пісні</item>+ <item quantity="many">%1$d пісень</item>+ <item quantity="other">%1$d пісень</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d збереження</item>+ <item quantity="few">%1$,d збереження</item>+ <item quantity="many">%1$,d збережень</item>+ <item quantity="other">%1$,d збережень</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s плейліст</item>+ <item quantity="few">%1$s плейлісти</item>+ <item quantity="many">%1$s плейлістів</item>+ <item quantity="other">%1$s плейлістів</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s пісня</item>+ <item quantity="few">%1$s пісні</item>+ <item quantity="many">%1$s пісень</item>+ <item quantity="other">%1$s пісні</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-uk/spotify_strings.xml b/base/app/src/main/res/values-uk/spotify_strings.xmlnew file mode 100644index 00000000..7721d020--- /dev/null+++ b/base/app/src/main/res/values-uk/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Додати до пісень, що сподобалися</string>+ <string name="collection_liked_songs_title" formatted="false">Пісні, що сподобалися</string>+ <string name="context_menu_add_to_playlist" formatted="false">Додати до плейліста</string>+ <string name="context_menu_play_next" formatted="false">Відтворити далі</string>+ <string name="context_menu_add_to_queue" formatted="false">Додати до черги</string>+ <string name="context_menu_go_to_queue" formatted="false">Переглянути чергу</string>+ <string name="context_menu_browse_album" formatted="false">Перейти до альбому</string>+ <string name="context_menu_browse_artist" formatted="false">Перейти до виконавця</string>+ <string name="context_menu_share" formatted="false">Поділитися</string>+ <string name="context_menu_sleep_timer" formatted="false">Таймер сну</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Вимкнути таймер</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">У кінці треку</string>+ <string name="snackbar_added_to_queue" formatted="false">Додано в чергу</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Додано до пісень, що сподобалися</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Видалено з пісень, що сподобалися</string>+ <string name="content_description_context_menu" formatted="false">Більше варіантів</string>+ <string name="close_button_content_description" formatted="false">Закрити</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Збережено тут:</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Новий плейліст</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Скасувати</string>+ <string name="create_playlist_create_button" formatted="false">Створити</string>+ <string name="lyrics_card_title" formatted="false">Текст</string>+ <string name="lyrics_card_title_preview" formatted="false">Попередній перегляд тексту</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Показати текст</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Відкрити текст на весь екран</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Поділіться текстом</string>+ <string name="lyrics_credential_note" formatted="false">Джерело тексту пісні: %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Поділитися</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Перекласти</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Закрити текст</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Переклад тексту</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Припинити перекладати текст</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Гм… ми не знаємо текст цієї пісні.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Текст поки що не синхронізовано за часом.</string>+ <string name="av_switch_to_video" formatted="false">Перейти на відео</string>+ <string name="av_switch_to_audio" formatted="false">Перейти на аудіо</string>+ <string name="av_content_desc" formatted="false">Перемикання між аудіо та відео</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Головна</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Пошук</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Моя бібліотека</string>+ <string name="search_header_field_hint" formatted="false">Що ви хочете послухати?</string>+ <string name="filter_chip_all_label" formatted="false">Усі</string>+ <string name="recents_content_filter_music" formatted="false">Музика</string>+ <string name="ad_category_title_podcasts" formatted="false">Подкасти</string>+ <string name="audiobooks_title" formatted="false">Аудіокниги</string>+ <string name="artist_popular_tracks" formatted="false">Популярні</string>+ <string name="curation_button_follow_state_text" formatted="false">Підписатися</string>+ <string name="curation_button_following_state_text" formatted="false">Ви підписалися</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Виконавець</string>+ <string name="connect_phone_is_self" formatted="false">Цей телефон</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Короткий повторюваний відеоряд під час відтворення пісні.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Не зараз</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Оновити</string>+ <string name="context_type_description_play_queue" formatted="false">Відтворюється з черги відтворення</string>+ <string name="context_type_description_collection_your_library" formatted="false">Відтворюється з розділу \"Моя бібліотека\"</string>+ <string name="context_type_description_playlist" formatted="false">Відтворюється з плейліста</string>+ <string name="context_type_description_album" formatted="false">Відтворюється з альбому</string>+ <string name="context_type_description_artist" formatted="false">Відтворюється з вмісту виконавця</string>+ <string name="context_type_description_show" formatted="false">Відтворюється аудіо з подкасту</string>+ <string name="context_type_description_search" formatted="false">Відтворюється з пошуку</string>+ <string name="default_notification_channel_name" formatted="false">Зараз відтворюється</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Пристрої</string>+ <string name="action_share_label" formatted="false">Поділитися</string>+ <string name="action_queue_label" formatted="false">Черга</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 година</string>+ <string name="curation_actions_edit_button_title" formatted="false">Змінити</string>+ <string name="content_description_pause_button" formatted="false">Пауза</string>+ <string name="content_description_play_button" formatted="false">Відтворити</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Перемішування</string>+ <string name="np_content_desc_repeat" formatted="false">Повторювати</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Таймер сну</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Видалити</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Перемістити</string>+ <string name="bottom_actions_close" formatted="false">Закрити</string>+ <string name="add_to_queue_action_content_description" formatted="false">Додати до черги</string>+ <string name="curation_button_saved_text" formatted="false">Збережено</string>+ <string name="np_content_desc_prev" formatted="false">Назад</string>+ <string name="np_content_desc_next" formatted="false">Далі</string>+ <string name="accessibility_navigate_back" formatted="false">Назад</string>+ <string name="monthly_listeners_text" formatted="false">%1$s слухачів за місяць</string>+ <string name="profile_bio_show_less" formatted="false">Менше</string>+ <string name="audiobook_series_see_more_button" formatted="false">Більше</string>+ <string name="popular_releases_section_title" formatted="false">Популярні релізи</string>+ <string name="creator_biography_section_title" formatted="false">Докладніше</string>+ <string name="fans_also_like_section_title" formatted="false">Фанам також подобається</string>+ <string name="appears_on_section_title" formatted="false">Інше із цим виконавцем</string>+ <string name="composer_section_button_show_all" formatted="false">Показати всі</string>+ <string name="releases_title" formatted="false">Релізи</string>+ <string name="artist_releases_albums" formatted="false">Альбоми</string>+ <string name="artist_releases_singles" formatted="false">Сингли й невеликі альбоми</string>+ <string name="latest_release_title" formatted="false">Останній реліз</string>+ <string name="artist_subtitle" formatted="false">Виконавець</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Останні пошукові запити</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Очистити</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Подкасти</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Епізоди</string>+ <string name="assisted_curation_search_song" formatted="false">Пісня</string>+ <string name="album" formatted="false">Альбом</string>+ <string name="album_type_podcast" formatted="false">Подкаст</string>+ <string name="recently_played_user_profile" formatted="false">Профіль</string>+ <string name="connect_device_menu_logout" formatted="false">Вийти</string>+ <string name="library_search_text_hint" formatted="false">Шукати в розділі \"Моя бібліотека\"</string>+ <string name="account_title" formatted="false">Акаунт</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Виконавці, на яких ви підписалися</string>+ <string name="settings_item_crossfade_title" formatted="false">Плавний перехід</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d с</string>+ <string name="local_files_title" formatted="false">Локальні файли</string>+ <string name="local_files_empty_section_title" formatted="false">Додавайте власні аудіофайли до своєї бібліотеки</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Маєте пісню чи особистий подкаст, яких немає в Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Тут відображатимуться ваші аудіофайли</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Надати доступ</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Перейти до налаштувань</string>+ <string name="context_menu_download" formatted="false">Завантажити</string>+ <string name="context_menu_undownload" formatted="false">Вилучити із завантажень</string>+ <string name="collection_downloaded" formatted="false">Завантажено</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Завантажено</string>+ <string name="download_badge_downloading_content_description" formatted="false">Завантаження</string>+ <string name="download_badge_error_content_description" formatted="false">Не вдалося завантажити</string>+ <string name="download_notification_downloading" formatted="false">Завантаження…</string>+ <string name="toast_undownload" formatted="false">Завантаження видалено.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Вилучити із завантажень?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Ви не зможете відтворити трек у режимі офлайн.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Вилучити</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Видалити всі завантаження</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Видалити всі завантаження?</string>+ <string name="album_type_album" formatted="false">Альбом</string>+ <string name="album_type_single" formatted="false">Сингл</string>+ <string name="album_type_ep" formatted="false">Мініальбом</string>+ <string name="album_type_compilation" formatted="false">Добірка</string>+ <string name="assisted_curation_search_playlist" formatted="false">Плейліст</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Топ</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Пісні</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Виконавці</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Альбоми</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Плейлісти</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Зняти фільтр</string>+ <string name="ad_category_title_music" formatted="false">Музика</string>+ <string name="made_for_you_hub_title" formatted="false">Для вас</string>+ <string name="settings_item_app_language_title" formatted="false">Мова додатка</string>+ <string name="create_menu_item_folder_title" formatted="false">Папка</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Нова папка</string>+ <string name="context_menu_rename_folder" formatted="false">Перейменувати папку</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Назва папки</string>+ <string name="create_playlist_content_description" formatted="false">Створити плейліст</string>+ <string name="actions_picker_delete" formatted="false">Видалити</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Сортувати</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">В алфавітному порядку</string>+ <string name="your_library_sort_order_creator" formatted="false">Автор</string>+ <string name="your_library_sort_order_custom" formatted="false">Настроюваний порядок</string>+ <string name="settings_item_version_title" formatted="false">Версія</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Перейти до радіо на основі пісні</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Спробуйте знайти в піснях, що сподобалися</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Спробуйте знайти пісні в плейлісті</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">За запитом \"%1$s\" нічого не знайдено</string>+</resources>diff --git a/base/app/src/main/res/values-ur/spotify_plurals.xml b/base/app/src/main/res/values-ur/spotify_plurals.xmlnew file mode 100644index 00000000..8e9298f6--- /dev/null+++ b/base/app/src/main/res/values-ur/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d گانا</item>+ <item quantity="other">%1$d گانے</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d محفوظ کردہ</item>+ <item quantity="other">%1$,d محفوظ کردہ</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s پلے لسٹ</item>+ <item quantity="other">%1$s پلے لسٹس</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s گانا</item>+ <item quantity="other">%1$s گانے</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-ur/spotify_strings.xml b/base/app/src/main/res/values-ur/spotify_strings.xmlnew file mode 100644index 00000000..c8dee47e--- /dev/null+++ b/base/app/src/main/res/values-ur/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">لائیک شدہ گانوں میں شامل کریں</string>+ <string name="collection_liked_songs_title" formatted="false">لائیک کردہ گانے</string>+ <string name="context_menu_add_to_playlist" formatted="false">پلے لسٹ میں شامل کریں</string>+ <string name="context_menu_play_next" formatted="false">اگلا پلے کریں</string>+ <string name="context_menu_add_to_queue" formatted="false">قطار میں شامل کریں</string>+ <string name="context_menu_go_to_queue" formatted="false">قطار میں شامل کریں</string>+ <string name="context_menu_browse_album" formatted="false">البم پر جائیں</string>+ <string name="context_menu_browse_artist" formatted="false">آرٹسٹ پر جائیں</string>+ <string name="context_menu_share" formatted="false">شیئر کریں</string>+ <string name="context_menu_sleep_timer" formatted="false">سلیپ ٹائمر</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">ٹائمر آف کریں</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">ٹریک کا اختتام</string>+ <string name="snackbar_added_to_queue" formatted="false">قطار میں شامل ہوگیا ہے</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">لائیک کردہ گانوں میں شامل ہوگیا ہے۔</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">لائیک کردہ گانوں سے ہٹا دیا گیا ہے۔</string>+ <string name="content_description_context_menu" formatted="false">مزید آپشنز</string>+ <string name="close_button_content_description" formatted="false">بند کریں</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">اس میں محفوظ ہے</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">نئی پلے لسٹ</string>+ <string name="add_to_playlist_button_cancel" formatted="false">منسوخ کریں</string>+ <string name="create_playlist_create_button" formatted="false">بنائیں</string>+ <string name="lyrics_card_title" formatted="false">بول</string>+ <string name="lyrics_card_title_preview" formatted="false">بول کا پیش منظر</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">بول دکھائیں</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">پوری اسکرین پر بول کھولیں</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">بول شیئر کریں</string>+ <string name="lyrics_credential_note" formatted="false">%1$s کی جانب سے فراہم کردہ بول</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">شیئر کریں</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">ترجمہ کریں</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">بول بند کریں</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">بول کا ترجمہ کریں</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">بولوں کا ترجمہ کرنا بند کریں۔</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">ہمم۔ ہمیں اس کے بول نہیں معلوم۔</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">یہ بول ابھی وقت کے لحاظ سے مطابقت پذیر نہیں ہیں۔</string>+ <string name="av_switch_to_video" formatted="false">ویڈیو پر سوئچ کریں</string>+ <string name="av_switch_to_audio" formatted="false">آڈیو پر سوئچ کریں</string>+ <string name="av_content_desc" formatted="false">آڈیو اور ویڈیو کے درمیان ٹوگل کریں</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">ہوم</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">تلاش کریں</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">آپ کی لائبریری</string>+ <string name="search_header_field_hint" formatted="false">آپ کیا سننا چاہتے ہیں؟</string>+ <string name="filter_chip_all_label" formatted="false">سبھی</string>+ <string name="recents_content_filter_music" formatted="false">موسیقی</string>+ <string name="ad_category_title_podcasts" formatted="false">پوڈکاسٹس</string>+ <string name="audiobooks_title" formatted="false">آڈیو بُکس</string>+ <string name="artist_popular_tracks" formatted="false">مقبول</string>+ <string name="curation_button_follow_state_text" formatted="false">فالو کریں</string>+ <string name="curation_button_following_state_text" formatted="false">فالو کر رہے ہیں</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">آرٹسٹ</string>+ <string name="connect_phone_is_self" formatted="false">اس فون</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">گانا پلے ہونے پر مختصر، لوپ والے ویژوئلز۔</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">ابھی نہیں</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">اپ ڈیٹ کریں</string>+ <string name="context_type_description_play_queue" formatted="false">پلے کی قطار سے پلے کیا جا رہا ہے</string>+ <string name="context_type_description_collection_your_library" formatted="false">\'آپ کی لائبریری\' سے پلے کیا جا رہا ہے</string>+ <string name="context_type_description_playlist" formatted="false">پلے لسٹ سے پلے کیا جا رہا ہے</string>+ <string name="context_type_description_album" formatted="false">البم سے پلے کیا جا رہا ہے</string>+ <string name="context_type_description_artist" formatted="false">آرٹسٹ سے پلے کیا جا رہا ہے</string>+ <string name="context_type_description_show" formatted="false">پوڈکاسٹ سے پلے کیا جا رہا ہے</string>+ <string name="context_type_description_search" formatted="false">\'تلاش کریں\' سے پلے کیا جا رہا ہے</string>+ <string name="default_notification_channel_name" formatted="false">ابھی چل رہا ہے</string>+ <string name="label_bluetooth" formatted="false">بلوٹوتھ</string>+ <string name="mr_user_route_category_name" formatted="false">آلات</string>+ <string name="action_share_label" formatted="false">شیئر کریں</string>+ <string name="action_queue_label" formatted="false">قطار</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 گھنٹہ</string>+ <string name="curation_actions_edit_button_title" formatted="false">ترمیم کریں</string>+ <string name="content_description_pause_button" formatted="false">موقوف کریں</string>+ <string name="content_description_play_button" formatted="false">پلے کریں</string>+ <string name="play_mode_item_shuffle_title" formatted="false">شفل کریں</string>+ <string name="np_content_desc_repeat" formatted="false">دہرائیں</string>+ <string name="np_content_desc_sleep_timer" formatted="false">سلیپ ٹائمر</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">ہٹائیں</string>+ <string name="edit_playlist_items_move_chip" formatted="false">منتقل کریں۔</string>+ <string name="bottom_actions_close" formatted="false">بند کریں</string>+ <string name="add_to_queue_action_content_description" formatted="false">قطار میں شامل کریں</string>+ <string name="curation_button_saved_text" formatted="false">محفوظ شدہ</string>+ <string name="np_content_desc_prev" formatted="false">پچھلا</string>+ <string name="np_content_desc_next" formatted="false">اگلا</string>+ <string name="accessibility_navigate_back" formatted="false">پچھلا</string>+ <string name="monthly_listeners_text" formatted="false">%1$s ماہانہ سامعین</string>+ <string name="profile_bio_show_less" formatted="false">کم دکھائیں</string>+ <string name="audiobook_series_see_more_button" formatted="false">مزید دکھائیں</string>+ <string name="popular_releases_section_title" formatted="false">مقبول ریلیزز</string>+ <string name="creator_biography_section_title" formatted="false">بمتعلق</string>+ <string name="fans_also_like_section_title" formatted="false">فینز یہ بھی پسند کرتے ہیں</string>+ <string name="appears_on_section_title" formatted="false">ان میں ہے</string>+ <string name="composer_section_button_show_all" formatted="false">سبھی دکھائیں</string>+ <string name="releases_title" formatted="false">ریلیزز</string>+ <string name="artist_releases_albums" formatted="false">البمز</string>+ <string name="artist_releases_singles" formatted="false">سنگلز اور EPs</string>+ <string name="latest_release_title" formatted="false">تازہ ترین ریلیز</string>+ <string name="artist_subtitle" formatted="false">آرٹسٹ</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">حالیہ تلاشیاں</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">صاف کریں</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">پوڈکاسٹس</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">اقساط</string>+ <string name="assisted_curation_search_song" formatted="false">گانا</string>+ <string name="album" formatted="false">البم</string>+ <string name="album_type_podcast" formatted="false">پوڈکاسٹ</string>+ <string name="recently_played_user_profile" formatted="false">پروفائل</string>+ <string name="connect_device_menu_logout" formatted="false">لاگ آؤٹ کریں</string>+ <string name="library_search_text_hint" formatted="false">آپ کی لائبریری میں تلاش کریں</string>+ <string name="account_title" formatted="false">اکاؤنٹ</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">فالو کردہ آرٹسٹس</string>+ <string name="settings_item_crossfade_title" formatted="false">کراس فیڈ</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d سیکنڈ</string>+ <string name="local_files_title" formatted="false">مقامی فائلز</string>+ <string name="local_files_empty_section_title" formatted="false">آپ کی لائبریری میں اپنی ذاتی آڈیو فائلز شامل کریں</string>+ <string name="local_files_empty_section_subtitle" formatted="false">ایسا کوئی گانا یا ذاتی پوڈکاسٹ ہے جو Spotify پر نہیں ہے؟</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">آپ کی آڈیو فائلز یہاں ظاہر ہوں گی</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">رسائی فراہم کریں</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">سیٹنگز پر جائیں</string>+ <string name="context_menu_download" formatted="false">ڈاؤن لوڈ کریں</string>+ <string name="context_menu_undownload" formatted="false">ڈاؤن لوڈ ہٹائیں</string>+ <string name="collection_downloaded" formatted="false">ڈاؤن لوڈ شدہ</string>+ <string name="download_badge_downloaded_content_description" formatted="false">ڈاؤن لوڈ شدہ</string>+ <string name="download_badge_downloading_content_description" formatted="false">ڈاؤن لوڈنگ جاری ہے</string>+ <string name="download_badge_error_content_description" formatted="false">ڈاؤن لوڈ ناکام ہوگیا</string>+ <string name="download_notification_downloading" formatted="false">ڈاؤن لوڈنگ جاری ہے…</string>+ <string name="toast_undownload" formatted="false">ڈاؤں لوڈ ہٹ گیا ہے۔</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">ڈاؤن لوڈز سے ہٹائیں؟</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">آپ اسے آف لائن پلے نہیں کر پائیں گے۔</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">ہٹائیں</string>+ <string name="settings_item_remove_downloads_title" formatted="false">سبھی ڈاؤن لوڈز ہٹائیں</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">سبھی ڈاؤن لوڈز ہٹائیں؟</string>+ <string name="album_type_album" formatted="false">البم</string>+ <string name="album_type_single" formatted="false">سنگل</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">مجموعے</string>+ <string name="assisted_curation_search_playlist" formatted="false">پلے لسٹ</string>+ <string name="assisted_curation_search_filter_top" formatted="false">بہترین نتائج</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">گانے</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">آرٹسٹس</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">البمز</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">پلے لسٹس</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">فلٹر صاف کریں</string>+ <string name="ad_category_title_music" formatted="false">موسیقی</string>+ <string name="made_for_you_hub_title" formatted="false">آپ کیلئے تیار کردہ</string>+ <string name="settings_item_app_language_title" formatted="false">ایپ کی زبان</string>+ <string name="create_menu_item_folder_title" formatted="false">فولڈر</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">نیا فولڈر</string>+ <string name="context_menu_rename_folder" formatted="false">فولڈر کا نام تبدیل کریں۔</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">فولڈر کا نام</string>+ <string name="create_playlist_content_description" formatted="false">پلے لسٹ بنائیں</string>+ <string name="actions_picker_delete" formatted="false">ڈیلیٹ کریں</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">ترتیب دیں بلحاظ</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">بلحاظ حروف تہجی</string>+ <string name="your_library_sort_order_creator" formatted="false">تخلیق کار</string>+ <string name="your_library_sort_order_custom" formatted="false">حسب منشاء ترتیب</string>+ <string name="settings_item_version_title" formatted="false">ورژن</string>+ <string name="context_menu_go_to_song_radio" formatted="false">گانے کے ریڈیو پر جائیں</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">لائیک کردہ گانوں میں تلاش کریں</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">پلے لسٹ میں تلاش کریں</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">\'%1$s\' نہیں ملا</string>+</resources>diff --git a/base/app/src/main/res/values-v30/bools.xml b/base/app/src/main/res/values-v30/bools.xmlnew file mode 100644index 00000000..fe9427a5--- /dev/null+++ b/base/app/src/main/res/values-v30/bools.xml@@ -0,0 +1,4 @@+<?xml version="1.0" encoding="utf-8"?>+<resources>+ <bool name="connect_route_provider">true</bool>+</resources>diff --git a/base/app/src/main/res/values-vi/spotify_plurals.xml b/base/app/src/main/res/values-vi/spotify_plurals.xmlnew file mode 100644index 00000000..627f6aee--- /dev/null+++ b/base/app/src/main/res/values-vi/spotify_plurals.xml@@ -0,0 +1,16 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="other">%1$d bài hát</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="other">%1$,d lượt lưu</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="other">%1$s danh sách phát</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="other">%1$s bài hát</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-vi/spotify_strings.xml b/base/app/src/main/res/values-vi/spotify_strings.xmlnew file mode 100644index 00000000..04f6513d--- /dev/null+++ b/base/app/src/main/res/values-vi/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Thêm vào Bài hát đã thích</string>+ <string name="collection_liked_songs_title" formatted="false">Bài hát đã thích</string>+ <string name="context_menu_add_to_playlist" formatted="false">Thêm vào danh sách phát</string>+ <string name="context_menu_play_next" formatted="false">Phát tiếp</string>+ <string name="context_menu_add_to_queue" formatted="false">Thêm vào Danh sách chờ</string>+ <string name="context_menu_go_to_queue" formatted="false">Chuyển đến Danh sách chờ</string>+ <string name="context_menu_browse_album" formatted="false">Chuyển đến album</string>+ <string name="context_menu_browse_artist" formatted="false">Chuyển tới nghệ sĩ</string>+ <string name="context_menu_share" formatted="false">Chia sẻ</string>+ <string name="context_menu_sleep_timer" formatted="false">Hẹn giờ đi ngủ</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Tắt hẹn giờ</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Cuối bản nhạc</string>+ <string name="snackbar_added_to_queue" formatted="false">Đã thêm vào danh sách chờ</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Đã thêm vào trang Bài hát đã thích.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Đã xóa khỏi trang Bài hát đã thích.</string>+ <string name="content_description_context_menu" formatted="false">Tùy chọn khác</string>+ <string name="close_button_content_description" formatted="false">Đóng</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Đã lưu vào</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Danh sách phát mới</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Hủy</string>+ <string name="create_playlist_create_button" formatted="false">Tạo</string>+ <string name="lyrics_card_title" formatted="false">Lời bài hát</string>+ <string name="lyrics_card_title_preview" formatted="false">Bản xem trước lời bài hát</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Hiện lời bài hát</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Mở lời bài hát trên toàn màn hình</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Chia sẻ lời bài hát</string>+ <string name="lyrics_credential_note" formatted="false">Lời bài hát do %1$s cung cấp</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Chia sẻ</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Dịch</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Đóng lời bài hát</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Dịch lời bài hát</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Dừng dịch lời bài hát</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Rất tiếc. Chúng tôi vẫn chưa có lời bài hát này.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">Những lời bài hát này chưa được đồng bộ hóa.</string>+ <string name="av_switch_to_video" formatted="false">Chuyển sang phát video</string>+ <string name="av_switch_to_audio" formatted="false">Chuyển sang phát âm thanh</string>+ <string name="av_content_desc" formatted="false">Chuyển đổi giữa âm thanh và video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Trang chủ</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Tìm kiếm</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Thư viện</string>+ <string name="search_header_field_hint" formatted="false">Bạn muốn nghe gì?</string>+ <string name="filter_chip_all_label" formatted="false">Tất cả</string>+ <string name="recents_content_filter_music" formatted="false">Nhạc</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcast</string>+ <string name="audiobooks_title" formatted="false">Sách nói</string>+ <string name="artist_popular_tracks" formatted="false">Phổ biến</string>+ <string name="curation_button_follow_state_text" formatted="false">Theo dõi</string>+ <string name="curation_button_following_state_text" formatted="false">Đang theo dõi</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Nghệ sĩ</string>+ <string name="connect_phone_is_self" formatted="false">Điện thoại này</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Hình ảnh ngắn, lặp lại khi bài hát đang phát.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Không phải bây giờ</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Cập nhật</string>+ <string name="context_type_description_play_queue" formatted="false">Đang phát từ Danh sách chờ Phát</string>+ <string name="context_type_description_collection_your_library" formatted="false">Đang phát từ Thư viện</string>+ <string name="context_type_description_playlist" formatted="false">Đang phát từ danh sách phát</string>+ <string name="context_type_description_album" formatted="false">Đang phát từ Album</string>+ <string name="context_type_description_artist" formatted="false">Đang phát từ Nghệ sĩ</string>+ <string name="context_type_description_show" formatted="false">Phát từ Podcast</string>+ <string name="context_type_description_search" formatted="false">Đang phát từ Tìm kiếm</string>+ <string name="default_notification_channel_name" formatted="false">Đang phát</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Thiết bị</string>+ <string name="action_share_label" formatted="false">Chia sẻ</string>+ <string name="action_queue_label" formatted="false">Danh sách chờ</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 giờ</string>+ <string name="curation_actions_edit_button_title" formatted="false">Chỉnh sửa</string>+ <string name="content_description_pause_button" formatted="false">Tạm dừng</string>+ <string name="content_description_play_button" formatted="false">Phát</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Phát ngẫu nhiên</string>+ <string name="np_content_desc_repeat" formatted="false">Lặp lại</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Hẹn giờ ngủ</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Xóa</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Di chuyển</string>+ <string name="bottom_actions_close" formatted="false">Đóng</string>+ <string name="add_to_queue_action_content_description" formatted="false">Thêm vào danh sách chờ</string>+ <string name="curation_button_saved_text" formatted="false">Đã lưu</string>+ <string name="np_content_desc_prev" formatted="false">Trước</string>+ <string name="np_content_desc_next" formatted="false">Tiếp</string>+ <string name="accessibility_navigate_back" formatted="false">Quay lại</string>+ <string name="monthly_listeners_text" formatted="false">%1$s người nghe hằng tháng</string>+ <string name="profile_bio_show_less" formatted="false">Ẩn bớt</string>+ <string name="audiobook_series_see_more_button" formatted="false">Hiện thêm</string>+ <string name="popular_releases_section_title" formatted="false">Bản phát hành nổi tiếng</string>+ <string name="creator_biography_section_title" formatted="false">Giới thiệu</string>+ <string name="fans_also_like_section_title" formatted="false">Fan cũng thích</string>+ <string name="appears_on_section_title" formatted="false">Xuất hiện trên</string>+ <string name="composer_section_button_show_all" formatted="false">Hiện tất cả</string>+ <string name="releases_title" formatted="false">Bản phát hành</string>+ <string name="artist_releases_albums" formatted="false">Album</string>+ <string name="artist_releases_singles" formatted="false">Đĩa đơn và Đĩa mở rộng EP</string>+ <string name="latest_release_title" formatted="false">Mới phát hành</string>+ <string name="artist_subtitle" formatted="false">Nghệ sĩ</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Các tìm kiếm gần đây</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Xóa</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcast</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Tập</string>+ <string name="assisted_curation_search_song" formatted="false">Bài hát</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Hồ sơ</string>+ <string name="connect_device_menu_logout" formatted="false">Đăng xuất</string>+ <string name="library_search_text_hint" formatted="false">Tìm kiếm trong thư viện</string>+ <string name="account_title" formatted="false">Tài khoản</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Nghệ sĩ đang theo dõi</string>+ <string name="settings_item_crossfade_title" formatted="false">Chuyển bài</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d giây</string>+ <string name="local_files_title" formatted="false">Tệp trên thiết bị</string>+ <string name="local_files_empty_section_title" formatted="false">Thêm tệp âm thanh của riêng bạn vào Thư viện</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Bạn có bài hát hoặc podcast cá nhân không có trên Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Tệp âm thanh của bạn sẽ xuất hiện ở đây</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Cấp quyền truy cập</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Chuyển đến Cài đặt</string>+ <string name="context_menu_download" formatted="false">Tải xuống</string>+ <string name="context_menu_undownload" formatted="false">Xóa nội dung tải xuống</string>+ <string name="collection_downloaded" formatted="false">Đã tải xuống</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Đã tải xuống</string>+ <string name="download_badge_downloading_content_description" formatted="false">Đang tải xuống</string>+ <string name="download_badge_error_content_description" formatted="false">Tải xuống không thành công</string>+ <string name="download_notification_downloading" formatted="false">Đang tải xuống…</string>+ <string name="toast_undownload" formatted="false">Xóa Bản Tải xuống.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Xóa bài hát khỏi nội dung tải xuống?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Bạn sẽ không thể phát bài hát này khi không có kết nối mạng nữa.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Xóa</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Xóa tất cả nội dung tải xuống</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Xóa tất cả nội dung tải xuống?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Đĩa đơn</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Tuyển tập</string>+ <string name="assisted_curation_search_playlist" formatted="false">Danh sách phát</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Kết quả phù hợp nhất</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Bài hát</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Nghệ sĩ</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Album</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Danh sách phát</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Xóa bộ lọc</string>+ <string name="ad_category_title_music" formatted="false">Nhạc</string>+ <string name="made_for_you_hub_title" formatted="false">Dành cho bạn</string>+ <string name="settings_item_app_language_title" formatted="false">Ngôn ngữ của ứng dụng</string>+ <string name="create_menu_item_folder_title" formatted="false">Thư mục</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Thư mục mới</string>+ <string name="context_menu_rename_folder" formatted="false">Đổi tên thư mục</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Tên thư mục</string>+ <string name="create_playlist_content_description" formatted="false">Tạo danh sách phát</string>+ <string name="actions_picker_delete" formatted="false">Xóa</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sắp xếp theo</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Thứ tự chữ cái</string>+ <string name="your_library_sort_order_creator" formatted="false">Người tạo</string>+ <string name="your_library_sort_order_custom" formatted="false">Thứ tự tùy chỉnh</string>+ <string name="settings_item_version_title" formatted="false">Phiên bản</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Chuyển đến radio theo bài hát</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Tìm trong mục Bài hát đã thích</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Tìm trong danh sách phát</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Không tìm thấy \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values-zh-rHK/spotify_plurals.xml b/base/app/src/main/res/values-zh-rHK/spotify_plurals.xmlnew file mode 100644index 00000000..37d48cc4--- /dev/null+++ b/base/app/src/main/res/values-zh-rHK/spotify_plurals.xml@@ -0,0 +1,16 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="other">%1$d 首歌曲</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="other">儲存次數:%1$,d</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="other">%1$s 個播放清單</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="other">%1$s 首歌曲</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-zh-rHK/spotify_strings.xml b/base/app/src/main/res/values-zh-rHK/spotify_strings.xmlnew file mode 100644index 00000000..795a2587--- /dev/null+++ b/base/app/src/main/res/values-zh-rHK/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">新增至「讚好過的歌曲」</string>+ <string name="collection_liked_songs_title" formatted="false">讚好過的歌曲</string>+ <string name="context_menu_add_to_playlist" formatted="false">新增至播放清單</string>+ <string name="context_menu_play_next" formatted="false">下一首播放</string>+ <string name="context_menu_add_to_queue" formatted="false">新增至佇列</string>+ <string name="context_menu_go_to_queue" formatted="false">前往佇列</string>+ <string name="context_menu_browse_album" formatted="false">前往專輯</string>+ <string name="context_menu_browse_artist" formatted="false">前往藝人</string>+ <string name="context_menu_share" formatted="false">分享</string>+ <string name="context_menu_sleep_timer" formatted="false">睡眠計時器</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">關閉計時器</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">曲目結尾</string>+ <string name="snackbar_added_to_queue" formatted="false">已新增至佇列</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">已新增至「讚好過的歌曲」。</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">已從「讚好過的歌曲」移除。</string>+ <string name="content_description_context_menu" formatted="false">更多選項</string>+ <string name="close_button_content_description" formatted="false">關閉</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">已儲存在</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">新播放清單</string>+ <string name="add_to_playlist_button_cancel" formatted="false">取消</string>+ <string name="create_playlist_create_button" formatted="false">建立</string>+ <string name="lyrics_card_title" formatted="false">歌詞</string>+ <string name="lyrics_card_title_preview" formatted="false">歌詞預覽</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">顯示歌詞</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">開啟全螢幕歌詞</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">分享歌詞</string>+ <string name="lyrics_credential_note" formatted="false">歌詞由%1$s提供</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">分享</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">翻譯</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">關閉歌詞</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">翻譯歌詞</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">停止翻譯歌詞</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">嗯,我們不知道這首歌的歌詞。</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">這些歌詞尚未實時同步。</string>+ <string name="av_switch_to_video" formatted="false">切換至影片</string>+ <string name="av_switch_to_audio" formatted="false">切換至音訊</string>+ <string name="av_content_desc" formatted="false">切換為音訊或影片</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">首頁</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">搜尋</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">你的音樂庫</string>+ <string name="search_header_field_hint" formatted="false">你想收聽什麼內容?</string>+ <string name="filter_chip_all_label" formatted="false">全部</string>+ <string name="recents_content_filter_music" formatted="false">音樂</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcast</string>+ <string name="audiobooks_title" formatted="false">有聲書</string>+ <string name="artist_popular_tracks" formatted="false">熱門</string>+ <string name="curation_button_follow_state_text" formatted="false">關注</string>+ <string name="curation_button_following_state_text" formatted="false">正在關注</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">藝人</string>+ <string name="connect_phone_is_self" formatted="false">此手機</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">歌曲播放時的簡短循環視覺效果。</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">現在不要</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">更新</string>+ <string name="context_type_description_play_queue" formatted="false">正在從播放佇列播放</string>+ <string name="context_type_description_collection_your_library" formatted="false">正在從你的音樂庫播放</string>+ <string name="context_type_description_playlist" formatted="false">正在播放的播放清單</string>+ <string name="context_type_description_album" formatted="false">正在播放專輯</string>+ <string name="context_type_description_artist" formatted="false">正在播放藝人</string>+ <string name="context_type_description_show" formatted="false">正在播放的 Podcast</string>+ <string name="context_type_description_search" formatted="false">正在播放搜尋內容</string>+ <string name="default_notification_channel_name" formatted="false">正在播放</string>+ <string name="label_bluetooth" formatted="false">藍牙</string>+ <string name="mr_user_route_category_name" formatted="false">裝置</string>+ <string name="action_share_label" formatted="false">分享</string>+ <string name="action_queue_label" formatted="false">佇列</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 小時</string>+ <string name="curation_actions_edit_button_title" formatted="false">編輯</string>+ <string name="content_description_pause_button" formatted="false">暫停</string>+ <string name="content_description_play_button" formatted="false">播放</string>+ <string name="play_mode_item_shuffle_title" formatted="false">隨機播放</string>+ <string name="np_content_desc_repeat" formatted="false">重複播放</string>+ <string name="np_content_desc_sleep_timer" formatted="false">睡眠計時器</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">移除</string>+ <string name="edit_playlist_items_move_chip" formatted="false">移動</string>+ <string name="bottom_actions_close" formatted="false">閂埋</string>+ <string name="add_to_queue_action_content_description" formatted="false">加去佇列</string>+ <string name="curation_button_saved_text" formatted="false">已儲存</string>+ <string name="np_content_desc_prev" formatted="false">上一步</string>+ <string name="np_content_desc_next" formatted="false">下一步</string>+ <string name="accessibility_navigate_back" formatted="false">返回</string>+ <string name="monthly_listeners_text" formatted="false">每月聽眾人數:%1$s</string>+ <string name="profile_bio_show_less" formatted="false">顯示較少內容</string>+ <string name="audiobook_series_see_more_button" formatted="false">顯示更多內容</string>+ <string name="popular_releases_section_title" formatted="false">熱門發行內容</string>+ <string name="creator_biography_section_title" formatted="false">關於</string>+ <string name="fans_also_like_section_title" formatted="false">粉絲亦鐘意</string>+ <string name="appears_on_section_title" formatted="false">參與的專輯</string>+ <string name="composer_section_button_show_all" formatted="false">顯示全部內容</string>+ <string name="releases_title" formatted="false">發行作品</string>+ <string name="artist_releases_albums" formatted="false">專輯</string>+ <string name="artist_releases_singles" formatted="false">單曲和迷你專輯</string>+ <string name="latest_release_title" formatted="false">最新發行</string>+ <string name="artist_subtitle" formatted="false">藝人</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">最近的搜尋記錄</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">清除</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcast</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">單集</string>+ <string name="assisted_curation_search_song" formatted="false">歌曲</string>+ <string name="album" formatted="false">專輯</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">個人檔案</string>+ <string name="connect_device_menu_logout" formatted="false">登出</string>+ <string name="library_search_text_hint" formatted="false">搜尋你的音樂庫</string>+ <string name="account_title" formatted="false">帳戶</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">已關注藝人</string>+ <string name="settings_item_crossfade_title" formatted="false">淡入/淡出</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d 秒</string>+ <string name="local_files_title" formatted="false">本機檔案</string>+ <string name="local_files_empty_section_title" formatted="false">將自己的音訊檔案新增至「你的音樂庫」</string>+ <string name="local_files_empty_section_subtitle" formatted="false">擁有 Spotify 沒有的歌曲或個人 Podcast?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">你的音訊檔案會在此處顯示</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">授予存取權限</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">前往「設定」</string>+ <string name="context_menu_download" formatted="false">下載</string>+ <string name="context_menu_undownload" formatted="false">移除下載檔案</string>+ <string name="collection_downloaded" formatted="false">已下載</string>+ <string name="download_badge_downloaded_content_description" formatted="false">已下載</string>+ <string name="download_badge_downloading_content_description" formatted="false">下載中</string>+ <string name="download_badge_error_content_description" formatted="false">下載失敗</string>+ <string name="download_notification_downloading" formatted="false">下載中…</string>+ <string name="toast_undownload" formatted="false">已移除下載檔案。</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">是否從下載檔案中移除?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">你將無法離線播放此內容。</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">移除</string>+ <string name="settings_item_remove_downloads_title" formatted="false">移除所有下載檔案</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">是否移除所有下載檔案?</string>+ <string name="album_type_album" formatted="false">專輯</string>+ <string name="album_type_single" formatted="false">單曲</string>+ <string name="album_type_ep" formatted="false">迷你專輯</string>+ <string name="album_type_compilation" formatted="false">合輯</string>+ <string name="assisted_curation_search_playlist" formatted="false">播放清單</string>+ <string name="assisted_curation_search_filter_top" formatted="false">熱門</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">歌曲</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">藝人</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">專輯</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">播放清單</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">清除篩選條件</string>+ <string name="ad_category_title_music" formatted="false">音樂</string>+ <string name="made_for_you_hub_title" formatted="false">為你精心打造</string>+ <string name="settings_item_app_language_title" formatted="false">應用程式語言</string>+ <string name="create_menu_item_folder_title" formatted="false">資料夾</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">新資料夾</string>+ <string name="context_menu_rename_folder" formatted="false">重新命名資料夾</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">資料夾名稱</string>+ <string name="create_playlist_content_description" formatted="false">建立播放清單</string>+ <string name="actions_picker_delete" formatted="false">刪除</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">排序方式</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">按字母順序</string>+ <string name="your_library_sort_order_creator" formatted="false">建立者</string>+ <string name="your_library_sort_order_custom" formatted="false">自訂順序</string>+ <string name="settings_item_version_title" formatted="false">版本</string>+ <string name="context_menu_go_to_song_radio" formatted="false">前往歌曲電台</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">在「讚好過的歌曲」中尋找</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">在播放清單中搜尋</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">找不到「%1$s」</string>+</resources>diff --git a/base/app/src/main/res/values-zh-rTW/spotify_plurals.xml b/base/app/src/main/res/values-zh-rTW/spotify_plurals.xmlnew file mode 100644index 00000000..37d48cc4--- /dev/null+++ b/base/app/src/main/res/values-zh-rTW/spotify_plurals.xml@@ -0,0 +1,16 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="other">%1$d 首歌曲</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="other">儲存次數:%1$,d</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="other">%1$s 個播放清單</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="other">%1$s 首歌曲</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-zh-rTW/spotify_strings.xml b/base/app/src/main/res/values-zh-rTW/spotify_strings.xmlnew file mode 100644index 00000000..a4d6303f--- /dev/null+++ b/base/app/src/main/res/values-zh-rTW/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">新增至「已按讚的歌曲」</string>+ <string name="collection_liked_songs_title" formatted="false">已按讚的歌曲</string>+ <string name="context_menu_add_to_playlist" formatted="false">新增至播放清單</string>+ <string name="context_menu_play_next" formatted="false">播放下一首</string>+ <string name="context_menu_add_to_queue" formatted="false">新增至佇列</string>+ <string name="context_menu_go_to_queue" formatted="false">前往佇列</string>+ <string name="context_menu_browse_album" formatted="false">前往專輯</string>+ <string name="context_menu_browse_artist" formatted="false">前往藝人頁面</string>+ <string name="context_menu_share" formatted="false">分享</string>+ <string name="context_menu_sleep_timer" formatted="false">睡眠定時器</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">關閉定時器</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">歌曲播完時</string>+ <string name="snackbar_added_to_queue" formatted="false">已新增至佇列</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">已新增至「已按讚的歌曲」。</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">已從「已按讚的歌曲」中移除。</string>+ <string name="content_description_context_menu" formatted="false">更多選項</string>+ <string name="close_button_content_description" formatted="false">關閉</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">儲存位置</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">建立新清單</string>+ <string name="add_to_playlist_button_cancel" formatted="false">取消</string>+ <string name="create_playlist_create_button" formatted="false">建立</string>+ <string name="lyrics_card_title" formatted="false">歌詞</string>+ <string name="lyrics_card_title_preview" formatted="false">歌詞預覽</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">顯示歌詞</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">全螢幕檢視歌詞</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">分享歌詞</string>+ <string name="lyrics_credential_note" formatted="false">歌詞提供者:%1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">分享</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">翻譯</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">關閉歌詞</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">翻譯歌詞</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">停止翻譯歌詞</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">嗯,我們也不知道這首歌曲的歌詞。</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">這些歌詞還沒跟播放時間同步。</string>+ <string name="av_switch_to_video" formatted="false">切換至影片</string>+ <string name="av_switch_to_audio" formatted="false">切換至音訊</string>+ <string name="av_content_desc" formatted="false">在音訊和影片之間切換</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">首頁</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">搜尋</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">你的音樂庫</string>+ <string name="search_header_field_hint" formatted="false">想聽什麼?</string>+ <string name="filter_chip_all_label" formatted="false">所有</string>+ <string name="recents_content_filter_music" formatted="false">音樂</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcast</string>+ <string name="audiobooks_title" formatted="false">有聲書</string>+ <string name="artist_popular_tracks" formatted="false">流行</string>+ <string name="curation_button_follow_state_text" formatted="false">追蹤</string>+ <string name="curation_button_following_state_text" formatted="false">追蹤中</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">藝人</string>+ <string name="connect_phone_is_self" formatted="false">這支手機</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">播放歌曲時出現的簡短循環播放視覺效果。</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">現在不要</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">更新</string>+ <string name="context_type_description_play_queue" formatted="false">播放自「播放佇列」</string>+ <string name="context_type_description_collection_your_library" formatted="false">正在從你的音樂庫播放</string>+ <string name="context_type_description_playlist" formatted="false">播放自播放清單</string>+ <string name="context_type_description_album" formatted="false">播放自專輯</string>+ <string name="context_type_description_artist" formatted="false">播放自藝人</string>+ <string name="context_type_description_show" formatted="false">從 Podcast 播放</string>+ <string name="context_type_description_search" formatted="false">搜尋播放自</string>+ <string name="default_notification_channel_name" formatted="false">現正播放</string>+ <string name="label_bluetooth" formatted="false">藍牙</string>+ <string name="mr_user_route_category_name" formatted="false">裝置</string>+ <string name="action_share_label" formatted="false">分享</string>+ <string name="action_queue_label" formatted="false">佇列</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 小時</string>+ <string name="curation_actions_edit_button_title" formatted="false">編輯</string>+ <string name="content_description_pause_button" formatted="false">暫停</string>+ <string name="content_description_play_button" formatted="false">播放</string>+ <string name="play_mode_item_shuffle_title" formatted="false">隨機播放</string>+ <string name="np_content_desc_repeat" formatted="false">重覆播放</string>+ <string name="np_content_desc_sleep_timer" formatted="false">睡眠定時器</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">移除</string>+ <string name="edit_playlist_items_move_chip" formatted="false">移動</string>+ <string name="bottom_actions_close" formatted="false">關閉</string>+ <string name="add_to_queue_action_content_description" formatted="false">新增至佇列</string>+ <string name="curation_button_saved_text" formatted="false">已儲存</string>+ <string name="np_content_desc_prev" formatted="false">上一首</string>+ <string name="np_content_desc_next" formatted="false">下一頁</string>+ <string name="accessibility_navigate_back" formatted="false">返回</string>+ <string name="monthly_listeners_text" formatted="false">每月 %1$s 名聽眾</string>+ <string name="profile_bio_show_less" formatted="false">顯示較少內容</string>+ <string name="audiobook_series_see_more_button" formatted="false">顯示更多內容</string>+ <string name="popular_releases_section_title" formatted="false">熱門新專輯</string>+ <string name="creator_biography_section_title" formatted="false">簡介</string>+ <string name="fans_also_like_section_title" formatted="false">粉絲也喜歡</string>+ <string name="appears_on_section_title" formatted="false">參與的專輯</string>+ <string name="composer_section_button_show_all" formatted="false">顯示所有內容</string>+ <string name="releases_title" formatted="false">新專輯</string>+ <string name="artist_releases_albums" formatted="false">專輯</string>+ <string name="artist_releases_singles" formatted="false">單曲和迷你專輯</string>+ <string name="latest_release_title" formatted="false">最新發行</string>+ <string name="artist_subtitle" formatted="false">藝人</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">最近的搜尋</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">清除</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcast</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">單集</string>+ <string name="assisted_curation_search_song" formatted="false">歌曲</string>+ <string name="album" formatted="false">專輯</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">個人檔案</string>+ <string name="connect_device_menu_logout" formatted="false">登出</string>+ <string name="library_search_text_hint" formatted="false">搜尋你的音樂庫</string>+ <string name="account_title" formatted="false">帳戶</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">已關注藝人</string>+ <string name="settings_item_crossfade_title" formatted="false">淡入/淡出</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d 秒</string>+ <string name="local_files_title" formatted="false">本機檔案</string>+ <string name="local_files_empty_section_title" formatted="false">將你自己的音訊檔案新增至「你的音樂庫」</string>+ <string name="local_files_empty_section_subtitle" formatted="false">你有不在 Spotify 上的歌曲或個人 Podcast 嗎?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">你的音訊檔案會在這裡顯示</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">允許存取</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">前往「設定」</string>+ <string name="context_menu_download" formatted="false">下載</string>+ <string name="context_menu_undownload" formatted="false">移除下載項目</string>+ <string name="collection_downloaded" formatted="false">已下載</string>+ <string name="download_badge_downloaded_content_description" formatted="false">已下載</string>+ <string name="download_badge_downloading_content_description" formatted="false">下載中</string>+ <string name="download_badge_error_content_description" formatted="false">下載失敗</string>+ <string name="download_notification_downloading" formatted="false">正在下載…</string>+ <string name="toast_undownload" formatted="false">下載已移除。</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">從下載項目中移除?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">你將無法以離線模式播放此播放清單。</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">移除</string>+ <string name="settings_item_remove_downloads_title" formatted="false">移除所有下載項目</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">移除所有下載項目?</string>+ <string name="album_type_album" formatted="false">專輯</string>+ <string name="album_type_single" formatted="false">單曲</string>+ <string name="album_type_ep" formatted="false">迷你專輯</string>+ <string name="album_type_compilation" formatted="false">合輯</string>+ <string name="assisted_curation_search_playlist" formatted="false">播放清單</string>+ <string name="assisted_curation_search_filter_top" formatted="false">熱門</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">歌曲</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">藝人</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">專輯</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">播放清單</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">清除篩選條件</string>+ <string name="ad_category_title_music" formatted="false">音樂</string>+ <string name="made_for_you_hub_title" formatted="false">專屬於你</string>+ <string name="settings_item_app_language_title" formatted="false">App 語言</string>+ <string name="create_menu_item_folder_title" formatted="false">資料夾</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">新資料夾</string>+ <string name="context_menu_rename_folder" formatted="false">重新命名資料夾</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">資料夾名稱</string>+ <string name="create_playlist_content_description" formatted="false">建立播放清單</string>+ <string name="actions_picker_delete" formatted="false">刪除</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">排序方式</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">按字母順序</string>+ <string name="your_library_sort_order_creator" formatted="false">創作者</string>+ <string name="your_library_sort_order_custom" formatted="false">自訂順序</string>+ <string name="settings_item_version_title" formatted="false">版本</string>+ <string name="context_menu_go_to_song_radio" formatted="false">前往歌曲電台</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">在已按讚的歌曲中尋找</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">在播放清單中尋找</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">找不到「%1$s」</string>+</resources>diff --git a/base/app/src/main/res/values-zh/spotify_plurals.xml b/base/app/src/main/res/values-zh/spotify_plurals.xmlnew file mode 100644index 00000000..0680e41d--- /dev/null+++ b/base/app/src/main/res/values-zh/spotify_plurals.xml@@ -0,0 +1,16 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="other">%1$d 首歌曲</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="other">收藏次数:%1$,d</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="other">%1$s 个歌单</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="other">%1$s 首歌曲</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-zh/spotify_strings.xml b/base/app/src/main/res/values-zh/spotify_strings.xmlnew file mode 100644index 00000000..ea576342--- /dev/null+++ b/base/app/src/main/res/values-zh/spotify_strings.xml@@ -0,0 +1,159 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">添加至已点赞的歌曲</string>+ <string name="collection_liked_songs_title" formatted="false">已点赞的歌曲</string>+ <string name="context_menu_add_to_playlist" formatted="false">加入歌单</string>+ <string name="context_menu_play_next" formatted="false">下一首播放</string>+ <string name="context_menu_add_to_queue" formatted="false">加入播放队列</string>+ <string name="context_menu_go_to_queue" formatted="false">转至播放队列</string>+ <string name="context_menu_browse_album" formatted="false">转至专辑</string>+ <string name="context_menu_browse_artist" formatted="false">转至艺人</string>+ <string name="context_menu_share" formatted="false">分享</string>+ <string name="context_menu_sleep_timer" formatted="false">睡眠定时器</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">关闭定时器</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">曲目结束时</string>+ <string name="snackbar_added_to_queue" formatted="false">已添加至播放队列</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">已加入“已点赞的歌曲”。</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">已从“已点赞的歌曲”中删除。</string>+ <string name="content_description_context_menu" formatted="false">更多选项</string>+ <string name="close_button_content_description" formatted="false">关闭</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">保存位置</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">新建歌单</string>+ <string name="add_to_playlist_button_cancel" formatted="false">取消</string>+ <string name="create_playlist_create_button" formatted="false">创建</string>+ <string name="lyrics_card_title" formatted="false">歌词</string>+ <string name="lyrics_card_title_preview" formatted="false">歌词预览</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">显示歌词</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">全屏打开歌词</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">分享歌词</string>+ <string name="lyrics_credential_note" formatted="false">歌词提供者:%1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">分享</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">翻译</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">关闭歌词</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">翻译歌词</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">停止翻译歌词</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">哎呀,我们也不知道这首歌的歌词。</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">这些歌词尚未与播放时间同步。</string>+ <string name="av_switch_to_video" formatted="false">切换至视频</string>+ <string name="av_switch_to_audio" formatted="false">切换至音频</string>+ <string name="av_content_desc" formatted="false">在音频和视频之间切换</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">主页</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">搜索</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">音乐库</string>+ <string name="search_header_field_hint" formatted="false">想听什么?</string>+ <string name="filter_chip_all_label" formatted="false">全部</string>+ <string name="recents_content_filter_music" formatted="false">音乐</string>+ <string name="ad_category_title_podcasts" formatted="false">播客</string>+ <string name="audiobooks_title" formatted="false">有声书</string>+ <string name="artist_popular_tracks" formatted="false">热门</string>+ <string name="curation_button_follow_state_text" formatted="false">关注</string>+ <string name="curation_button_following_state_text" formatted="false">已关注</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">艺人</string>+ <string name="connect_phone_is_self" formatted="false">此手机</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">歌曲播放时的简短视觉循环效果。</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">以后再说</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">更新</string>+ <string name="context_type_description_play_queue" formatted="false">播放自“播放队列”</string>+ <string name="context_type_description_collection_your_library" formatted="false">播放自“音乐库”</string>+ <string name="context_type_description_playlist" formatted="false">播放自“歌单”</string>+ <string name="context_type_description_album" formatted="false">播放自“专辑”</string>+ <string name="context_type_description_artist" formatted="false">播放自“艺人”</string>+ <string name="context_type_description_show" formatted="false">从播客播放</string>+ <string name="context_type_description_search" formatted="false">播放自“搜索”</string>+ <string name="default_notification_channel_name" formatted="false">Spotify</string>+ <string name="label_bluetooth" formatted="false">蓝牙</string>+ <string name="action_share_label" formatted="false">分享</string>+ <string name="action_queue_label" formatted="false">队列</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 小时</string>+ <string name="curation_actions_edit_button_title" formatted="false">编辑</string>+ <string name="content_description_pause_button" formatted="false">暂停</string>+ <string name="content_description_play_button" formatted="false">播放</string>+ <string name="play_mode_item_shuffle_title" formatted="false">随机播放</string>+ <string name="np_content_desc_repeat" formatted="false">循环播放</string>+ <string name="np_content_desc_sleep_timer" formatted="false">睡眠定时器</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">删除</string>+ <string name="edit_playlist_items_move_chip" formatted="false">移动</string>+ <string name="bottom_actions_close" formatted="false">关闭</string>+ <string name="add_to_queue_action_content_description" formatted="false">加入播放队列</string>+ <string name="curation_button_saved_text" formatted="false">已保存</string>+ <string name="np_content_desc_prev" formatted="false">上一首</string>+ <string name="np_content_desc_next" formatted="false">下一首</string>+ <string name="accessibility_navigate_back" formatted="false">返回</string>+ <string name="monthly_listeners_text" formatted="false">每月有 %1$s 名听众</string>+ <string name="profile_bio_show_less" formatted="false">收起</string>+ <string name="audiobook_series_see_more_button" formatted="false">显示更多</string>+ <string name="popular_releases_section_title" formatted="false">热门新歌</string>+ <string name="creator_biography_section_title" formatted="false">关于</string>+ <string name="fans_also_like_section_title" formatted="false">粉丝也喜欢</string>+ <string name="appears_on_section_title" formatted="false">参与的专辑</string>+ <string name="composer_section_button_show_all" formatted="false">显示全部</string>+ <string name="releases_title" formatted="false">新歌</string>+ <string name="artist_releases_albums" formatted="false">专辑</string>+ <string name="artist_releases_singles" formatted="false">单曲和 EP</string>+ <string name="latest_release_title" formatted="false">最新发布</string>+ <string name="artist_subtitle" formatted="false">艺人</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">最近的搜索记录</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">清除</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">播客</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">单集</string>+ <string name="assisted_curation_search_song" formatted="false">歌曲</string>+ <string name="album" formatted="false">专辑</string>+ <string name="album_type_podcast" formatted="false">播客</string>+ <string name="recently_played_user_profile" formatted="false">个人资料</string>+ <string name="connect_device_menu_logout" formatted="false">退出</string>+ <string name="library_search_text_hint" formatted="false">搜索“音乐库”</string>+ <string name="account_title" formatted="false">帐号</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">已关注艺人</string>+ <string name="settings_item_crossfade_title" formatted="false">淡入/淡出</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d 秒</string>+ <string name="local_files_title" formatted="false">本地文件</string>+ <string name="local_files_empty_section_title" formatted="false">将你的音频文件添加到“音乐库”</string>+ <string name="local_files_empty_section_subtitle" formatted="false">找到了 Spotify 没有的歌曲或个人播客?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">你的音频文件将显示在此处</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">允许访问</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">前往“设置”</string>+ <string name="context_menu_download" formatted="false">下载</string>+ <string name="context_menu_undownload" formatted="false">删除已下载内容</string>+ <string name="collection_downloaded" formatted="false">已下载</string>+ <string name="download_badge_downloaded_content_description" formatted="false">已下载</string>+ <string name="download_badge_downloading_content_description" formatted="false">正在下载</string>+ <string name="download_badge_error_content_description" formatted="false">下载失败</string>+ <string name="download_notification_downloading" formatted="false">正在下载…</string>+ <string name="toast_undownload" formatted="false">已删除下载。</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">从下载内容中删除?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">你将无法离线播放此单集。</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">删除</string>+ <string name="settings_item_remove_downloads_title" formatted="false">删除所有已下载内容</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">是否删除所有已下载内容?</string>+ <string name="album_type_album" formatted="false">专辑</string>+ <string name="album_type_single" formatted="false">单曲</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">精选辑</string>+ <string name="assisted_curation_search_playlist" formatted="false">歌单</string>+ <string name="assisted_curation_search_filter_top" formatted="false">最相关</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">歌曲</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">艺人</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">专辑</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">歌单</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">清除筛选条件</string>+ <string name="ad_category_title_music" formatted="false">音乐</string>+ <string name="made_for_you_hub_title" formatted="false">为小雅打造</string>+ <string name="settings_item_app_language_title" formatted="false">应用语言</string>+ <string name="create_menu_item_folder_title" formatted="false">文件夹</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">新文件夹</string>+ <string name="context_menu_rename_folder" formatted="false">重命名文件夹</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">文件夹名</string>+ <string name="create_playlist_content_description" formatted="false">创建歌单</string>+ <string name="actions_picker_delete" formatted="false">删除</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">排序方式</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">按字母顺序</string>+ <string name="your_library_sort_order_creator" formatted="false">创作者</string>+ <string name="your_library_sort_order_custom" formatted="false">自定义顺序</string>+ <string name="settings_item_version_title" formatted="false">版本</string>+ <string name="context_menu_go_to_song_radio" formatted="false">转至歌曲电台</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">在已点赞的歌曲中查找</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">在歌单中查找</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">找不到“%1$s”</string>+</resources>diff --git a/base/app/src/main/res/values-zu/spotify_plurals.xml b/base/app/src/main/res/values-zu/spotify_plurals.xmlnew file mode 100644index 00000000..f2251c7a--- /dev/null+++ b/base/app/src/main/res/values-zu/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%1$d ingoma</item>+ <item quantity="other">%1$d izingoma</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">Ukulondoloza okungu-%1$,d</item>+ <item quantity="other">Ukulondoloza okungu-%1$,d</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s uhlu lokudlalayo</item>+ <item quantity="other">%1$s izinhlu zokudlalayo</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s ingoma</item>+ <item quantity="other">%1$s izingoma</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values-zu/spotify_strings.xml b/base/app/src/main/res/values-zu/spotify_strings.xmlnew file mode 100644index 00000000..37846bb1--- /dev/null+++ b/base/app/src/main/res/values-zu/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Nezela kokuthi Izingoma Ezithandiwe</string>+ <string name="collection_liked_songs_title" formatted="false">Izingoma Ezithandiwe</string>+ <string name="context_menu_add_to_playlist" formatted="false">Nezela kuhlu lokudlalayo</string>+ <string name="context_menu_play_next" formatted="false">Dlala okulandelayo</string>+ <string name="context_menu_add_to_queue" formatted="false">Nezela Kulayini</string>+ <string name="context_menu_go_to_queue" formatted="false">Iya Kulayini</string>+ <string name="context_menu_browse_album" formatted="false">Iya ku-albhamu</string>+ <string name="context_menu_browse_artist" formatted="false">Iya kumculi</string>+ <string name="context_menu_share" formatted="false">Yabelana</string>+ <string name="context_menu_sleep_timer" formatted="false">Isibali-sikhathi sokulala</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Vala isibali sikhathi</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">Isiphetho sengoma</string>+ <string name="snackbar_added_to_queue" formatted="false">Kunezelwe Kulayini</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Kunezelwe kokuthi Izingoma Ezithandiwe.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Kususiwe kokuthi Izingoma Ezithandiwe.</string>+ <string name="content_description_context_menu" formatted="false">Izinketho ezengeziwe</string>+ <string name="close_button_content_description" formatted="false">Vala</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Kulondolozwe kokuthi</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">Uhlu lokudlalayo olusha</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Khansela</string>+ <string name="create_playlist_create_button" formatted="false">Yenza</string>+ <string name="lyrics_card_title" formatted="false">Amagama engoma</string>+ <string name="lyrics_card_title_preview" formatted="false">Ukuhlola kuqala kwamagama engoma</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Bonisa amagama engoma</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Vula amagama engoma esikrini esigcwele</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Yabelana ngamagama wengoma</string>+ <string name="lyrics_credential_note" formatted="false">Amagama engoma ahlinzekwe ngu-%1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Yabelana</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Humusha</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Vala amagama engoma</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Humusha amagama engoma</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Yeka ukuhumusha amagama engoma</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. Nathi asiwazi amagama ale ngoma.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">La magama wengoma awavumelanisiwe nesikhathi, okwamanje.</string>+ <string name="av_switch_to_video" formatted="false">Shintshela kuvidiyo</string>+ <string name="av_switch_to_audio" formatted="false">Shintshela kokulalelwayo</string>+ <string name="av_content_desc" formatted="false">Guqula phakathi komsindo nevidiyo</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Ikhaya</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Sesha</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Umtapo Wakho</string>+ <string name="search_header_field_hint" formatted="false">Yini ofuna ukuyilalela?</string>+ <string name="filter_chip_all_label" formatted="false">Konke</string>+ <string name="recents_content_filter_music" formatted="false">Umculo</string>+ <string name="ad_category_title_podcasts" formatted="false">Ama-podcast</string>+ <string name="audiobooks_title" formatted="false">Ama-Audiobook</string>+ <string name="artist_popular_tracks" formatted="false">Okudumile</string>+ <string name="curation_button_follow_state_text" formatted="false">Landela</string>+ <string name="curation_button_following_state_text" formatted="false">Obalandelayo</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Umculi</string>+ <string name="connect_phone_is_self" formatted="false">Le foni</string>+ <string name="settings_item_canvas_title" formatted="false">I-Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Okubukwayo okufushane, okuphindayo lapho kudlala ingoma.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Hhayi manje</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Buyekeza</string>+ <string name="context_type_description_play_queue" formatted="false">Idlala ezivela ku-Play Queue</string>+ <string name="context_type_description_collection_your_library" formatted="false">Idlala ezivela Kumtapo Wakho</string>+ <string name="context_type_description_playlist" formatted="false">Idlala ezivela Kuhlu Lokudlalayo</string>+ <string name="context_type_description_album" formatted="false">Idlala ezivela ku-albhamu</string>+ <string name="context_type_description_artist" formatted="false">Idlala ezivela Kumculi</string>+ <string name="context_type_description_show" formatted="false">Idlala ezivela ku-Podcast</string>+ <string name="context_type_description_search" formatted="false">Idlala ezivela Kusesho</string>+ <string name="default_notification_channel_name" formatted="false">Okudlala manje</string>+ <string name="label_bluetooth" formatted="false">I-Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Amadivayisi</string>+ <string name="action_share_label" formatted="false">Yabelana</string>+ <string name="action_queue_label" formatted="false">Ulayini</string>+ <string name="mute_chat_duration_one_hour" formatted="false">Ihora eli-1</string>+ <string name="curation_actions_edit_button_title" formatted="false">Hlela</string>+ <string name="content_description_pause_button" formatted="false">Phumuza</string>+ <string name="content_description_play_button" formatted="false">Dlala</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Phithanisa</string>+ <string name="np_content_desc_repeat" formatted="false">Phinda</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Isibali-sikhathi sokulala</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Susa</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Nyakaza</string>+ <string name="bottom_actions_close" formatted="false">Vala</string>+ <string name="add_to_queue_action_content_description" formatted="false">Nezela kulayini</string>+ <string name="curation_button_saved_text" formatted="false">Kulondoloziwe</string>+ <string name="np_content_desc_prev" formatted="false">Edlule</string>+ <string name="np_content_desc_next" formatted="false">Okulandelayo</string>+ <string name="accessibility_navigate_back" formatted="false">Emuva</string>+ <string name="monthly_listeners_text" formatted="false">Abalaleli benyanga abangu-%1$s</string>+ <string name="profile_bio_show_less" formatted="false">Veza okumbalwa</string>+ <string name="audiobook_series_see_more_button" formatted="false">Veza okuningi</string>+ <string name="popular_releases_section_title" formatted="false">Okukhishiwe okuthandwayo</string>+ <string name="creator_biography_section_title" formatted="false">Mayelana</string>+ <string name="fans_also_like_section_title" formatted="false">Abalandeli babuye bathanda</string>+ <string name="appears_on_section_title" formatted="false">Uyavela ku-</string>+ <string name="composer_section_button_show_all" formatted="false">Veza konke</string>+ <string name="releases_title" formatted="false">Okukhishiwe</string>+ <string name="artist_releases_albums" formatted="false">Ama-albhamu</string>+ <string name="artist_releases_singles" formatted="false">Ama-Single nama-EP</string>+ <string name="latest_release_title" formatted="false">Ukukhishwa kwamuva</string>+ <string name="artist_subtitle" formatted="false">Umculi</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Usesho lwakamuva</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Sula</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Ama-podcast</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Iziqephu</string>+ <string name="assisted_curation_search_song" formatted="false">Ingoma</string>+ <string name="album" formatted="false">I-albhamu</string>+ <string name="album_type_podcast" formatted="false">I-podcast</string>+ <string name="recently_played_user_profile" formatted="false">Iphrofayili</string>+ <string name="connect_device_menu_logout" formatted="false">Phuma</string>+ <string name="library_search_text_hint" formatted="false">Sesha Umtapo Wakho</string>+ <string name="account_title" formatted="false">I-akhawunti</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Abaculi abalandelwayo</string>+ <string name="settings_item_crossfade_title" formatted="false">Isixubanisi</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Amafayela Alapha</string>+ <string name="local_files_empty_section_title" formatted="false">Nezela amafayela akho omsindo kokuthi Umtapo Wakho</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Ingabe unayo ingoma noma i-podcast yomuntu siqu engekho ku-Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Amafayela akho omsindo azovela lapha</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Nikeza ukufinyelela</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Iya kumaSethingi</string>+ <string name="context_menu_download" formatted="false">Dawuniloda</string>+ <string name="context_menu_undownload" formatted="false">Susa okudawunilodiwe</string>+ <string name="collection_downloaded" formatted="false">Kudawunilodiwe</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Kudawunilodiwe</string>+ <string name="download_badge_downloading_content_description" formatted="false">Iyadawuniloda</string>+ <string name="download_badge_error_content_description" formatted="false">Ukudawuniloda kuhlulekile</string>+ <string name="download_notification_downloading" formatted="false">Iyadawuniloda…</string>+ <string name="toast_undownload" formatted="false">Ukudawuniloda kukhishiwe.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Susa kokudawunilodiwe?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">Ngeke ukwazi ukudlala lokhu ungaxhunyiwe ku-inthanethi.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Susa</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Susa konke okudawunilodiwe</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Susa konke okudawunilodiwe?</string>+ <string name="album_type_album" formatted="false">I-albhamu</string>+ <string name="album_type_single" formatted="false">I-Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Amaqoqo</string>+ <string name="assisted_curation_search_playlist" formatted="false">Uhlu lokudlalayo</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Okuphambili</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Izingoma</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Abaculi</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Ama-albhamu</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Izinhlu zokudlalayo</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Sula isihlungi</string>+ <string name="ad_category_title_music" formatted="false">Umculo</string>+ <string name="made_for_you_hub_title" formatted="false">Ezenzelwe Wena</string>+ <string name="settings_item_app_language_title" formatted="false">Ulimi lohlelo</string>+ <string name="create_menu_item_folder_title" formatted="false">Ifolda</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">Ifolda entsha</string>+ <string name="context_menu_rename_folder" formatted="false">Qamba kabusha ifolda</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Igama lefolda</string>+ <string name="create_playlist_content_description" formatted="false">Yenza uhlu lokudlalayo</string>+ <string name="actions_picker_delete" formatted="false">Susa</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Hlukanisa nge-</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Ngokwezinhlamvu zamagama</string>+ <string name="your_library_sort_order_creator" formatted="false">Umenzi</string>+ <string name="your_library_sort_order_custom" formatted="false">Ukuhleleka ngokwezifiso</string>+ <string name="settings_item_version_title" formatted="false">Uhlobo</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Iya kokuthi umsakazo wengoma</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Thola Ezingomeni Ezithandwayo</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Thola kuhlu lokudlalayo</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Ayikwazanga ukuthola \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values/bools.xml b/base/app/src/main/res/values/bools.xmlnew file mode 100644index 00000000..bef4106d--- /dev/null+++ b/base/app/src/main/res/values/bools.xml@@ -0,0 +1,5 @@+<?xml version="1.0" encoding="utf-8"?>+<resources>+ <!-- MediaRoute2ProviderService exists from Android 11. -->+ <bool name="connect_route_provider">false</bool>+</resources>diff --git a/base/app/src/main/res/values/colors.xml b/base/app/src/main/res/values/colors.xmlnew file mode 100644index 00000000..7e749061--- /dev/null+++ b/base/app/src/main/res/values/colors.xml@@ -0,0 +1,30 @@+<?xml version="1.0" encoding="utf-8"?>+<resources>+ <!-- Spotify Brand Colors -->+ <color name="spotify_green">#FF1DB954</color>+ <color name="spotify_black">#FF000000</color>+ <color name="spotify_white">#FFFFFFFF</color>+ <color name="spotify_dark_gray">#FF121212</color>+ <color name="spotify_medium_gray">#FF535353</color>+ <color name="spotify_light_gray">#FFB3B3B3</color>++ <!-- Material 3 Primary Colors -->+ <color name="primary">#FFE0E0E0</color>+ <color name="on_primary">#FF121212</color>+ <color name="primary_container">#FF2E2E2E</color>+ <color name="on_primary_container">#FFF5F5F5</color>++ <!-- Material 3 Surface Colors -->+ <color name="surface">@color/spotify_black</color>+ <color name="on_surface">@color/spotify_white</color>+ <color name="surface_variant">@color/spotify_black</color>+ <color name="on_surface_variant">@color/spotify_light_gray</color>++ <!-- Material 3 Background -->+ <color name="background">@color/spotify_black</color>+ <color name="on_background">@color/spotify_white</color>++ <!-- Material 3 Status Bar -->+ <color name="status_bar">#FF000000</color>+ <color name="app_background">#FF121212</color>+</resources>\ No newline at end of filediff --git a/base/app/src/main/res/values/myspoti_strings.xml b/base/app/src/main/res/values/myspoti_strings.xmlnew file mode 100644index 00000000..85dda9f7--- /dev/null+++ b/base/app/src/main/res/values/myspoti_strings.xml@@ -0,0 +1,173 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Myspoti's own texts (English default, French). -->+<resources>+ <string name="welcome_tagline">Your music, with synced lyrics and official music videos.</string>+ <string name="welcome_login">Log in with Spotify</string>+ <string name="welcome_privacy">You sign in on Spotify\'s own page. Myspoti never sees your password.</string>+ <string name="crash_heading">Myspoti stopped working</string>+ <string name="crash_explanation">Something went wrong. Restart the app; if it happens again, copy the report and share it in a GitHub issue.</string>+ <string name="crash_restart_app">Restart Myspoti</string>+ <string name="crash_copy_report">Copy the report</string>+ <string name="crash_report_copied">Report copied</string>+ <string name="remove_from_liked">Remove from Liked Songs</string>+ <string name="repeat_on">Repeat: on</string>+ <string name="repeat_one">Repeat one</string>+ <string name="repeat_off">Repeat: off</string>+ <string name="headphones">Headphones</string>+ <string name="listen_on">Listen on</string>+ <string name="no_devices">No devices found</string>+ <string name="sleep_minutes">%1$d minutes</string>+ <string name="playing_on">Playing on:\u0020</string>+ <string name="next_in_queue">Next in queue</string>+ <string name="next_from">Next from: %1$s</string>+ <string name="next_up">Next up</string>+ <string name="clear_queue">Clear queue</string>+ <string name="my_playlist">My playlist</string>+ <string name="playlist_name">Playlist name</string>+ <string name="loading_playlists">Loading playlists…</string>+ <string name="couldnt_load">Couldn\'t load %1$s</string>+ <string name="nothing_here">Nothing here yet</string>+ <string name="album_not_found">Album not found</string>+ <string name="liked_song">Liked song</string>+ <string name="verified_artist">Verified Artist</string>+ <string name="lyrics_share">Share lyrics</string>+ <string name="lyrics_extra_title">More lyrics sources</string>+ <string name="lyrics_extra_summary">Apple Music (word by word), NetEase and Genius, when Spotify has no lyrics</string>+ <string name="lyrics_reload">Reload lyrics</string>+ <string name="lyrics_fullscreen">Open lyrics full screen</string>+ <string name="browse_all">Browse all</string>+ <string name="home_error">Couldn\'t load Home.\nCheck your connection and try again.</string>+ <string name="home_empty">Nothing to show yet.</string>+ <string name="spotify_account">Spotify account</string>+ <string name="spotify_user">Spotify user</string>+ <string name="list_view">Show as list</string>+ <string name="grid_view">Show as grid</string>+ <string name="library_error">Couldn\'t load your Library</string>+ <string name="library_empty">Your Library is empty</string>+ <string name="background_playback_title">Background playback</string>+ <string name="background_playback_on">Battery optimization is off: music and Spotify Connect keep going with the screen off.</string>+ <string name="background_playback_off">Turn off battery optimization so Android does not pause the app in the background.</string>+ <string name="crossfade_summary">Fades the end of a track out and the next one in (no overlap). On this phone only.</string>+ <plurals name="local_files_count">+ <item quantity="one">%d track</item>+ <item quantity="other">%d tracks</item>+ </plurals>+ <string name="local_files_none_subtitle">We didn\'t find any playable audio files on this device. When there are some, they\'ll show up here.</string>+ <string name="downloads_empty_title">Download to listen offline</string>+ <string name="downloads_empty_subtitle">Tap Download in a song\'s menu, or the download button of an album or playlist.</string>+ <string name="downloads_source">Audio from YouTube Music, checked against the original recording. Kept inside Myspoti only.</string>+ <string name="downloads_size">%1$s on this phone</string>+ <string name="download_unavailable">No matching recording found</string>+ <string name="download_retry">Try again</string>+ <string name="download_cancel">Cancel download</string>+ <string name="not_signed_in">You\'re signed out of Spotify. Sign in again to see this.</string>+ <string name="artist_not_found">Artist not found</string>+ <string name="playlist_not_found">Playlist not found</string>+ <string name="browse_new_releases">New releases</string>+ <string name="browse_charts">Charts</string>+ <string name="browse_workout">Workout</string>+ <string name="browse_dance_electronic">Dance/Electronic</string>+ <string name="language_auto">Automatic</string>+ <string name="language_auto_detail">French on a French phone, English otherwise</string>+ <string name="language_partial_note">Other languages: Spotify\'s own labels are translated, Myspoti\'s texts stay in English.</string>+ <string name="restart_player_title">Restart the player</string>+ <string name="restart_player_detail">If the music stops responding: reloads Spotify\'s player</string>+ <string name="local_playlist_subtitle">On this device</string>+ <string name="local_playlist_new">Playlist on this device</string>+ <string name="local_added_section">Added on this device</string>+ <string name="local_add_note">Phone files stay on this phone: Spotify can\'t receive them.</string>+ <string name="local_rename">Rename</string>+ <string name="local_delete_playlist">Delete playlist</string>+ <string name="local_added_to">Added to %1$s</string>+ <string name="folder_create_failed">Couldn\'t create the folder</string>+ <string name="local_playlist_empty">Add songs from Local Files with their + button.</string>+ <string name="playlist_change_refused">Spotify refused the change to this playlist</string>+ <string name="download_kept_by_list">Still downloaded: a downloaded playlist holds it</string>+ <string name="support_title">Support Myspoti</string>+ <string name="support_body">Myspoti is free, without ads, and made in my spare time. If you enjoy it, a small donation helps keep it going.</string>+ <string name="support_action">Support on Ko-fi</string>+ <string name="support_decline">No thanks</string>+ <string name="support_row_detail">A small donation on Ko-fi helps keep the app going</string>+ <string name="supporter_perks_title">Supporter perks</string>+ <string name="supporter_perks_detail">Accent colour, app icon and a badge, to say thanks</string>+ <string name="supporter_perks_locked">Unlocked by supporting Myspoti. It\'s on your word: nothing is checked.</string>+ <string name="supporter_i_supported">I\'ve supported Myspoti</string>+ <string name="supporter_how">How did you support it?</string>+ <string name="supporter_once">A donation</string>+ <string name="supporter_monthly">Every month</string>+ <string name="supporter_badge">Supporter</string>+ <string name="supporter_thanks_title">Thank you for your support!</string>+ <string name="supporter_thanks_body">If Myspoti still serves you well, a new small donation helps keep it going.</string>+ <string name="support_again">Support again</string>+ <string name="supporter_accent">Accent colour</string>+ <string name="supporter_icon">App icon</string>+ <string name="supporter_icon_note">When the icon changes, its home-screen shortcut may go away: the app stays in your app list.</string>+ <string name="supporter_monthly_switch">I support every month (no more reminders)</string>+ <string name="color_green">Green</string>+ <string name="color_blue">Blue</string>+ <string name="color_purple">Purple</string>+ <string name="color_pink">Pink</string>+ <string name="color_orange">Orange</string>+ <string name="about_detail">Version, Discord community, source code</string>+ <string name="about_discord">Discord</string>+ <string name="about_discord_detail">News, help and ideas: join the community</string>+ <string name="about_github">Source code</string>+ <string name="about_github_detail">Releases, issues and code on GitHub</string>+ <string name="about_free">Free, open source and without ads. Not affiliated with Spotify.</string>+ <string name="library_reorder_hint">Hold a playlist, then drag it to move it</string>+ <string name="library_reorder_reset">Back to Spotify\'s order</string>+ <string name="song_radio_failed">Couldn\'t open this song\'s radio</string>+ <string name="local_files_find_hint">Find in Local Files</string>+ <string name="data_saver_title">Data saver</string>+ <string name="data_saver_summary">On mobile data, Myspoti uses no data: only downloaded songs and Local Files play</string>+ <string name="data_saver_blocked">Data saver: on mobile data, only downloaded songs and Local Files play</string>+ <string name="new_releases_followed">From artists you follow</string>+ <string name="new_releases_latest">Latest releases</string>+ <string name="your_episodes_title">Your Episodes</string>+ <string name="your_episodes_empty">Episodes you save show up here.</string>+ <string name="recap_title">Your recap</string>+ <string name="recap_month">30 days</string>+ <string name="recap_year">12 months</string>+ <string name="recap_all">All time</string>+ <string name="recap_minutes">%1$d minutes</string>+ <string name="recap_listens">%1$d listens</string>+ <string name="recap_sources">Spotify %1$d min • Downloads %2$d min • Local files %3$d min</string>+ <string name="recap_empty">Listen for a while: your top tracks and artists will show up here.</string>+ <string name="recap_plays">%1$d plays</string>+ <string name="recap_top_tracks">Top tracks</string>+ <string name="recap_top_artists">Top artists</string>+ <string name="recap_top_albums">Top albums</string>+ <string name="recap_private_note">Counts everything played in Myspoti (Spotify, downloads, local files). It stays on this phone and is never sent to Spotify.</string>+ <string name="recap_detail">Your listening, downloads and local files included</string>+ <string name="track_credits">Credits</string>+ <string name="exclude_taste">Exclude from your taste profile</string>+ <string name="include_taste">Include in your taste profile</string>+ <string name="playback_speed">Playback speed</string>+ <string name="recommended_songs">Recommended songs</string>+ <string name="jam_title">Jam</string>+ <string name="jam_restricted">Spotify keeps starting a Jam to Premium accounts. You can still join one with a link.</string>+ <string name="jam_join">Join a Jam</string>+ <string name="jam_join_hint">Paste the invite link</string>+ <string name="jam_leave">Leave the Jam</string>+ <string name="jam_members">%1$d people listening</string>+ <string name="pin">Pin</string>+ <string name="unpin">Unpin</string>+ <string name="jam_start">Start a Jam</string>+ <string name="jam_invite">Share invite link</string>+ <string name="jam_failed">Spotify refused this Jam</string>+ <string name="jam_scan">Scan a Jam QR code</string>+ <string name="beta_logs_title">Logs of the last %1$d minutes</string>+ <string name="beta_logs_copy">Copy</string>+ <string name="beta_logs_copied">Logs copied</string>+ <string name="beta_logs_share">Share</string>+ <string name="beta_logs_close">Close</string>+ <string name="widget_description">Now playing, with play and skip buttons</string>+ <string name="widget_previous">Previous</string>+ <string name="widget_next">Next</string>+ <string name="widget_play_pause">Play or pause</string>+ <string name="offline_only_downloaded">Offline: only the %1$d downloaded songs of %2$d play</string>+ <string name="track_sort_title">Title</string>+ <string name="track_sort_artist">Artist</string>+ <string name="track_sort_album">Album</string>+ <string name="track_sort_duration">Duration</string>+</resources>diff --git a/base/app/src/main/res/values/spotify_plurals.xml b/base/app/src/main/res/values/spotify_plurals.xmlnew file mode 100644index 00000000..b3471e92--- /dev/null+++ b/base/app/src/main/res/values/spotify_plurals.xml@@ -0,0 +1,20 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <plurals name="liked_songs_header_metadata_text">+ <item quantity="one">%d song</item>+ <item quantity="other">%d songs</item>+ </plurals>+ <plurals name="profile_list_item_saves_count">+ <item quantity="one">%1$,d save</item>+ <item quantity="other">%1$,d saves</item>+ </plurals>+ <plurals name="add_to_playlist_folder_subtitle_playlists_count">+ <item quantity="one">%1$s playlist</item>+ <item quantity="other">%1$s playlists</item>+ </plurals>+ <plurals name="add_to_playlist_subtitle_songs_count">+ <item quantity="one">%1$s song</item>+ <item quantity="other">%1$s songs</item>+ </plurals>+</resources>diff --git a/base/app/src/main/res/values/spotify_strings.xml b/base/app/src/main/res/values/spotify_strings.xmlnew file mode 100644index 00000000..5b344bc4--- /dev/null+++ b/base/app/src/main/res/values/spotify_strings.xml@@ -0,0 +1,160 @@+<?xml version="1.0" encoding="utf-8"?>+<!-- Generated by tools/apkstrings.py from the official app (labels only). -->+<resources>+ <string name="aligned_curation_context_menu_item_add_to_liked_songs" formatted="false">Add to Liked Songs</string>+ <string name="collection_liked_songs_title" formatted="false">Liked Songs</string>+ <string name="context_menu_add_to_playlist" formatted="false">Add to playlist</string>+ <string name="context_menu_play_next" formatted="false">Play next</string>+ <string name="context_menu_add_to_queue" formatted="false">Add to Queue</string>+ <string name="context_menu_go_to_queue" formatted="false">Go to Queue</string>+ <string name="context_menu_browse_album" formatted="false">Go to album</string>+ <string name="context_menu_browse_artist" formatted="false">Go to artist</string>+ <string name="context_menu_share" formatted="false">Share</string>+ <string name="context_menu_sleep_timer" formatted="false">Sleep timer</string>+ <string name="context_menu_sleep_timer_turn_off" formatted="false">Turn off timer</string>+ <string name="context_menu_sleep_timer_end_of_track" formatted="false">End of track</string>+ <string name="snackbar_added_to_queue" formatted="false">Added to Queue</string>+ <string name="snackbar_added_to_liked_songs" formatted="false">Added to Liked Songs.</string>+ <string name="snackbar_removed_from_liked_songs" formatted="false">Removed from Liked Songs.</string>+ <string name="content_description_context_menu" formatted="false">More options</string>+ <string name="close_button_content_description" formatted="false">Close</string>+ <string name="add_to_playlist_saved_in_section_header" formatted="false">Saved in</string>+ <string name="add_to_playlist_new_playlist_button_text" formatted="false">New playlist</string>+ <string name="add_to_playlist_button_cancel" formatted="false">Cancel</string>+ <string name="create_playlist_create_button" formatted="false">Create</string>+ <string name="lyrics_card_title" formatted="false">Lyrics</string>+ <string name="lyrics_card_title_preview" formatted="false">Lyrics preview</string>+ <string name="lyrics_card_show_lyrics_button" formatted="false">Show lyrics</string>+ <string name="lyrics_card_expand_button_content_description" formatted="false">Open fullscreen lyrics</string>+ <string name="lyrics_card_share_button_content_description" formatted="false">Share lyrics</string>+ <string name="lyrics_credential_note" formatted="false">Lyrics provided by %1$s</string>+ <string name="lyrics_fullscreen_chip_label_share" formatted="false">Share</string>+ <string name="lyrics_fullscreen_chip_label_translate" formatted="false">Translate</string>+ <string name="lyrics_fullscreen_close_button_readout_value" formatted="false">Close lyrics</string>+ <string name="lyrics_fullscreen_context_menu_main_page_translate_lyrics_action" formatted="false">Translate lyrics</string>+ <string name="lyrics_fullscreen_translate_button_enabled_readout_value" formatted="false">Stop translating lyrics</string>+ <string name="lyrics_fullscreen_no_lyrics_error_version_two" formatted="false">Hmm. We don\'t know the lyrics for this one.</string>+ <string name="lyrics_fullscreen_unsynced" formatted="false">These lyrics aren\'t time-synced, yet.</string>+ <string name="av_switch_to_video" formatted="false">Switch to video</string>+ <string name="av_switch_to_audio" formatted="false">Switch to audio</string>+ <string name="av_content_desc" formatted="false">Toggle between audio and video</string>+ <string name="navigationbar_musicappitems_home_title" formatted="false">Home</string>+ <string name="navigationbar_musicappitems_search_title" formatted="false">Search</string>+ <string name="navigationbar_musicappitems_yourlibrary_title" formatted="false">Your Library</string>+ <string name="search_header_field_hint" formatted="false">What do you want to listen to?</string>+ <string name="filter_chip_all_label" formatted="false">All</string>+ <string name="recents_content_filter_music" formatted="false">Music</string>+ <string name="ad_category_title_podcasts" formatted="false">Podcasts</string>+ <string name="audiobooks_title" formatted="false">Audiobooks</string>+ <string name="artist_popular_tracks" formatted="false">Popular</string>+ <string name="curation_button_follow_state_text" formatted="false">Follow</string>+ <string name="curation_button_following_state_text" formatted="false">Following</string>+ <string name="search_main_entity_subtitle_artist" formatted="false">Artist</string>+ <string name="connect_phone_is_self" formatted="false">This phone</string>+ <string name="settings_item_canvas_title" formatted="false">Canvas</string>+ <string name="video_settings_canvas_subtitle" formatted="false">Short, looping visuals when a song is playing.</string>+ <string name="age_assurance_intro_cta_not_now" formatted="false">Not now</string>+ <string name="version_sunsetting_dialog_cta_update" formatted="false">Update</string>+ <string name="context_type_description_play_queue" formatted="false">Playing from Play Queue</string>+ <string name="context_type_description_collection_your_library" formatted="false">Playing from Your Library</string>+ <string name="context_type_description_playlist" formatted="false">Playing from Playlist</string>+ <string name="context_type_description_album" formatted="false">Playing from Album</string>+ <string name="context_type_description_artist" formatted="false">Playing from Artist</string>+ <string name="context_type_description_show" formatted="false">Playing from Podcast</string>+ <string name="context_type_description_search" formatted="false">Playing from Search</string>+ <string name="default_notification_channel_name" formatted="false">Now playing</string>+ <string name="label_bluetooth" formatted="false">Bluetooth</string>+ <string name="mr_user_route_category_name" formatted="false">Devices</string>+ <string name="action_share_label" formatted="false">Share</string>+ <string name="action_queue_label" formatted="false">Queue</string>+ <string name="mute_chat_duration_one_hour" formatted="false">1 hour</string>+ <string name="curation_actions_edit_button_title" formatted="false">Edit</string>+ <string name="content_description_pause_button" formatted="false">Pause</string>+ <string name="content_description_play_button" formatted="false">Play</string>+ <string name="play_mode_item_shuffle_title" formatted="false">Shuffle</string>+ <string name="np_content_desc_repeat" formatted="false">Repeat</string>+ <string name="np_content_desc_sleep_timer" formatted="false">Sleep timer</string>+ <string name="aligned_curation_first_save_default_row_remove_action_description" formatted="false">Remove</string>+ <string name="edit_playlist_items_move_chip" formatted="false">Move</string>+ <string name="bottom_actions_close" formatted="false">Close</string>+ <string name="add_to_queue_action_content_description" formatted="false">Add to queue</string>+ <string name="curation_button_saved_text" formatted="false">Saved</string>+ <string name="np_content_desc_prev" formatted="false">Previous</string>+ <string name="np_content_desc_next" formatted="false">Next</string>+ <string name="accessibility_navigate_back" formatted="false">Back</string>+ <string name="monthly_listeners_text" formatted="false">%1$s monthly listeners</string>+ <string name="profile_bio_show_less" formatted="false">Show less</string>+ <string name="audiobook_series_see_more_button" formatted="false">Show more</string>+ <string name="popular_releases_section_title" formatted="false">Popular releases</string>+ <string name="creator_biography_section_title" formatted="false">About</string>+ <string name="fans_also_like_section_title" formatted="false">Fans also like</string>+ <string name="appears_on_section_title" formatted="false">Appears on</string>+ <string name="composer_section_button_show_all" formatted="false">Show all</string>+ <string name="releases_title" formatted="false">Releases</string>+ <string name="artist_releases_albums" formatted="false">Albums</string>+ <string name="artist_releases_singles" formatted="false">Singles and EPs</string>+ <string name="latest_release_title" formatted="false">Latest release</string>+ <string name="artist_subtitle" formatted="false">Artist</string>+ <string name="assisted_curation_search_search_history_title" formatted="false">Recent searches</string>+ <string name="chat_content_picker_clear_recent_searches" formatted="false">Clear</string>+ <string name="assisted_curation_search_filter_podcasts" formatted="false">Podcasts</string>+ <string name="assisted_curation_search_filter_episodes" formatted="false">Episodes</string>+ <string name="assisted_curation_search_song" formatted="false">Song</string>+ <string name="album" formatted="false">Album</string>+ <string name="album_type_podcast" formatted="false">Podcast</string>+ <string name="recently_played_user_profile" formatted="false">Profile</string>+ <string name="connect_device_menu_logout" formatted="false">Log out</string>+ <string name="library_search_text_hint" formatted="false">Search Your Library</string>+ <string name="account_title" formatted="false">Account</string>+ <string name="song_dna_search_chip_followed_artists" formatted="false">Followed artists</string>+ <string name="settings_item_crossfade_title" formatted="false">Crossfade</string>+ <string name="playback_settings_crossfade_slider_seconds" formatted="false">%1$d s</string>+ <string name="local_files_title" formatted="false">Local Files</string>+ <string name="local_files_empty_section_title" formatted="false">Add your own audio files to Your Library</string>+ <string name="local_files_empty_section_subtitle" formatted="false">Got a song or personal podcast that\'s not on Spotify?</string>+ <string name="local_files_empty_section_no_files_title" formatted="false">Your audio files will appear here</string>+ <string name="local_files_empty_section_dialog_permission_rationale_accept" formatted="false">Give access</string>+ <string name="local_files_empty_section_button_go_to_settings" formatted="false">Go to Settings</string>+ <string name="context_menu_download" formatted="false">Download</string>+ <string name="context_menu_undownload" formatted="false">Remove download</string>+ <string name="collection_downloaded" formatted="false">Downloaded</string>+ <string name="download_badge_downloaded_content_description" formatted="false">Downloaded</string>+ <string name="download_badge_downloading_content_description" formatted="false">Downloading</string>+ <string name="download_badge_error_content_description" formatted="false">Download failed</string>+ <string name="download_notification_downloading" formatted="false">Downloading…</string>+ <string name="toast_undownload" formatted="false">Download removed.</string>+ <string name="playlist_entity_remove_download_dialog_title" formatted="false">Remove from downloads?</string>+ <string name="playlist_entity_remove_download_dialog_description" formatted="false">You won\'t be able to play this offline.</string>+ <string name="playlist_entity_remove_download_dialog_positive_button" formatted="false">Remove</string>+ <string name="settings_item_remove_downloads_title" formatted="false">Remove all downloads</string>+ <string name="settings_storage_remove_downloads_dialog_title" formatted="false">Remove all downloads?</string>+ <string name="album_type_album" formatted="false">Album</string>+ <string name="album_type_single" formatted="false">Single</string>+ <string name="album_type_ep" formatted="false">EP</string>+ <string name="album_type_compilation" formatted="false">Compilation</string>+ <string name="assisted_curation_search_playlist" formatted="false">Playlist</string>+ <string name="assisted_curation_search_filter_top" formatted="false">Top</string>+ <string name="assisted_curation_search_filter_songs" formatted="false">Songs</string>+ <string name="assisted_curation_search_filter_artists" formatted="false">Artists</string>+ <string name="assisted_curation_search_filter_albums" formatted="false">Albums</string>+ <string name="assisted_curation_search_filter_playlists" formatted="false">Playlists</string>+ <string name="assisted_curation_search_filter_clear_content_description" formatted="false">Clear filter</string>+ <string name="ad_category_title_music" formatted="false">Music</string>+ <string name="made_for_you_hub_title" formatted="false">Made for You</string>+ <string name="settings_item_app_language_title" formatted="false">App language</string>+ <string name="create_menu_item_folder_title" formatted="false">Folder</string>+ <string name="create_folder_name_suggested_folder_name" formatted="false">New folder</string>+ <string name="context_menu_rename_folder" formatted="false">Rename folder</string>+ <string name="your_library_messaging_folder_rename_hint" formatted="false">Folder name</string>+ <string name="create_playlist_content_description" formatted="false">Create playlist</string>+ <string name="actions_picker_delete" formatted="false">Delete</string>+ <string name="filter_and_sort_sort_section_title" formatted="false">Sort by</string>+ <string name="your_library_sort_order_alphabetical" formatted="false">Alphabetical</string>+ <string name="your_library_sort_order_creator" formatted="false">Creator</string>+ <string name="your_library_sort_order_custom" formatted="false">Custom order</string>+ <string name="settings_item_version_title" formatted="false">Version</string>+ <string name="context_menu_go_to_song_radio" formatted="false">Go to song radio</string>+ <string name="find_in_context_edit_text_liked_songs_hint" formatted="false">Find in Liked Songs</string>+ <string name="find_in_context_edit_text_playlist_hint" formatted="false">Find in playlist</string>+ <string name="assisted_curation_search_empty_view_no_result_title" formatted="false">Couldn\'t find \"%1$s\"</string>+</resources>diff --git a/base/app/src/main/res/values/strings.xml b/base/app/src/main/res/values/strings.xmlnew file mode 100644index 00000000..e4e4bc14--- /dev/null+++ b/base/app/src/main/res/values/strings.xml@@ -0,0 +1,44 @@+<resources xmlns:tools="http://schemas.android.com/tools">+ <string name="app_name">Myspoti</string>+ <string name="aa_playlists">Playlists</string>+ <string name="aa_albums">Albums</string>+ <string name="aa_artists">Artists</string>+ <string name="aa_podcasts">Podcasts</string>+ <string name="settings_amoled_theme">AMOLED Theme</string>+ <string name="settings_amoled_theme_subtitle">Pure black background to save battery</string>+ <string name="settings_lyrics_style_spotify_default">Spotify Default</string>+ <string name="settings_lyrics_style_fullscreen">Fullscreen (Album Colors)</string>+ <string name="settings_lyrics_style_compact">Compact</string>+ <string name="settings_lyrics_style_karaoke">Karaoke</string>+ <string name="settings_lyrics_style_bold">Bold Large</string>+ <string name="main_update_available">A new update is available</string>++ <string name="notif_channel_media_name">Media Playback</string>+ <string name="notif_channel_media_description">Myspoti media playback controls</string>+ <string name="notif_action_previous">Previous</string>+ <string name="notif_action_next">Next</string>+ <string name="notif_action_play">Play</string>+ <string name="notif_action_pause">Pause</string>+ <string name="notif_shuffle_enable">Enable shuffle</string>+ <string name="notif_shuffle_disable">Disable shuffle</string>+ <string name="notif_shuffle_disable_smart">Disable smart shuffle</string>+ <string name="notif_action_like">Like</string>+ <string name="notif_action_unlike">Unlike</string>+ <string name="notif_unknown_name">Unknown</string>+ <string name="notif_by_artist">by %1$s</string>+ <string name="notif_repeat_disable">Disable repeat</string>+ <string name="notif_repeat_disable_one">Disable repeat one</string>+ <string name="notif_repeat_enable">Enable repeat</string>++ <string name="bridge_player_unlocked">Player unlocked</string>+ <string name="bridge_reloading">Reloading…</string>++ <string name="service_disabled_message">Service is not enabled</string>+ <string name="energy_saver_title" tools:ignore="MissingTranslation">Battery saver</string>+ <string name="energy_saver_summary" tools:ignore="MissingTranslation">Canvas off, lighter videos and animations</string>+ <string name="video_fullscreen_enter" tools:ignore="MissingTranslation">Enter fullscreen</string>+ <string name="video_fullscreen_exit" tools:ignore="MissingTranslation">Exit fullscreen</string>+ <string name="playback_seek_description" tools:ignore="MissingTranslation">Playback position</string>+ <string name="account_page_title">Spotify account</string>+ <string name="account_page_detail">Plan, privacy and devices, on spotify.com</string>+</resources>diff --git a/base/app/src/main/res/values/themes.xml b/base/app/src/main/res/values/themes.xmlnew file mode 100644index 00000000..6dd64f6a--- /dev/null+++ b/base/app/src/main/res/values/themes.xml@@ -0,0 +1,36 @@+<resources xmlns:tools="http://schemas.android.com/tools">+ <!-- Base application theme. Material 3 + Spotify -->+ <style name="Theme.Myspoti" parent="Theme.Material3.DayNight.NoActionBar">+ <!-- Material 3 Primary -->+ <item name="colorPrimary">@color/primary</item>+ <item name="colorOnPrimary">@color/on_primary</item>+ <item name="colorPrimaryContainer">@color/primary_container</item>+ <item name="colorOnPrimaryContainer">@color/on_primary_container</item>++ <!-- Material 3 Surface -->+ <item name="colorSurface">@color/surface</item>+ <item name="colorOnSurface">@color/on_surface</item>+ <item name="colorSurfaceVariant">@color/surface_variant</item>+ <item name="colorOnSurfaceVariant">@color/on_surface_variant</item>++ <!-- Material 3 Background -->+ <item name="android:colorBackground">@color/background</item>+ <item name="colorOnBackground">@color/on_background</item>++ <!-- Status bar -->+ <item name="android:statusBarColor">@color/status_bar</item>+ <item name="android:navigationBarColor">@color/status_bar</item>++ <!-- Ensure edge-to-edge works -->+ <item name="android:windowTranslucentStatus">false</item>+ <item name="android:windowTranslucentNavigation">false</item>++ <!-- Launch screen: same background as the app (no black-to-grey flash). -->+ <item name="android:windowBackground">@color/app_background</item>+ <item name="android:windowSplashScreenBackground" tools:targetApi="31">@color/app_background</item>+ <item name="android:windowSplashScreenAnimatedIcon" tools:targetApi="31">@drawable/splash_icon</item>++ <!-- Light status bar icons (white icons on dark background) -->+ <item name="android:windowLightStatusBar">false</item>+ </style>+</resources>\ No newline at end of filediff --git a/base/app/src/main/res/xml/automotive_app_desc.xml b/base/app/src/main/res/xml/automotive_app_desc.xmlnew file mode 100644index 00000000..0f739ff8--- /dev/null+++ b/base/app/src/main/res/xml/automotive_app_desc.xml@@ -0,0 +1,4 @@+<?xml version="1.0" encoding="utf-8"?>+<automotiveApp>+ <uses name="media" />+</automotiveApp>\ No newline at end of filediff --git a/base/app/src/main/res/xml/widget_now_playing_info.xml b/base/app/src/main/res/xml/widget_now_playing_info.xmlnew file mode 100644index 00000000..4a01747b--- /dev/null+++ b/base/app/src/main/res/xml/widget_now_playing_info.xml@@ -0,0 +1,12 @@+<?xml version="1.0" encoding="utf-8"?>+<appwidget-provider xmlns:android="http://schemas.android.com/apk/res/android"+ android:description="@string/widget_description"+ android:initialLayout="@layout/widget_now_playing"+ android:minWidth="250dp"+ android:minHeight="40dp"+ android:previewLayout="@layout/widget_now_playing"+ android:resizeMode="horizontal"+ android:targetCellWidth="4"+ android:targetCellHeight="1"+ android:updatePeriodMillis="0"+ android:widgetCategory="home_screen" />diff --git a/base/app/src/test/java/app/myspoti/power/EnergyPolicyTest.kt b/base/app/src/test/java/app/myspoti/power/EnergyPolicyTest.ktnew file mode 100644index 00000000..f3fe299f--- /dev/null+++ b/base/app/src/test/java/app/myspoti/power/EnergyPolicyTest.kt@@ -0,0 +1,70 @@+package app.myspoti.power++import org.junit.Assert.*+import org.junit.Test++class EnergyPolicyTest {+ @Test fun constructorDefaultsMatchResolvedNormalPolicy() {+ assertEquals(EnergyPolicy(), EnergyPolicy.resolve(false, false))+ }+ @Test fun onlySaverCapsTheDisplayAndReducesProgress() {+ for (manual in listOf(false, true)) for (black in listOf(false, true)) {+ val p = EnergyPolicy.resolve(manual, black)+ assertEquals(if (manual) 60f else 0f, p.displayRefreshCap, 0f)+ assertEquals(if (manual) 20 else 30, p.progressFps)+ }+ }+ @Test fun defaultRequestsAStableDisplayBudgetAndPreservesCanvas() {+ val p = EnergyPolicy.resolve(false, false)+ assertTrue(p.allowCanvas); assertTrue(p.allowBackgroundLookups)+ assertFalse(p.oledBlack); assertEquals(0f, p.displayRefreshCap, 0f)+ assertEquals(30, p.progressFps)+ }+ @Test fun androidSaverIsNotFollowed() {+ // Nothing in the app's state comes from Android's battery saver.+ assertFalse(EnergyState().policy.saverEnabled)+ assertTrue(EnergyState().policy.allowCanvas)+ }+ @Test fun saverRestrictsVisualWork() {+ val p = EnergyPolicy.resolve(true, false)+ assertTrue(p.saverEnabled); assertFalse(p.allowCanvas); assertFalse(p.oledBlack)+ assertEquals(480, p.videoMaxHeight); assertEquals(20, p.progressFps)+ assertEquals(60f, p.displayRefreshCap, 0f); assertFalse(p.allowBackgroundLookups)+ }+ @Test fun blackOptionDoesNotDisableMotionOrCanvas() {+ val p = EnergyPolicy.resolve(false, true)+ assertTrue(p.oledBlack); assertTrue(p.allowCanvas); assertFalse(p.saverEnabled)+ }+ @Test fun amoledPreferenceControlsBlackWithEverySaverCombination() {+ for (manual in listOf(false, true)) for (black in listOf(false, true)) {+ val p = EnergyPolicy.resolve(manual, black)+ assertEquals(black, p.oledBlack)+ assertEquals(manual, p.saverEnabled)+ assertEquals(!manual, p.allowCanvas)+ assertEquals(!manual, p.allowBackgroundLookups)+ assertEquals(if (manual) 480 else 1080, p.videoMaxHeight)+ assertEquals(if (manual) 20 else 30, p.progressFps)+ assertEquals(if (manual) 60f else 0f, p.displayRefreshCap, 0f)+ }+ }+ @Test fun turningAmoledOffKeepsTheSameSaverRestrictions() {+ val enabled = EnergyState(manualSaver = true, blackPreference = true)+ val disabled = enabled.copy(blackPreference = false)+ assertTrue(enabled.policy.oledBlack)+ assertFalse(disabled.policy.oledBlack)+ assertEquals(enabled.policy.copy(oledBlack = false), disabled.policy)+ }+ @Test fun leavingSaverRestoresVisualDefaults() {+ val p = EnergyPolicy.resolve(false, false)+ assertEquals(1080, p.videoMaxHeight); assertEquals(30, p.progressFps)+ assertEquals(0f, p.displayRefreshCap, 0f)+ assertTrue(p.allowCanvas)+ }+ @Test fun canvasSwitchOnlyDisablesCanvas() {+ val p = EnergyPolicy.resolve(false, false, canvasEnabled = false)+ assertFalse(p.allowCanvas); assertFalse(p.saverEnabled); assertFalse(p.oledBlack)+ assertEquals(1080, p.videoMaxHeight); assertTrue(p.allowBackgroundLookups)+ assertFalse(EnergyState(canvasEnabled = false).policy.allowCanvas)+ assertTrue(EnergyState().policy.allowCanvas)+ }+}diff --git a/base/app/src/test/java/com/music/spotui/data/LibraryOrderTest.kt b/base/app/src/test/java/com/music/spotui/data/LibraryOrderTest.ktnew file mode 100644index 00000000..fc7420be--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/data/LibraryOrderTest.kt@@ -0,0 +1,41 @@+package com.music.spotui.data++import com.music.spotui.data.entity.LibraryEntry+import com.music.spotui.data.local.LibraryOrder+import com.music.spotui.data.local.LibraryOrder.Sort+import org.junit.Assert.assertEquals+import org.junit.Test++class LibraryOrderTest {+ private fun playlist(id: String, name: String, owner: String) =+ LibraryEntry(spotifyId = id, name = name, subtitle = "Playlist • $owner", coverUri = "", isPlaylist = true)+ private fun album(id: String, name: String, artists: String) =+ LibraryEntry(spotifyId = id, name = name, subtitle = "Album • $artists", coverUri = "", isPlaylist = false, artists = artists)+ private fun folder(uri: String, name: String) =+ LibraryEntry(spotifyId = uri, name = name, subtitle = "Folder • 2 playlists", coverUri = "", isPlaylist = false, folderUri = uri)++ private val liked = playlist("liked", "Liked Songs", "")+ private val b = playlist("b", "beta", "Zoe")+ private val a = playlist("a", "Alpha", "Max")+ private val e = album("e", "Éclat", "Adele")+ private val f = folder("spotify:user:x:folder:1", "Zzz folder")+ private val all = listOf(liked, b, a, e, f)++ private fun ids(l: List<LibraryEntry>) = l.map { it.spotifyId }++ @Test fun customWithoutSavedOrderKeepsSpotifys() =+ assertEquals(ids(all), ids(LibraryOrder.arrange(all, Sort.CUSTOM, emptyList(), 1)))++ @Test fun customFollowsSavedOrderAndPutsNewEntriesFirst() {+ val saved = listOf("spotify:user:x:folder:1", "a", "b")+ assertEquals(listOf("liked", "e", "spotify:user:x:folder:1", "a", "b"), ids(LibraryOrder.arrange(all, Sort.CUSTOM, saved, 1)))+ }++ @Test fun alphabeticalIgnoresCaseAndAccentsAndKeepsPinned() =+ assertEquals(listOf("liked", "a", "b", "e", "spotify:user:x:folder:1"), ids(LibraryOrder.arrange(all, Sort.ALPHABETICAL, emptyList(), 1)))++ @Test fun creatorPutsFoldersFirstThenOwnersAndArtists() =+ assertEquals(listOf("liked", "spotify:user:x:folder:1", "e", "a", "b"), ids(LibraryOrder.arrange(all, Sort.CREATOR, emptyList(), 1)))++ @Test fun folderKeyIsItsUri() = assertEquals("spotify:user:x:folder:1", LibraryOrder.key(f))+}diff --git a/base/app/src/test/java/com/music/spotui/data/api/LyricsApiAuditTest.kt b/base/app/src/test/java/com/music/spotui/data/api/LyricsApiAuditTest.ktnew file mode 100644index 00000000..93ece6d1--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/data/api/LyricsApiAuditTest.kt@@ -0,0 +1,93 @@+package com.music.spotui.data.api++import com.music.spotui.data.entity.LyricLine+import org.junit.Assert.*+import org.junit.Test+import kotlinx.coroutines.CompletableDeferred+import kotlinx.coroutines.CoroutineStart+import kotlinx.coroutines.Deferred+import kotlinx.coroutines.cancelAndJoin+import kotlinx.coroutines.launch+import kotlinx.coroutines.runBlocking+import java.util.concurrent.ConcurrentHashMap+import com.music.spotui.data.entity.Lyrics++/** Invokes the real private parser, without changing application visibility. */+class LyricsApiAuditTest {+ @Suppress("UNCHECKED_CAST")+ private fun parse(text: String): List<LyricLine> =+ LyricsApi::class.java.getDeclaredMethod("parseLrc", String::class.java).let {+ it.isAccessible = true+ it.invoke(LyricsApi, text) as List<LyricLine>+ }++ @Test fun fractionalSecondsOneTwoThreeDigits() {+ assertEquals(listOf(1200L, 1230L, 1234L, 2000L),+ parse("[00:01.2] a\n[00:01.23] b\n[00:01.234] c\n[00:02] d").map { it.timeMs })+ }++ @Test fun multipleTagsProduceChronologicallySortedCopies() {+ val lines = parse("[01:02.50][00:03.100] Refrain\n[00:02] Avant")+ assertEquals(listOf(2000L, 3100L, 62500L), lines.map { it.timeMs })+ assertEquals(listOf("Avant", "Refrain", "Refrain"), lines.map { it.text })+ }++ @Test fun untaggedMetadataAndBlankLinesAreIgnored() {+ assertEquals(emptyList<LyricLine>(), parse("[ar:Artist]\n[ti:Song]\n\nplain text"))+ }++ @Test fun consecutiveInstrumentalLinesCollapseWithoutRemovingLaterInstrumental() {+ assertEquals(listOf("♪", "Hello", "♪"),+ parse("[00:01]\n[00:02] \n[00:03] Hello\n[00:04]\n[00:05]").map { it.text })+ }++ @Test fun minuteBoundaryAndColonFraction() {+ assertEquals(listOf(59999L, 60000L, 60300L),+ parse("[00:59.999] a\n[01:00] b\n[01:00:3] c").map { it.timeMs })+ }++ @Test fun plausibleExactAndRemasterWithinThreeSeconds() {+ assertTrue(LyricsApi.isPlausibleMatch("Hello - 2011 Remaster", "Adele", 203, "Hello", "Adele", 200))+ assertFalse(LyricsApi.isPlausibleMatch("Hello", "Adele", 204, "Hello", "Adele", 200))+ }++ @Test fun unrelatedTitleAndArtistAreRejected() {+ assertFalse(LyricsApi.isPlausibleMatch("Hello", "Lionel Richie", 200, "Hello", "Adele", 200))+ assertFalse(LyricsApi.isPlausibleMatch("Skyfall", "Adele", 200, "Hello", "Adele", 200))+ }++ @Test fun unknownDurationDoesNotRejectOtherwiseMatchingSong() {+ assertTrue(LyricsApi.isPlausibleMatch("Hello", "Adele", 0, "Hello", "Adele", 200))+ }++ // Regression expectations: failures reveal unsafe substring matching.+ @Test fun differentArtistWithSharedPrefixIsRejected() {+ assertFalse("Cher and Cherry are distinct artists",+ LyricsApi.isPlausibleMatch("Hello", "Cherry", 200, "Hello", "Cher", 200))+ }++ @Test fun distinctSongWithSharedTitlePrefixIsRejected() {+ assertFalse("Hello and Hello Again are distinct songs",+ LyricsApi.isPlausibleMatch("Hello Again", "Adele", 200, "Hello", "Adele", 200))+ }++ /** Uses a controlled real Deferred; never contacts a lyrics provider. */+ @Test fun cancellingOneWaiterMustNotEvictStillRunningSharedRequest() = runBlocking {+ @Suppress("UNCHECKED_CAST")+ val requests = LyricsApi::class.java.getDeclaredField("inFlight").let {+ it.isAccessible = true+ it.get(LyricsApi) as ConcurrentHashMap<String, Deferred<Lyrics?>>+ }+ val track = LyricsApi.Track("audit-controlled-cancellation", "test", "artist", "", 200_000)+ val deferred = CompletableDeferred<Lyrics?>()+ val previous = requests.put(track.key, deferred)+ try {+ val waiter = launch(start = CoroutineStart.UNDISPATCHED) { LyricsApi.fetch(track) }+ waiter.cancelAndJoin()+ assertSame("A cancelled UI waiter must not remove an unfinished shared provider request", deferred, requests[track.key])+ } finally {+ deferred.cancel()+ if (previous == null) requests.remove(track.key) else requests[track.key] = previous+ }+ }+}diff --git a/base/app/src/test/java/com/music/spotui/data/api/SupportReminderTest.kt b/base/app/src/test/java/com/music/spotui/data/api/SupportReminderTest.ktnew file mode 100644index 00000000..e1e84f6b--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/data/api/SupportReminderTest.kt@@ -0,0 +1,33 @@+package com.music.spotui.data.api++import com.music.spotui.data.api.SupportReminder.Level+import org.junit.Assert.assertEquals+import org.junit.Test++class SupportReminderTest {+ private val day = 24 * 3_600_000L++ @Test fun firstReminderADayAfterFirstUse() {+ assertEquals(1_000L + day, SupportReminder.nextAt(1_000L, lastShown = 0L, level = Level.NONE, supportedAt = 0L))+ }++ @Test fun perksStayOffUntilSupportsCanBeChecked() {+ // Everyone gets the non-supporter cadence and the default green while they are off.+ org.junit.Assert.assertFalse(SupportReminder.PERKS_ENABLED)+ assertEquals(Level.NONE, SupportReminder.level)+ }++ @Test fun thenEveryTwoWeeksAfterTheLastAnswer() {+ assertEquals(64 * day, SupportReminder.nextAt(1_000L, lastShown = 50 * day, level = Level.NONE, supportedAt = 0L))+ }++ @Test fun aOneTimeSupporterHearsAgainAfterThreeMonths() {+ // Counted from the later of the last reminder and the support itself.+ assertEquals(100 * day, SupportReminder.nextAt(1_000L, lastShown = 5 * day, level = Level.ONCE, supportedAt = 10 * day))+ assertEquals(110 * day, SupportReminder.nextAt(1_000L, lastShown = 20 * day, level = Level.ONCE, supportedAt = 10 * day))+ }++ @Test fun aMonthlySupporterIsNeverAsked() {+ assertEquals(Long.MAX_VALUE, SupportReminder.nextAt(1_000L, lastShown = 0L, level = Level.MONTHLY, supportedAt = 1L))+ }+}diff --git a/base/app/src/test/java/com/music/spotui/data/api/UpdateCheckerTest.kt b/base/app/src/test/java/com/music/spotui/data/api/UpdateCheckerTest.ktnew file mode 100644index 00000000..d5176f30--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/data/api/UpdateCheckerTest.kt@@ -0,0 +1,28 @@+package com.music.spotui.data.api++import org.junit.Assert.assertEquals+import org.junit.Assert.assertFalse+import org.junit.Assert.assertTrue+import org.junit.Test++class UpdateCheckerTest {+ @Test fun comparesNumericallyNotAsText() {+ assertTrue(UpdateChecker.isNewer("1.10.0", "1.9.2"))+ assertTrue(UpdateChecker.isNewer("0.9.1", "0.9.0"))+ assertTrue(UpdateChecker.isNewer("1.0", "0.9.9"))+ }+ @Test fun sameOrOlderIsNotAnUpdate() {+ assertFalse(UpdateChecker.isNewer("0.9.0", "0.9.0"))+ assertFalse(UpdateChecker.isNewer("0.9", "0.9.0"))+ assertFalse(UpdateChecker.isNewer("0.8.9", "0.9.0"))+ assertFalse(UpdateChecker.isNewer("0.9.0-beta", "0.9.0"))+ assertTrue(UpdateChecker.isNewer("2.0.0", "2.0.0-beta.3"))+ assertTrue(UpdateChecker.isNewer("2.0.0-beta.2", "2.0.0-beta.1"))+ assertFalse(UpdateChecker.isNewer("2.0.0-beta.1", "2.0.0-beta.1"))+ assertTrue(UpdateChecker.isNewer("2.0.1-beta.1", "2.0.0"))+ }+ @Test fun notesKeepTheChangelogSectionAsPlainLines() {+ val body = "- **Local Files**: a folder\n - nested [link](https://x.y)\n\n**Full Changelog**: https://github.com/a/b/compare/v1...v2"+ assertEquals("• Local Files: a folder\n • nested link", UpdateChecker.cleanNotes(body))+ }+}diff --git a/base/app/src/test/java/com/music/spotui/data/offline/OfflineDownloaderTest.kt b/base/app/src/test/java/com/music/spotui/data/offline/OfflineDownloaderTest.ktnew file mode 100644index 00000000..1edd129b--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/data/offline/OfflineDownloaderTest.kt@@ -0,0 +1,62 @@+package com.music.spotui.data.offline++import com.music.spotui.data.offline.OfflineDownloader.AudioChoice+import org.junit.Assert.assertEquals+import org.junit.Assert.assertNull+import org.junit.Assert.assertTrue+import org.junit.Test++class OfflineDownloaderTest {+ @Test fun rankAudioPrefersHighestBitrateThenOpus() {+ val ranked = OfflineDownloader.rankAudio(listOf(+ AudioChoice("m4a", 48, "a"),+ AudioChoice("m4a", 128, "b"),+ AudioChoice("webm", 160, "c"),+ AudioChoice("webm", 128, "d"),+ ))+ assertEquals(listOf("c", "d", "b", "a"), ranked.map { it.url })+ }++ @Test fun normalizeIsrcAcceptsDashesAndCase() {+ assertEquals("USUM71703861", OfflineDownloader.normalizeIsrc("us-um7-17-03861"))+ assertEquals("FRZ039800212", OfflineDownloader.normalizeIsrc("FR Z03 98 00212"))+ }++ @Test fun normalizeIsrcRejectsOtherIds() {+ assertNull(OfflineDownloader.normalizeIsrc(""))+ assertNull(OfflineDownloader.normalizeIsrc("0602557362806")) // a UPC+ assertNull(OfflineDownloader.normalizeIsrc("USUM7170386")) // one digit short+ }++ private fun hit(url: String, title: String, artist: String, sec: Long) = OfflineDownloader.PreviewHit(url, title, artist, sec)++ @Test fun pickPreviewKeepsTheSameSong() {+ val results = listOf(+ hit("https://cdn/live.mp3", "Paranoïa (Live)", "MadeInParis", 312), // live take, much longer+ hit("", "Paranoïa", "MadeInParis", 163), // no preview+ hit("https://cdn/other.mp3", "Typical", "Al-Walid", 163), // same length, other song+ hit("https://cdn/album.mp3", "Paranoia", "MadeInParis", 164),+ )+ assertEquals("https://cdn/album.mp3", OfflineDownloader.pickPreview(results, "Paranoïa", "MadeInParis", 163_400))+ }++ @Test fun pickPreviewIgnoresFeatAndRemasterSuffixes() {+ val results = listOf(hit("https://cdn/a.mp3", "Yellow Submarine (Remastered 2009)", "The Beatles", 157))+ assertEquals("https://cdn/a.mp3", OfflineDownloader.pickPreview(results, "Yellow Submarine - Remastered 2009", "The Beatles", 158_000))+ val feat = listOf(hit("https://cdn/b.mp3", "Stay (feat. Guest)", "Artist", 200))+ assertEquals("https://cdn/b.mp3", OfflineDownloader.pickPreview(feat, "Stay", "Artist", 200_000))+ }++ @Test fun pickPreviewRejectsAnotherArtistOrDuration() {+ val results = listOf(hit("https://cdn/a.mp3", "GO", "Someone Else", 178))+ assertNull(OfflineDownloader.pickPreview(results, "GO", "Slimka", 178_000))+ assertNull(OfflineDownloader.pickPreview(listOf(hit("https://cdn/a.mp3", "GO", "Slimka", 178)), "GO", "Slimka", 0))+ assertNull(OfflineDownloader.pickPreview(listOf(hit("https://cdn/a.mp3", "GO", "Slimka", 178)), "GO", "Slimka", 190_000))+ }++ @Test fun localIdsNeverCollideWithMediaStoreIds() {+ for (id in listOf("4uLU6hMCjMI75M1A2tKUQC", "0", "", "zzzzzzzzzzzzzzzzzzzzzz")) {+ assertTrue(OfflineStore.localIdOf(id) < 0)+ }+ }+}diff --git a/base/app/src/test/java/com/music/spotui/ui/FindInListTest.kt b/base/app/src/test/java/com/music/spotui/ui/FindInListTest.ktnew file mode 100644index 00000000..f4f5e913--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/ui/FindInListTest.kt@@ -0,0 +1,14 @@+package com.music.spotui.ui++import com.music.spotui.ui.components.matchesFind+import org.junit.Assert.assertFalse+import org.junit.Assert.assertTrue+import org.junit.Test++class FindInListTest {+ @Test fun blankMatchesEverything() = assertTrue(matchesFind(" ", "Halo", "Beyoncé"))+ @Test fun ignoresCaseAndAccents() = assertTrue(matchesFind("BEYONCE", "Halo", "Beyoncé"))+ @Test fun everyWordInAnyField() = assertTrue(matchesFind("beyonce hal", "Halo", "Beyoncé", "I Am... Sasha Fierce"))+ @Test fun missingWordFails() = assertFalse(matchesFind("beyonce crazy", "Halo", "Beyoncé"))+ @Test fun matchesPartOfAWord() = assertTrue(matchesFind("sava", "J'SAVAIS", "Ikaz Boi"))+}diff --git a/base/app/src/test/java/com/music/spotui/ui/components/FrameCadenceTest.kt b/base/app/src/test/java/com/music/spotui/ui/components/FrameCadenceTest.ktnew file mode 100644index 00000000..4d543c1b--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/ui/components/FrameCadenceTest.kt@@ -0,0 +1,100 @@+package com.music.spotui.ui.components++import org.junit.Assert.assertEquals+import org.junit.Assert.assertFalse+import org.junit.Assert.assertTrue+import org.junit.Test++class FrameCadenceTest {+ private fun emittedSlots(fps: Int, displayHz: Int, seconds: Int = 5): List<Int> {+ val cadence = FrameCadence(fps)+ return (0 until displayHz * seconds).filter { frame ->+ cadence.shouldTick(frame.toLong() * 1_000_000_000L / displayHz)+ }+ }++ @Test fun firstFrameIsPublishedImmediately() {+ for (fps in listOf(20, 30)) {+ val cadence = FrameCadence(fps)+ assertTrue(cadence.shouldTick(1_987_654_321L))+ assertFalse(cadence.shouldTick(1_987_654_321L))+ }+ }++ @Test fun normalProgressUsesEverySecondOrFourthDisplayFrame() {+ assertEquals((0 until 300 step 2).toList(), emittedSlots(30, 60))+ assertEquals((0 until 600 step 4).toList(), emittedSlots(30, 120))+ }++ @Test fun saverProgressUsesEveryThirdOrSixthDisplayFrame() {+ assertEquals((0 until 300 step 3).toList(), emittedSlots(20, 60))+ assertEquals((0 until 600 step 6).toList(), emittedSlots(20, 120))+ }++ @Test fun slowDisplayCannotCauseMultipleTicksInOneFrame() {+ assertEquals((0 until 120).toList(), emittedSlots(30, 24))+ val cadence = FrameCadence(30)+ val frame = 41_666_666L+ assertTrue(cadence.shouldTick(frame))+ assertFalse(cadence.shouldTick(frame))+ }++ @Test fun missedFrameRebasesRatherThanCatchingUpOnTheAdjacentFrame() {+ val cadence = FrameCadence(30)+ assertTrue(cadence.shouldTick(0L))+ assertFalse(cadence.shouldTick(16_666_666L))+ // The expected frame at33ms was missed; the next frame is at50ms.+ assertTrue(cadence.shouldTick(50_000_000L))+ assertFalse(cadence.shouldTick(66_666_666L))+ assertTrue(cadence.shouldTick(83_333_333L))+ }++ @Test fun longPausePublishesOnceThenRestartsRegularSlots() {+ for (fps in listOf(20, 30)) {+ val cadence = FrameCadence(fps)+ val resumed = 600_000_000_000L+ assertTrue(cadence.shouldTick(0L))+ assertTrue(cadence.shouldTick(resumed))+ assertFalse(cadence.shouldTick(resumed))+ assertFalse(cadence.shouldTick(resumed + 16_666_666L))+ assertTrue(cadence.shouldTick(resumed + 1_000_000_000L / fps))+ }+ }++ @Test fun subMillisecondTimestampJitterDoesNotDropNominalSlots() {+ val cadence = FrameCadence(30)+ val frames = listOf(0L, 16_500_000L, 33_200_000L, 50_100_000L, 66_400_000L)+ assertEquals(listOf(true, false, true, false, true), frames.map(cadence::shouldTick))+ }++ @Test fun earlyNonDisplayPeriodDoesNotTriggerATick() {+ val cadence = FrameCadence(30)+ assertTrue(cadence.shouldTick(0L))+ assertFalse(cadence.shouldTick(32_000_000L))+ assertTrue(cadence.shouldTick(33_333_332L))+ }++ @Test fun newLifecycleInstanceHasNoWaitingPeriod() {+ val beforeStop = FrameCadence(30)+ assertTrue(beforeStop.shouldTick(1_000_000_000L))+ val afterStart = FrameCadence(30)+ assertTrue(afterStart.shouldTick(1_000_000_001L))+ }++ @Test fun clockRestartRebasesTheCadence() {+ val cadence = FrameCadence(30)+ assertTrue(cadence.shouldTick(1_000_000_000L))+ assertFalse(cadence.shouldTick(1_016_666_666L))+ assertTrue(cadence.shouldTick(0L))+ assertFalse(cadence.shouldTick(16_666_666L))+ assertTrue(cadence.shouldTick(33_333_333L))+ }++ @Test fun unsupportedRatesAreBounded() {+ val minimum = FrameCadence(0)+ assertTrue(minimum.shouldTick(0L))+ assertFalse(minimum.shouldTick(500_000_000L))+ assertTrue(minimum.shouldTick(1_000_000_000L))+ assertEquals((0 until 600).toList(), emittedSlots(Int.MAX_VALUE, 120))+ }+}diff --git a/base/app/src/test/java/com/music/spotui/ui/viewmodel/CanvasRequestsTest.kt b/base/app/src/test/java/com/music/spotui/ui/viewmodel/CanvasRequestsTest.ktnew file mode 100644index 00000000..1097a674--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/ui/viewmodel/CanvasRequestsTest.kt@@ -0,0 +1,135 @@+package com.music.spotui.ui.viewmodel++import org.junit.Assert.*+import org.junit.Test++class CanvasRequestsTest {+ private fun songId(track: String) = ("track:$track").hashCode() and 0x7fffffff++ @Test fun optimisticChangeHidesAAndConfirmedUriStartsBWithoutAnotherSongIdChange() {+ val requests = CanvasRequests()+ val a = requests.select(confirmedTrackIdForDisplay("spotify:track:A", songId("A")))!!+ requests.complete(a, "canvas-a")+ assertEquals("A", requests.state.trackId)+ val optimistic = confirmedTrackIdForDisplay("spotify:track:A", songId("B"))+ assertEquals("", optimistic)+ requests.select(optimistic)+ assertNull(requests.state.url)+ val confirmed = confirmedTrackIdForDisplay("spotify:track:B", songId("B"))+ assertEquals("B", confirmed)+ val b = requests.select(confirmed)!!+ assertTrue(b.fetch)+ assertTrue(requests.complete(b, "canvas-b"))+ assertEquals(CanvasTrackState("B", "canvas-b"), requests.state)+ }++ @Test fun lastTrackWinsWhenAnEarlierResponseCompletesLast() {+ val requests = CanvasRequests()+ val a = requests.select("A")!!+ val b = requests.select("B")!!+ assertTrue(requests.complete(b, "canvas-b"))+ assertFalse(requests.complete(a, "canvas-a"))+ assertEquals(CanvasTrackState("B", "canvas-b"), requests.state)+ }++ @Test fun replayARejectsTheFirstAGenerationAfterAToBToA() {+ val requests = CanvasRequests()+ val firstA = requests.select("A")!!+ val b = requests.select("B")!!+ val replayA = requests.select("A")!!+ assertTrue(requests.complete(replayA, "fresh-a"))+ assertFalse(requests.complete(firstA, "stale-a"))+ assertFalse(requests.complete(b, "canvas-b"))+ assertEquals(CanvasTrackState("A", "fresh-a"), requests.state)+ }++ @Test fun nullCanvasIsResolvedAndDoesNotStartRepeatedLoadsForTheSameTrack() {+ val requests = CanvasRequests()+ val a = requests.select("A")!!+ assertTrue(requests.complete(a, null))+ repeat(3) { assertNull(requests.select("A")) }+ assertEquals(CanvasTrackState("A"), requests.state)+ }++ @Test fun sameTrackAndUrlPreserveTheResolvedSnapshotWithoutNewFetch() {+ val requests = CanvasRequests()+ requests.complete(requests.select("A")!!, "same-url")+ val snapshot = requests.state+ assertNull(requests.select("A"))+ assertSame(snapshot, requests.state)+ }++ @Test fun identicalUrlForANewTrackStillHasTheNewOwner() {+ val requests = CanvasRequests()+ requests.complete(requests.select("A")!!, "same-url")+ val b = requests.select("B")!!+ assertEquals(CanvasTrackState("B"), requests.state)+ requests.complete(b, "same-url")+ assertEquals(CanvasTrackState("B", "same-url"), requests.state)+ }++ @Test fun failureFallsBackToArtworkAndCanBeRetried() {+ val requests = CanvasRequests()+ val a = requests.select("A")!!+ assertTrue(requests.fail(a))+ assertNull(requests.state.url)+ val retry = requests.select("A")!!+ assertTrue(retry.generation > a.generation)+ assertTrue(requests.complete(retry, "retry-a"))+ assertEquals(CanvasTrackState("A", "retry-a"), requests.state)+ }++ @Test fun oldFailureCannotClearTheNewTrackCanvas() {+ val requests = CanvasRequests()+ val a = requests.select("A")!!+ val b = requests.select("B")!!+ requests.complete(b, "canvas-b")+ assertFalse(requests.fail(a))+ assertEquals(CanvasTrackState("B", "canvas-b"), requests.state)+ }++ @Test fun saverDisableInvalidatesPendingAndReenableFetchesTheSameTrackSafely() {+ val requests = CanvasRequests()+ val pending = requests.select("A")!!+ val disabled = requests.select("")!!+ assertFalse(disabled.fetch)+ assertNull(requests.state.url)+ assertFalse(requests.complete(pending, "old-a"))+ val resumed = requests.select("A")!!+ assertTrue(requests.complete(resumed, "new-a"))+ assertFalse(requests.complete(pending, "old-a"))+ assertEquals(CanvasTrackState("A", "new-a"), requests.state)+ }++ @Test fun audioBufferingDefersANewLookupUntilTheSameTrackIsReady() {+ val requests = CanvasRequests()+ val deferred = requests.select("A", allowFetch = false)!!+ assertFalse(deferred.fetch)+ assertFalse(requests.complete(deferred, "unexpected"))+ assertNull(requests.select("A", allowFetch = false))+ val started = requests.select("A", allowFetch = true)!!+ assertTrue(started.fetch)+ requests.complete(started, "canvas-a")+ val snapshot = requests.state+ assertNull(requests.select("A", allowFetch = false))+ assertSame(snapshot, requests.state)+ }++ @Test fun bufferingCancelsAnInFlightGenerationBeforeItCanPublish() {+ val requests = CanvasRequests()+ val pending = requests.select("A")!!+ val blocked = requests.select("A", allowFetch = false)!!+ assertFalse(blocked.fetch)+ assertFalse(requests.complete(pending, "old-a"))+ val resumed = requests.select("A")!!+ requests.complete(resumed, "new-a")+ assertEquals(CanvasTrackState("A", "new-a"), requests.state)+ }++ @Test fun unknownAndEpisodeIdentityNeverSelectATrackCanvas() {+ assertEquals("", confirmedTrackIdForDisplay("", songId("A")))+ assertEquals("", confirmedTrackIdForDisplay("spotify:episode:A", songId("A")))+ assertEquals("", confirmedTrackIdForDisplay("spotify:track:", songId("A")))+ assertEquals("", confirmedTrackIdForDisplay("spotify:track:A", songId("B")))+ }+}diff --git a/base/app/src/test/java/com/music/spotui/video/AudioAlignTest.kt b/base/app/src/test/java/com/music/spotui/video/AudioAlignTest.ktnew file mode 100644index 00000000..eb316e84--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/video/AudioAlignTest.kt@@ -0,0 +1,176 @@+package com.music.spotui.video++import kotlinx.coroutines.runBlocking+import org.junit.Assert.assertEquals+import org.junit.Assert.assertFalse+import org.junit.Assert.assertTrue+import org.junit.Test+import java.util.Random+import kotlin.math.PI+import kotlin.math.abs+import kotlin.math.sin++/** Calls production AudioAlign; no codec, Android, network or replicated matcher. */+class AudioAlignTest {+ @Test fun emptyMapIsIdentity() {+ val map = AudioAlign.TimeMap(emptyList(), 0.0)+ for (time in listOf(0L, 1L, 12_345L)) {+ assertEquals(time, map.toVideo(time))+ assertEquals(time, map.toSong(time))+ }+ }++ @Test fun segmentsUseExclusiveEndAndNearestOffsetOutside() {+ val map = AudioAlign.TimeMap(listOf(+ AudioAlign.Segment(1_000, 4_000, 500),+ AudioAlign.Segment(6_000, 9_000, 2_000),+ ), 1.0)+ assertEquals(500L, map.toVideo(0))+ assertEquals(1_500L, map.toVideo(1_000))+ assertEquals(4_499L, map.toVideo(3_999))+ assertEquals(4_500L, map.toVideo(4_000))+ assertEquals(4_501L, map.toVideo(4_001))+ assertEquals(5_500L, map.toVideo(5_000)) // Equal distance chooses the first listed segment.+ assertEquals(7_001L, map.toVideo(5_001))+ assertEquals(8_000L, map.toVideo(6_000))+ assertEquals(11_000L, map.toVideo(9_000))+ assertEquals(12_000L, map.toVideo(10_000))+ }++ @Test fun inverseClampsVideoOnlyIntroGapAndOutro() {+ val map = AudioAlign.TimeMap(listOf(+ AudioAlign.Segment(0, 5_000, 2_000),+ AudioAlign.Segment(5_000, 10_000, 5_000),+ ), 1.0)+ assertEquals(0L, map.toSong(0))+ assertEquals(0L, map.toSong(2_000))+ assertEquals(4_999L, map.toSong(7_500))+ assertEquals(5_000L, map.toSong(9_500))+ assertEquals(5_000L, map.toSong(10_000))+ assertEquals(9_999L, map.toSong(99_999))+ for (time in listOf(0L, 1L, 4_999L, 5_000L, 9_999L)) {+ assertEquals(time, map.toSong(map.toVideo(time)))+ }+ }++ @Test fun infiniteFinalSegmentRoundTripsLargeTimes() {+ val map = AudioAlign.TimeMap(listOf(AudioAlign.Segment(0, Long.MAX_VALUE, 3_000)), 1.0)+ for (time in listOf(0L, 60_000L, 86_400_000L)) {+ assertEquals(time + 3_000, map.toVideo(time))+ assertEquals(time, map.toSong(map.toVideo(time)))+ }+ }++ @Test fun negativeOffsetExposesMissingVideoPrefix() {+ val map = AudioAlign.TimeMap(listOf(AudioAlign.Segment(0, Long.MAX_VALUE, -2_000)), 1.0)+ assertEquals(-2_000L, map.toVideo(0)) // Raw map can be negative; caller must clamp before seek.+ assertEquals(2_000L, map.toSong(0))+ }++ @Test fun pcmShorterThanFftWindowProducesNoFeatures() {+ // 805..1023 used to round (samples - 1024) / 220 towards zero, then read 1024 samples.+ for (samples in listOf(0, 1, 804, 805, 900, 1023)) {+ assertTrue("$samples PCM samples are too short for a complete frame", AudioAlign.features(FloatArray(samples)).isEmpty())+ }+ }++ @Test fun insufficientAlignmentAndSilenceHaveNoCredibleMatch() = runBlocking {+ val short = AudioAlign.align(Array(1) { DoubleArray(32) }, Array(1) { DoubleArray(32) })+ assertTrue(short.segments.isEmpty())+ assertEquals(0.0, short.score, 0.0)+ val silent = AudioAlign.features(FloatArray(SR * 8))+ val map = AudioAlign.align(silent, silent)+ assertTrue(map.score.isFinite())+ assertTrue("Silence must not pass the controller's MIN_SCORE=0.4", map.score < 0.4)+ }++ @Test fun shiftedSyntheticPcmFindsKnownOffset() = runBlocking {+ val song = synthetic(1_050)+ val video = prefix(song, 100)+ val map = AudioAlign.align(AudioAlign.features(song), AudioAlign.features(video))+ assertCredible(map)+ assertOffset(map, 4_000, framesMs(100))+ assertOffset(map, 15_000, framesMs(100))+ }++ @Test fun insertedSkitsCreateMultipleOffsets() = runBlocking {+ val song = synthetic(1_500)+ val introFrames = 100+ val skitFrames = 150+ val split = HOP * 600+ val video = FloatArray(introFrames * HOP + song.size + skitFrames * HOP)+ song.copyInto(video, introFrames * HOP, 0, split)+ song.copyInto(video, (introFrames + skitFrames) * HOP + split, split)+ val map = AudioAlign.align(AudioAlign.features(song), AudioAlign.features(video))+ assertCredible(map)+ assertTrue("An inserted skit must produce multiple mapping segments: ${map.segments}", map.segments.size >= 2)+ assertOffset(map, 3_000, framesMs(introFrames))+ assertOffset(map, 24_000, framesMs(introFrames + skitFrames))+ }++ @Test fun repeatedChorusKeepsForwardContinuousPath() = runBlocking {+ val song = synthetic(1_500)+ // The same six-second chorus appears twice, with unique material on either side.+ song.copyInto(song, HOP * 900, HOP * 150, HOP * 450)+ val map = AudioAlign.align(AudioAlign.features(song), AudioAlign.features(prefix(song, 75)))+ assertCredible(map)+ for (time in listOf(2_000L, 6_000L, 15_000L, 22_000L, 27_000L)) {+ assertOffset(map, time, framesMs(75))+ }+ assertTrue(map.toVideo(22_000) > map.toVideo(6_000))+ }++ @Test fun addedNoiseKeepsOffsetWithinOneHundredMilliseconds() = runBlocking {+ val song = synthetic(1_050)+ val video = prefix(song, 100)+ val rng = Random(981L)+ for (i in video.indices) video[i] += ((rng.nextDouble() - 0.5) * 0.06).toFloat()+ val map = AudioAlign.align(AudioAlign.features(song), AudioAlign.features(video))+ assertCredible(map)+ assertOffset(map, 4_000, framesMs(100))+ assertOffset(map, 15_000, framesMs(100))+ }++ @Test fun prefixOnlyAlignmentCannotDiscoverLaterSkits() = runBlocking {+ val song = synthetic(1_500)+ val intro = 100 * HOP+ val split = 900 * HOP+ val skit = 150 * HOP+ val video = FloatArray(intro + song.size + skit)+ song.copyInto(video, intro, 0, split)+ song.copyInto(video, intro + split + skit, split)+ // Production first-pass decode limits are 45 s / 100 s; shortened here for a fast JVM repro.+ val prefixSamples = 600 * HOP + N+ val map = AudioAlign.align(AudioAlign.features(song.copyOf(prefixSamples)),+ AudioAlign.features(video.copyOf(intro + prefixSamples)))+ assertCredible(map)+ assertEquals(Long.MAX_VALUE, map.segments.last().songEndMs)+ val expectedFullOffset = framesMs(250)+ assertFalse("A prefix cannot know about a later inserted skit", abs(map.toVideo(26_000) - 26_000 - expectedFullOffset) <= 100)+ }++ private fun synthetic(frames: Int): FloatArray {+ val random = Random(77419L)+ val pitches = IntArray((frames * HOP + N) / 1_100 + 1) { 150 + random.nextInt(3_500) }+ return FloatArray(frames * HOP + N) { i ->+ val frequency = pitches[i / 1_100]+ val phase = 2 * PI * frequency * i / SR+ val envelope = 0.3 + 0.7 * ((i % 1_100) / 1_100.0)+ (envelope * (0.3 * sin(phase) + 0.15 * sin(phase * 1.5)) + 0.08 * (random.nextDouble() - 0.5)).toFloat()+ }+ }++ private fun prefix(song: FloatArray, frames: Int) = FloatArray(frames * HOP + song.size).also {+ song.copyInto(it, frames * HOP)+ }+ private fun assertCredible(map: AudioAlign.TimeMap) {+ assertTrue("Expected a credible match, score=${map.score}, segments=${map.segments}", map.score >= 0.4)+ assertTrue(map.segments.isNotEmpty())+ }+ private fun assertOffset(map: AudioAlign.TimeMap, songMs: Long, expected: Long) {+ val actual = map.toVideo(songMs) - songMs+ assertTrue("At song=$songMs expected offset=$expected ±100 ms, got $actual; ${map.segments}", abs(actual - expected) <= 100)+ }+ private fun framesMs(frames: Int) = (frames * HOP.toDouble() / SR * 1_000).toLong()+ private companion object { const val SR = 11_025; const val HOP = 220; const val N = 1_024 }+}diff --git a/base/app/src/test/java/com/music/spotui/video/AudioDecodeCapacityTest.kt b/base/app/src/test/java/com/music/spotui/video/AudioDecodeCapacityTest.ktnew file mode 100644index 00000000..d75fefa3--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/video/AudioDecodeCapacityTest.kt@@ -0,0 +1,27 @@+package com.music.spotui.video++import org.junit.Assert.assertEquals+import org.junit.Assert.assertTrue+import org.junit.Test++class AudioDecodeCapacityTest {+ @Test fun prefixAllocationUsesLimitInsteadOfFullContainerDuration() {+ assertEquals(46 * 11_025, AudioAlign.decodeCapacity(240_000_000, 45))+ assertEquals(101 * 11_025, AudioAlign.decodeCapacity(240_000_000, 100))+ }+ @Test fun unknownDurationStillRespectsPrefixLimit() {+ assertEquals(46 * 11_025, AudioAlign.decodeCapacity(0, 45))+ assertEquals(46 * 11_025, AudioAlign.decodeCapacity(-1, 45))+ }+ @Test fun shortContainerKeepsItsSmallerCapacity() {+ assertEquals(11 * 11_025, AudioAlign.decodeCapacity(10_000_000, 45))+ }+ @Test fun fullDecodeAndUnknownDurationPreserveExistingSizing() {+ assertEquals(241 * 11_025, AudioAlign.decodeCapacity(240_000_000, 0))+ assertEquals(1 shl 22, AudioAlign.decodeCapacity(0, 0))+ }+ @Test fun extremeDurationAndLimitCannotOverflowNegativeCapacity() {+ assertTrue(AudioAlign.decodeCapacity(Long.MAX_VALUE, 0) > 0)+ assertTrue(AudioAlign.decodeCapacity(Long.MAX_VALUE, Int.MAX_VALUE) > 0)+ }+}diff --git a/base/app/src/test/java/com/music/spotui/video/AudioFeatureCancellationTest.kt b/base/app/src/test/java/com/music/spotui/video/AudioFeatureCancellationTest.ktnew file mode 100644index 00000000..1941b087--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/video/AudioFeatureCancellationTest.kt@@ -0,0 +1,25 @@+package com.music.spotui.video++import org.junit.Assert.assertFalse+import org.junit.Assert.assertTrue+import org.junit.Test+import java.util.concurrent.atomic.AtomicReference++class AudioFeatureCancellationTest {+ @Test fun interruptedWorkerAbortsFeatureExtraction() {+ val failure = AtomicReference<Throwable?>()+ val worker = Thread {+ Thread.currentThread().interrupt()+ try {+ AudioAlign.features(FloatArray(11_025 * 10))+ failure.set(AssertionError("Interrupted feature extraction completed instead of aborting"))+ } catch (t: Throwable) {+ failure.set(t)+ }+ }+ worker.start()+ worker.join(5_000)+ assertFalse("Interrupted worker must terminate", worker.isAlive)+ assertTrue("Expected InterruptedException, got ${failure.get()}", failure.get() is InterruptedException)+ }+}diff --git a/base/app/src/test/java/com/music/spotui/video/InterruptibleHttpTest.kt b/base/app/src/test/java/com/music/spotui/video/InterruptibleHttpTest.ktnew file mode 100644index 00000000..c8828d7c--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/video/InterruptibleHttpTest.kt@@ -0,0 +1,109 @@+package com.music.spotui.video++import okhttp3.Call+import okhttp3.Callback+import okhttp3.EventListener+import okhttp3.Protocol+import okhttp3.Request+import okhttp3.Response+import okhttp3.ResponseBody+import okio.Buffer+import okio.BufferedSource+import okio.ForwardingSource+import okio.Timeout+import okio.buffer+import org.junit.Assert.*+import org.junit.Test+import java.io.IOException+import java.util.concurrent.CountDownLatch+import java.util.concurrent.TimeUnit+import java.util.concurrent.atomic.AtomicBoolean+import java.util.concurrent.atomic.AtomicInteger+import java.util.concurrent.atomic.AtomicReference+import kotlin.reflect.KClass++class InterruptibleHttpTest {+ @Test fun callbackResultIsReturnedAndResponseClosed() {+ val call = FakeCall()+ val result = AtomicReference<String?>(); val error = AtomicReference<Throwable?>()+ val reader = thread { try { result.set(InterruptibleHttp.read(call) { it.body!!.string() }) } catch (t: Throwable) { error.set(t) } }+ assertTrue(call.enqueued.await(3, TimeUnit.SECONDS)); call.respond(); reader.joinChecked()+ assertNull(error.get()); assertEquals("metadata", result.get()); assertTrue(call.bodyClosed.get())+ assertEquals(1, call.enqueues.get()); assertEquals(0, call.cancels.get())+ }++ @Test fun interruptedPendingReadCancelsExactlyOnceAndDoesNotRetry() {+ val call = FakeCall(); val error = AtomicReference<Throwable?>(); val interrupted = AtomicBoolean()+ val reader = thread { try { InterruptibleHttp.read(call) { "wrong" } } catch (t: Throwable) { error.set(t); interrupted.set(Thread.currentThread().isInterrupted) } }+ assertTrue(call.enqueued.await(3, TimeUnit.SECONDS)); reader.interrupt(); reader.joinChecked()+ assertTrue(error.get() is InterruptedException); assertTrue(interrupted.get())+ assertEquals(1, call.enqueues.get()); assertEquals(1, call.cancels.get())+ }++ @Test fun preInterruptedReadNeverEnqueuesARequest() {+ val call = FakeCall(); val error = AtomicReference<Throwable?>()+ val reader = thread { Thread.currentThread().interrupt(); try { InterruptibleHttp.read(call) { "wrong" } } catch (t: Throwable) { error.set(t) } }+ reader.joinChecked(); assertTrue(error.get() is InterruptedException); assertEquals(0, call.enqueues.get())+ }++ @Test fun interruptionDuringCallbackDecodeCancelsAndClosesResponse() {+ val call = FakeCall(); val entered = CountDownLatch(1); val error = AtomicReference<Throwable?>()+ val reader = thread {+ try { InterruptibleHttp.read(call) { entered.countDown(); call.cancelled.await(); throw IOException("cancelled body read") } }+ catch (t: Throwable) { error.set(t) }+ }+ assertTrue(call.enqueued.await(3, TimeUnit.SECONDS)); val callback = thread { call.respond() }+ assertTrue(entered.await(3, TimeUnit.SECONDS)); reader.interrupt()+ reader.joinChecked(); callback.joinChecked()+ assertTrue(error.get() is InterruptedException); assertEquals(1, call.cancels.get()); assertTrue(call.bodyClosed.get())+ }++ @Test fun backendFailureIsPropagatedWithoutStartingARetry() {+ val call = FakeCall(); val error = AtomicReference<Throwable?>()+ val reader = thread { try { InterruptibleHttp.read(call) { "wrong" } } catch (t: Throwable) { error.set(t) } }+ assertTrue(call.enqueued.await(3, TimeUnit.SECONDS)); call.fail(IOException("backend unavailable")); reader.joinChecked()+ assertEquals("backend unavailable", error.get()?.message); assertEquals(1, call.enqueues.get()); assertEquals(0, call.cancels.get())+ }++ private class FakeCall : Call {+ val enqueued = CountDownLatch(1); val cancelled = CountDownLatch(1)+ val enqueues = AtomicInteger(); val cancels = AtomicInteger(); val bodyClosed = AtomicBoolean()+ private val delivered = AtomicBoolean(); private val cancelledFlag = AtomicBoolean()+ @Volatile private var callback: Callback? = null+ private val req = Request.Builder().url("https://metadata.invalid/example").build()+ private val tags = mutableMapOf<Class<*>, Any>()+ override fun request() = req+ override fun enqueue(responseCallback: Callback) { callback = responseCallback; enqueues.incrementAndGet(); enqueued.countDown() }+ override fun execute(): Response = error("Fake transport only supports enqueue")+ override fun cancel() {+ cancels.incrementAndGet(); cancelledFlag.set(true); cancelled.countDown()+ if (delivered.compareAndSet(false, true)) callback?.onFailure(this, IOException("cancelled"))+ }+ override fun isExecuted() = enqueues.get() > 0+ override fun isCanceled() = cancelledFlag.get()+ override fun timeout() = Timeout()+ public override fun clone(): Call = FakeCall()+ override fun addEventListener(eventListener: EventListener) = Unit+ override fun <T : Any> tag(type: KClass<T>): T? = tag(type.java)+ override fun <T> tag(type: Class<out T>): T? = synchronized(tags) { type.cast(tags[type]) }+ override fun <T : Any> tag(type: KClass<T>, computeIfAbsent: () -> T): T = tag(type.java, computeIfAbsent)+ override fun <T : Any> tag(type: Class<T>, computeIfAbsent: () -> T): T = synchronized(tags) {+ type.cast(tags[type]) ?: computeIfAbsent().also { tags[type] = it }+ }+ fun fail(failure: IOException) { if (delivered.compareAndSet(false, true)) callback!!.onFailure(this, failure) }+ fun respond() {+ if (!delivered.compareAndSet(false, true)) return+ val body = object : ResponseBody() {+ private val source = object : ForwardingSource(Buffer().writeUtf8("metadata")) {+ override fun close() { bodyClosed.set(true); super.close() }+ }.buffer()+ override fun contentType(): okhttp3.MediaType? = null+ override fun contentLength() = 8L+ override fun source(): BufferedSource = source+ }+ callback!!.onResponse(this, Response.Builder().request(req).protocol(Protocol.HTTP_1_1).code(200).message("OK").body(body).build())+ }+ }+ private fun thread(block: () -> Unit) = Thread(block).apply { isDaemon = true; start() }+ private fun Thread.joinChecked() { join(4_000); assertFalse("HTTP worker did not finish", isAlive) }+}diff --git a/base/app/src/test/java/com/music/spotui/video/OrderedClipResolverTest.kt b/base/app/src/test/java/com/music/spotui/video/OrderedClipResolverTest.ktnew file mode 100644index 00000000..02eb18d6--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/video/OrderedClipResolverTest.kt@@ -0,0 +1,56 @@+package com.music.spotui.video++import kotlinx.coroutines.CancellationException+import kotlinx.coroutines.delay+import kotlinx.coroutines.runBlocking+import kotlinx.coroutines.withTimeout+import org.junit.Assert.*+import org.junit.Test++class OrderedClipResolverTest {+ @Test fun firstMatchCancelsSlowSiblingAndNeverDownloadsOtherCandidates() = runBlocking {+ val requests = mutableListOf<Int>(); val verified = mutableListOf<Int>(); var siblingCancelled = false+ val result = withTimeout(1000) {+ firstVerifiedClip((0..5).toList(), classify = {+ requests += it+ try { delay(if (it == 0) 10L else 10_000L); "MUSIC_VIDEO_TYPE_OMV" }+ catch (e: CancellationException) { siblingCancelled = true; throw e }+ }, verify = { verified += it; ClipVerification("clip-$it") })+ }+ assertEquals("clip-0", result.value)+ assertEquals(listOf(0, 1), requests)+ assertEquals(listOf(0), verified)+ assertTrue(siblingCancelled)+ }+ @Test fun audioMismatchFallsBackInRankOrder() = runBlocking {+ val tried = mutableListOf<Int>()+ val result = firstVerifiedClip(listOf(1, 2, 3), { "MUSIC_VIDEO_TYPE_OMV" }) {+ tried += it; ClipVerification(if (it == 2) "matched" else null)+ }+ assertEquals("matched", result.value); assertEquals(listOf(1, 2), tried)+ }+ @Test fun identityWorkIsBoundedWhenEveryOfficialCandidateMismatches() = runBlocking {+ var downloaded = 0+ val result = firstVerifiedClip((0..9).toList(), { "MUSIC_VIDEO_TYPE_OMV" }) {+ downloaded++; ClipVerification<String>()+ }+ assertNull(result.value); assertEquals(3, downloaded)+ }+ @Test fun classificationNeverAcceptsUnofficialUploads() = runBlocking {+ var downloaded = 0+ val result = firstVerifiedClip(listOf(0, 1), { "MUSIC_VIDEO_TYPE_UGC" }) {+ downloaded++; ClipVerification("bad")+ }+ assertNull(result.value); assertFalse(result.failed); assertEquals(0, downloaded)+ }+ @Test fun unknownClassificationMustNotBeCachedAsUnavailable() = runBlocking {+ val result = firstVerifiedClip(listOf(0, 1), { if (it == 0) null else "MUSIC_VIDEO_TYPE_ATV" }) { ClipVerification("unused") }+ assertNull(result.value); assertTrue(result.failed)+ }+ @Test fun failedDownloadAllowsAnotherOfficialCandidate() = runBlocking {+ val result = firstVerifiedClip(listOf(0, 1), { "MUSIC_VIDEO_TYPE_OMV" }) {+ if (it == 0) ClipVerification(failed = true) else ClipVerification("next")+ }+ assertEquals("next", result.value)+ }+}diff --git a/base/app/src/test/java/com/music/spotui/video/RangeAudioDownloadTest.kt b/base/app/src/test/java/com/music/spotui/video/RangeAudioDownloadTest.ktnew file mode 100644index 00000000..8ffb28f9--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/video/RangeAudioDownloadTest.kt@@ -0,0 +1,50 @@+package com.music.spotui.video++import com.sun.net.httpserver.HttpServer+import kotlinx.coroutines.*+import okhttp3.OkHttpClient+import org.junit.Assert.*+import org.junit.Test+import java.io.File+import java.net.InetSocketAddress+import java.util.concurrent.CountDownLatch+import java.util.concurrent.TimeUnit++class RangeAudioDownloadTest {+ @Test fun streamsRangedResponseToDiskAndPreservesHeaders() = runBlocking {+ val data = ByteArray(131072) { (it % 251).toByte() }+ val server = HttpServer.create(InetSocketAddress("127.0.0.1", 0), 0)+ var range = ""; var header = ""+ server.createContext("/audio") { exchange ->+ range = exchange.requestURI.rawQuery; header = exchange.requestHeaders.getFirst("X-Test")+ exchange.sendResponseHeaders(200, data.size.toLong())+ exchange.responseBody.use { it.write(data) }+ }+ server.start()+ val out = File.createTempFile("audio-range", ".bin"); val client = OkHttpClient()+ try {+ RangeAudioDownload.fetch(client, "http://127.0.0.1:${server.address.port}/audio?clen=${data.size}", out, mapOf("X-Test" to "kept"))+ assertArrayEquals(data, out.readBytes()); assertTrue(range.contains("range=0-131071")); assertEquals("kept", header)+ } finally { out.delete(); server.stop(0); client.dispatcher.executorService.shutdownNow(); client.connectionPool.evictAll() }+ }+ @Test fun cancelledTrackStopsAnActiveResponseInsteadOfWaitingForTimeout() = runBlocking {+ val entered = CountDownLatch(1); val release = CountDownLatch(1)+ val server = HttpServer.create(InetSocketAddress("127.0.0.1", 0), 0)+ server.createContext("/slow") { exchange ->+ try {+ exchange.sendResponseHeaders(200, 100_000)+ exchange.responseBody.write(ByteArray(2048)); exchange.responseBody.flush(); entered.countDown()+ release.await(5, TimeUnit.SECONDS)+ } catch (_: Exception) {} finally { exchange.close() }+ }+ server.start()+ val out = File.createTempFile("audio-cancel", ".bin"); val client = OkHttpClient()+ try {+ val job = launch(Dispatchers.IO) { RangeAudioDownload.fetch(client, "http://127.0.0.1:${server.address.port}/slow?clen=100000", out, emptyMap()) }+ assertTrue(entered.await(2, TimeUnit.SECONDS))+ withTimeout(1000) { job.cancelAndJoin() }+ assertTrue(job.isCancelled)+ assertTrue(out.length() < 100_000)+ } finally { release.countDown(); server.stop(0); out.delete(); client.dispatcher.executorService.shutdownNow(); client.connectionPool.evictAll() }+ }+}diff --git a/base/app/src/test/java/com/music/spotui/video/RefinementFilesTest.kt b/base/app/src/test/java/com/music/spotui/video/RefinementFilesTest.ktnew file mode 100644index 00000000..3e01b8d3--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/video/RefinementFilesTest.kt@@ -0,0 +1,47 @@+package com.music.spotui.video++import org.junit.Assert.*+import org.junit.Rule+import org.junit.Test+import org.junit.rules.TemporaryFolder+import java.io.File++class RefinementFilesTest {+ @get:Rule val temp = TemporaryFolder()++ @Test fun retainedPairKeepsContentsUntilOwnerCloses() {+ val ref = temp.newFile("reference").apply { writeText("reference PCM container") }+ val cand = temp.newFile("candidate").apply { writeText("candidate PCM container") }+ val owned = RefinementFiles.retain(ref, cand, temp.root)!!+ assertFalse(ref.exists())+ assertFalse(cand.exists())+ assertEquals("reference PCM container", owned.reference.readText())+ assertEquals("candidate PCM container", owned.candidate.readText())+ owned.close()+ owned.close()+ assertFalse(owned.reference.exists())+ assertFalse(owned.candidate.exists())+ }++ @Test fun secondRenameFailureRemovesAlreadyMovedReference() {+ val ref = temp.newFile("reference").apply { writeText("reference") }+ val absent = File(temp.root, "missing-candidate")+ assertNull(RefinementFiles.retain(ref, absent, temp.root))+ assertTrue("Failed ownership transfer must leave no mv_full file", temp.root.listFiles()!!.none { it.name.startsWith("mv_full_") })+ }++ @Test fun twoRunsOfSameTrackDoNotSharePathsOrCleanup() {+ val first = RefinementFiles.empty(temp.root)+ val second = RefinementFiles.empty(temp.root)+ assertNotEquals(first.reference, second.reference)+ assertNotEquals(first.candidate, second.candidate)+ first.reference.writeText("first")+ first.candidate.writeText("first")+ second.reference.writeText("second")+ second.candidate.writeText("second")+ first.close()+ assertEquals("second", second.reference.readText())+ assertEquals("second", second.candidate.readText())+ second.close()+ }+}diff --git a/base/app/src/test/java/com/music/spotui/video/SingleFlightCacheTest.kt b/base/app/src/test/java/com/music/spotui/video/SingleFlightCacheTest.ktnew file mode 100644index 00000000..4e70b8d5--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/video/SingleFlightCacheTest.kt@@ -0,0 +1,136 @@+package com.music.spotui.video++import org.junit.Assert.*+import org.junit.Test+import java.io.IOException+import java.util.concurrent.CountDownLatch+import java.util.concurrent.Semaphore+import java.util.concurrent.TimeUnit+import java.util.concurrent.atomic.AtomicInteger+import java.util.concurrent.atomic.AtomicLong+import java.util.concurrent.atomic.AtomicReference++class SingleFlightCacheTest {+ @Test fun parallelReadersShareOneLoadAndWarmHitsHaveNoBackendCalls() {+ val cache = SingleFlightCache<String, String>(2, 1_000)+ val calls = AtomicInteger()+ val workers = List(8) { worker { cache.get("video") { calls.incrementAndGet(); Thread.sleep(40); "metadata" } } }+ workers.forEach { it.start() }; workers.forEach { it.joinChecked() }+ assertEquals(1, calls.get())+ workers.forEach { assertEquals("metadata", it.result.get()) }+ assertEquals("metadata", cache.get("video") { fail("Warm cache must not call the backend"); "wrong" })+ assertEquals(1, cache.cachedSize)+ assertEquals(0, cache.inFlightCount)+ }++ @Test fun fakeMonotonicClockExpiresAtExactTtlAndLruIsBounded() {+ val clock = AtomicLong(0)+ val cache = SingleFlightCache<String, Int>(2, 100, clock::get)+ val calls = AtomicInteger()+ fun get(key: String) = cache.get(key) { calls.incrementAndGet() }+ assertEquals(1, get("a")); assertEquals(2, get("b")); assertEquals(1, get("a"))+ assertEquals(3, get("c")); assertEquals(2, cache.cachedSize)+ assertEquals(4, get("b")) // a was accessed; b was evicted.+ clock.set(99); assertEquals(4, get("b"))+ clock.set(100); assertEquals(5, get("b"))+ assertEquals(1, cache.cachedSize) // Expired entries are removed, not retained forever.+ }++ @Test fun forcedRefreshJoinsAnActiveRefreshAndNormalReadersJoinItToo() {+ val cache = SingleFlightCache<String, String>(2, 10_000)+ assertEquals("old", cache.get("v") { "old" })+ val calls = AtomicInteger()+ val entered = CountDownLatch(1)+ val release = CountDownLatch(1)+ val owner = worker { cache.get("v", fresh = true) { calls.incrementAndGet(); entered.countDown(); release.await(); "new" } }+ owner.start(); assertTrue(entered.await(3, TimeUnit.SECONDS))+ val fresh = worker { cache.get("v", fresh = true) { calls.incrementAndGet(); "wrong" } }+ val normal = worker { cache.get("v") { calls.incrementAndGet(); "wrong" } }+ fresh.start(); normal.start(); awaitBlocked(fresh, normal)+ release.countDown(); owner.joinChecked(); fresh.joinChecked(); normal.joinChecked()+ assertEquals(1, calls.get())+ listOf(owner, fresh, normal).forEach { assertEquals("new", it.result.get()) }+ }++ @Test fun failuresAreNotCachedAndFailedForceRefreshDoesNotRestoreAnOldUrl() {+ val cache = SingleFlightCache<String, String>(2, 10_000)+ cache.get("v") { "expired-url" }+ try { cache.get("v", fresh = true) { throw IOException("403") }; fail("Expected failure") }+ catch (expected: IOException) { assertEquals("403", expected.message) }+ assertEquals(0, cache.cachedSize); assertEquals(0, cache.inFlightCount)+ assertEquals("new-url", cache.get("v") { "new-url" })+ }++ @Test fun interruptedWaiterLeavesOwnerAliveWithoutStartingAnotherBackendCall() {+ val cache = SingleFlightCache<String, String>(2, 10_000)+ val calls = AtomicInteger(); val entered = CountDownLatch(1); val release = CountDownLatch(1)+ val owner = worker { cache.get("v") { calls.incrementAndGet(); entered.countDown(); release.await(); "value" } }+ owner.start(); assertTrue(entered.await(3, TimeUnit.SECONDS))+ val waiter = worker { cache.get("v") { calls.incrementAndGet(); "wrong" } }+ waiter.start(); awaitBlocked(waiter); waiter.interrupt(); waiter.joinChecked(allowFailure = true)+ assertTrue(waiter.error.get() is InterruptedException)+ assertTrue(owner.isAlive); assertEquals(1, calls.get())+ release.countDown(); owner.joinChecked()+ assertEquals("value", owner.result.get()); assertEquals(1, calls.get())+ }++ @Test fun interruptedOwnerFailsSharedFlightWithoutRetryOrCachingAndLaterRequestCanRetry() {+ val cache = SingleFlightCache<String, String>(2, 10_000)+ val calls = AtomicInteger(); val entered = CountDownLatch(1); val release = CountDownLatch(1)+ val owner = worker { cache.get("v") { calls.incrementAndGet(); entered.countDown(); release.await(); "wrong" } }+ owner.start(); assertTrue(entered.await(3, TimeUnit.SECONDS))+ val waiter = worker { cache.get("v") { calls.incrementAndGet(); "wrong" } }+ waiter.start(); awaitBlocked(waiter); owner.interrupt()+ owner.joinChecked(allowFailure = true); waiter.joinChecked(allowFailure = true)+ assertTrue(owner.error.get() is InterruptedException); assertTrue(waiter.error.get() is InterruptedException)+ assertEquals(1, calls.get()); assertEquals(0, cache.cachedSize); assertEquals(0, cache.inFlightCount)+ assertEquals("retry", cache.get("v") { calls.incrementAndGet(); "retry" }); assertEquals(2, calls.get())+ }++ @Test fun preInterruptedCallerDoesNotLoadOrReadEvenAWarmCache() {+ val cache = SingleFlightCache<String, String>(2, 1_000)+ cache.get("v") { "warm" }+ val calls = AtomicInteger()+ val reader = worker { Thread.currentThread().interrupt(); cache.get("v") { calls.incrementAndGet(); "wrong" } }+ reader.start(); reader.joinChecked(allowFailure = true)+ assertTrue(reader.error.get() is InterruptedException); assertEquals(0, calls.get())+ }++ @Test fun benchmarkSharedMetadataOnTwoSlotFakeBackend() {+ fun batch(cached: Boolean): Pair<Long, Int> {+ val slots = Semaphore(2)+ val calls = AtomicInteger()+ val cache = SingleFlightCache<String, String>(2, 10_000)+ val start = CountDownLatch(1)+ fun backend(): String {+ slots.acquire()+ try { calls.incrementAndGet(); Thread.sleep(75); return "metadata" }+ finally { slots.release() }+ }+ val workers = List(8) { worker { start.await(); if (cached) cache.get("v", load = ::backend) else backend() } }+ workers.forEach { it.start() }; val t0 = System.nanoTime(); start.countDown()+ workers.forEach { it.joinChecked() }+ return (System.nanoTime() - t0) / 1_000_000 to calls.get()+ }+ val raw = batch(false); val shared = batch(true)+ assertEquals(8, raw.second); assertEquals(1, shared.second)+ println("FAKE_METADATA_BENCH clients=8 backendSlots=2 backendDelayMs=75 rawMs=${raw.first} rawCalls=${raw.second} sharedMs=${shared.first} sharedCalls=${shared.second}")+ }++ private class Worker(block: () -> String) : Thread() {+ val result = AtomicReference<String?>(); val error = AtomicReference<Throwable?>()+ private val task = block+ init { isDaemon = true }+ override fun run() { try { result.set(task()) } catch (t: Throwable) { error.set(t) } }+ fun joinChecked(allowFailure: Boolean = false) {+ join(4_000); assertFalse("Worker did not finish", isAlive)+ if (!allowFailure) error.get()?.let { throw AssertionError("Worker failed", it) }+ }+ }+ private fun worker(block: () -> String) = Worker(block)+ private fun awaitBlocked(vararg workers: Worker) {+ val deadline = System.nanoTime() + TimeUnit.SECONDS.toNanos(3)+ while (workers.any { it.state != Thread.State.WAITING } && System.nanoTime() < deadline) Thread.sleep(1)+ assertTrue("Waiters must have joined the active flight", workers.all { it.state == Thread.State.WAITING })+ }+}diff --git a/base/app/src/test/java/com/music/spotui/video/VideoLookupPolicyTest.kt b/base/app/src/test/java/com/music/spotui/video/VideoLookupPolicyTest.ktnew file mode 100644index 00000000..04c44a6b--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/video/VideoLookupPolicyTest.kt@@ -0,0 +1,28 @@+package com.music.spotui.video++import org.junit.Assert.assertFalse+import org.junit.Assert.assertTrue+import org.junit.Test++class VideoLookupPolicyTest {+ @Test fun normalResumeMayWarmTheCurrentTrack() {+ assertTrue(videoLookupOnResumeAllowed(allowAutomatic = true, wantVideo = false, videoOn = false, playerVisible = false))+ }++ @Test fun saverSkipsAnAutomaticLookupOnAppResume() {+ assertFalse(videoLookupOnResumeAllowed(allowAutomatic = false, wantVideo = false, videoOn = false, playerVisible = false))+ }++ @Test fun requestedVideoCanResumeAndFollowTracksInSaver() {+ assertTrue(videoLookupOnResumeAllowed(allowAutomatic = false, wantVideo = true, videoOn = false, playerVisible = false))+ }++ @Test fun alreadyPlayingVideoCanResumeInSaver() {+ assertTrue(videoLookupOnResumeAllowed(allowAutomatic = false, wantVideo = false, videoOn = true, playerVisible = false))+ assertTrue(videoLookupOnResumeAllowed(allowAutomatic = false, wantVideo = true, videoOn = true, playerVisible = false))+ }++ @Test fun visiblePlayerCanResumeItsLookupInSaverWithoutVideoMode() {+ assertTrue(videoLookupOnResumeAllowed(allowAutomatic = false, wantVideo = false, videoOn = false, playerVisible = true))+ }+}diff --git a/base/app/src/test/java/com/music/spotui/video/YouTubeSourceTest.kt b/base/app/src/test/java/com/music/spotui/video/YouTubeSourceTest.ktnew file mode 100644index 00000000..1029c068--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/video/YouTubeSourceTest.kt@@ -0,0 +1,97 @@+package com.music.spotui.video++import org.junit.Assert.assertEquals+import org.junit.Assert.assertFalse+import org.junit.Assert.assertTrue+import org.junit.Test++/** Private pure helpers are invoked reflectively, preserving the unmodified app sources. */+class YouTubeSourceTest {+ @Test fun titleMatchesIgnoresCasePunctuationAndFeatSuffix() {+ assertTrue(titleMatches("Beyoncé - Halo (Official Music Video)", "HALO"))+ assertTrue(titleMatches("Artist — One More Time (Official Video)", "One More Time"))+ assertTrue(titleMatches("Artist — Stay", "Stay (feat. Guest)"))+ assertTrue(titleMatches("Artist — Stay", "Stay feat. Guest"))+ }++ @Test fun titleMatchesRejectsUnrelatedTitles() {+ assertFalse(titleMatches("Artist — Another Song (Official Video)", "One More Time"))+ assertFalse(titleMatches("A documentary about the artist", "Billie Jean"))+ }++ @Test fun titleMatchesDoesNotUseSubstringsAsWholeWords() {+ assertFalse("Fox is not Foxtrot", titleMatches("Foxtrot (Official Video)", "Fox"))+ assertFalse("Love is not Loveless", titleMatches("Loveless (Official Video)", "Love"))+ }++ @Test fun titleMatchesKeepsElidedWordsWhole() {+ assertTrue(titleMatches("Ikaz Boi - J'SAVAIS (ft. La Fève) (Official Visualizer)", "J'SAVAIS"))+ assertTrue(titleMatches("Ikaz Boi - J’savais", "J'SAVAIS"))+ assertFalse("Si tu savais is another song", titleMatches("Ikaz Boi (ft. Leto) - Si Tu Savais", "J'SAVAIS"))+ }++ @Test fun titleMatchesAllowsCommonAccentDifferences() {+ assertTrue(titleMatches("Artist — Deja Vu (Official Video)", "Déjà Vu"))+ }++ @Test fun normRemovesPresentationLabelsAndFeatMarker() {+ assertEquals("adelehello", norm("ADELE — Hello (Official Music Video)"))+ assertEquals("artistguest", norm("Artist feat. Guest [HD]"))+ }++ @Test fun normPreservesLettersInsideOrdinaryWords() {+ assertEquals("liftyourself", norm("Lift Yourself"))+ assertEquals("draft", norm("Draft"))+ assertEquals("audiobook", norm("Audiobook"))+ }++ @Test fun normTreatsComposedAndUnaccentedNamesEqually() {+ assertEquals(norm("Beyonce"), norm("Beyoncé"))+ assertEquals(norm("Deja Vu"), norm("Déjà Vu"))+ }++ @Test fun looksLikeClipAcceptsEnglishAndFrenchLabels() {+ for (title in listOf("Artist (Official Music Video)", "Artist (Official Video)",+ "Artist (Clip officiel)", "Artist (Vidéo officielle)", "Artist (Vidéoclip)")) {+ assertTrue(title, YouTubeSource.looksLikeClip(title))+ }+ }++ @Test fun looksLikeClipRejectsPlainAudioAndUnmarkedTitles() {+ for (title in listOf("Artist (Official Audio)", "Artist (Lyric Video)", "Artist — Song", "Artist (unofficial video)")) {+ assertFalse(title, YouTubeSource.looksLikeClip(title))+ }+ }++ @Test fun sameArtistAcceptsTopicVevoAndFirstArtist() {+ assertTrue(YouTubeSource.sameArtist(hit("Adele - Topic"), "Adele"))+ assertTrue(YouTubeSource.sameArtist(hit("AdeleVEVO"), "Adele, Guest"))+ assertFalse(YouTubeSource.sameArtist(hit("Other Artist"), "Adele"))+ assertFalse(YouTubeSource.sameArtist(hit(""), "Adele"))+ assertFalse(YouTubeSource.sameArtist(hit("Adele"), ""))+ }++ @Test fun sameArtistRejectsNamesThatOnlyShareAnInternalSubstring() {+ assertFalse("Madeleine is not Adele", YouTubeSource.sameArtist(hit("Madeleine"), "Adele"))+ assertFalse("A is not an identity check for any artist", YouTubeSource.sameArtist(hit("A"), "Adele"))+ }++ @Test fun sameArtistAllowsAccentDifferences() {+ assertTrue(YouTubeSource.sameArtist(hit("BeyonceVEVO"), "Beyoncé"))+ }++ @Test fun videoIdRequiresAnElevenCharacterWatchId() {+ assertEquals("AbCdEfGhI_1", YouTubeSource.videoId("https://www.youtube.com/watch?v=AbCdEfGhI_1&list=other"))+ assertEquals(null, YouTubeSource.videoId("https://www.youtube.com/watch?v=short"))+ }++ private fun hit(uploader: String) = YouTubeSource.Hit("https://www.youtube.com/watch?v=AbCdEfGhI_1", "Song", uploader, 180)+ private fun norm(value: String): String = call("norm", arrayOf(value)) as String+ private fun titleMatches(candidate: String, title: String): Boolean = call("titleMatches", arrayOf(candidate, title)) as Boolean+ private fun call(name: String, arguments: Array<String>): Any? {+ val parameters = Array(arguments.size) { String::class.java }+ val method = YouTubeSource::class.java.getDeclaredMethod(name, *parameters)+ method.isAccessible = true+ return method.invoke(YouTubeSource, *arguments)+ }+}diff --git a/base/app/src/test/java/com/music/spotui/video/YouTubeUrlKeyTest.kt b/base/app/src/test/java/com/music/spotui/video/YouTubeUrlKeyTest.ktnew file mode 100644index 00000000..239767a4--- /dev/null+++ b/base/app/src/test/java/com/music/spotui/video/YouTubeUrlKeyTest.kt@@ -0,0 +1,27 @@+package com.music.spotui.video++import org.junit.Assert.*+import org.junit.Test++class YouTubeUrlKeyTest {+ @Test fun knownUrlFormsAndTrackingQueriesShareCanonicalVideoKey() {+ val id = "AbCdEfGhI_1"+ val expected = "https://www.youtube.com/watch?v=$id|locale=fr-CH"+ for (url in listOf("https://www.youtube.com/watch?v=$id&list=other&t=7", "https://music.youtube.com/watch?v=$id",+ "http://youtube.com/watch?v=$id", "https://youtu.be/$id?si=track", "https://www.youtube.com/shorts/$id", "https://www.youtube.com/embed/$id")) {+ assertEquals(url, expected, YouTubeUrlKey.cacheKey(url, "fr-CH"))+ }+ }+ @Test fun idsAreExactAndAmbiguousOrUnrelatedHostsAreNotMerged() {+ for (url in listOf("https://youtube.com/watch?v=AbCdEfGhI_12", "https://youtube.com/watch?v=short",+ "https://youtube.com/watch?v=AbCdEfGhI_1&v=other000000", "https://evil.example/watch?v=AbCdEfGhI_1",+ "https://[email protected]/watch?v=AbCdEfGhI_1", "https://youtube.com:8888/watch?v=AbCdEfGhI_1")) {+ assertNull(url, YouTubeUrlKey.videoId(url)); assertEquals(url, YouTubeUrlKey.canonicalUrl(url))+ }+ }+ @Test fun localeAndDifferentVideosHaveDifferentKeys() {+ val a = "https://youtube.com/watch?v=AbCdEfGhI_1"+ assertNotEquals(YouTubeUrlKey.cacheKey(a, "fr-CH"), YouTubeUrlKey.cacheKey(a, "en-US"))+ assertNotEquals(YouTubeUrlKey.cacheKey(a, "fr-CH"), YouTubeUrlKey.cacheKey("https://youtube.com/watch?v=AbCdEfGhI_2", "fr-CH"))+ }+}diff --git a/base/build.gradle.kts b/base/build.gradle.ktsnew file mode 100644index 00000000..080f878d--- /dev/null+++ b/base/build.gradle.kts@@ -0,0 +1,7 @@+plugins {+ alias(libs.plugins.android.application) apply false+ alias(libs.plugins.android.library) apply false+ alias(libs.plugins.kotlin.compose) apply false+ alias(libs.plugins.kotlin.jvm) apply false+ alias(libs.plugins.kotlin.serialization) apply false+}\ No newline at end of filediff --git a/base/gradle.properties b/base/gradle.propertiesnew file mode 100644index 00000000..59d7ec52--- /dev/null+++ b/base/gradle.properties@@ -0,0 +1,20 @@+# Gradle: parallel, cached builds with a bounded daemon (fits a laptop and CI runners).+org.gradle.jvmargs=-Xmx3072m -XX:MaxMetaspaceSize=768m -Dfile.encoding=UTF-8+org.gradle.daemon=true+org.gradle.parallel=true+org.gradle.workers.max=2+org.gradle.caching=true+org.gradle.configuration-cache=true+org.gradle.configuration-cache.parallel=true+org.gradle.vfs.watch=true+org.gradle.tooling.parallel=true++# Kotlin+kotlin.code.style=official+kotlin.incremental=true+kotlin.daemon.jvmargs=-Xmx1536m -Dfile.encoding=UTF-8++# Android+android.useAndroidX=true+android.enableJetifier=false+android.nonTransitiveRClass=truediff --git a/base/gradle/gradle-daemon-jvm.properties b/base/gradle/gradle-daemon-jvm.propertiesnew file mode 100644index 00000000..de6cdfef--- /dev/null+++ b/base/gradle/gradle-daemon-jvm.properties@@ -0,0 +1,12 @@+#This file is generated by updateDaemonJvm+toolchainUrl.FREE_BSD.AARCH64=https\://api.foojay.io/disco/v3.0/ids/542351b649eb2bd122f0bdd21a8e74af/redirect+toolchainUrl.FREE_BSD.X86_64=https\://api.foojay.io/disco/v3.0/ids/65e59d9b9d79dc0a8e44790703568088/redirect+toolchainUrl.LINUX.AARCH64=https\://api.foojay.io/disco/v3.0/ids/542351b649eb2bd122f0bdd21a8e74af/redirect+toolchainUrl.LINUX.X86_64=https\://api.foojay.io/disco/v3.0/ids/65e59d9b9d79dc0a8e44790703568088/redirect+toolchainUrl.MAC_OS.AARCH64=https\://api.foojay.io/disco/v3.0/ids/23cf3c8c56e7e6e5fd44824184a52b46/redirect+toolchainUrl.MAC_OS.X86_64=https\://api.foojay.io/disco/v3.0/ids/de7b909e926af950f67dc8cb2cd33f0e/redirect+toolchainUrl.UNIX.AARCH64=https\://api.foojay.io/disco/v3.0/ids/542351b649eb2bd122f0bdd21a8e74af/redirect+toolchainUrl.UNIX.X86_64=https\://api.foojay.io/disco/v3.0/ids/65e59d9b9d79dc0a8e44790703568088/redirect+toolchainUrl.WINDOWS.AARCH64=https\://api.foojay.io/disco/v3.0/ids/916f6e47bbe16857b6188d9f385a936a/redirect+toolchainUrl.WINDOWS.X86_64=https\://api.foojay.io/disco/v3.0/ids/f9aa63bae008193aeb384bd02c8b44f8/redirect+toolchainVersion=21diff --git a/base/gradle/libs.versions.toml b/base/gradle/libs.versions.tomlnew file mode 100644index 00000000..10b6610f--- /dev/null+++ b/base/gradle/libs.versions.toml@@ -0,0 +1,84 @@+[versions]+agp = "9.4.1"+kotlin = "2.4.0"+coreKtx = "1.17.0"+appcompat = "1.7.1"+material = "1.14.0"+webkit = "1.13.0"+composeBom = "2026.06.01"+material3 = "1.5.0-beta01"+activityCompose = "1.10.0"+lifecycleRuntime = "2.9.0"+media = "1.7.1"+securityCrypto = "1.0.0"+bouncycastle = "1.70"+ktor = "3.5.1"+brotli = "0.1.2"+newpipe = "0.26.3"+okhttp = "5.4.0"+serialization = "1.11.0"+desugaring = "2.1.5"+glance = "1.2.0"+coroutines = "1.11.0"+junit = "5.13.4"++[libraries]+androidx-core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "coreKtx" }+androidx-appcompat = { group = "androidx.appcompat", name = "appcompat", version.ref = "appcompat" }+material = { group = "com.google.android.material", name = "material", version.ref = "material" }+androidx-webkit = { group = "androidx.webkit", name = "webkit", version.ref = "webkit" }+androidx-media = { group = "androidx.media", name = "media", version.ref = "media" }+bouncyprov = { group = "org.bouncycastle", name = "bcprov-jdk15on", version.ref = "bouncycastle" }+bouncypkix = { group = "org.bouncycastle", name = "bcpkix-jdk15on", version.ref = "bouncycastle" }+security-crypto = { group = "androidx.security", name = "security-crypto", version.ref = "securityCrypto" }++# Jetpack Compose+compose-bom = { group = "androidx.compose", name = "compose-bom", version.ref = "composeBom" }+compose-ui = { group = "androidx.compose.ui", name = "ui" }+compose-ui-graphics = { group = "androidx.compose.ui", name = "ui-graphics" }+compose-ui-tooling-preview = { group = "androidx.compose.ui", name = "ui-tooling-preview" }+compose-ui-tooling = { group = "androidx.compose.ui", name = "ui-tooling" }+compose-material3 = { group = "androidx.compose.material3", name = "material3", version.ref = "material3" }+compose-foundation = { group = "androidx.compose.foundation", name = "foundation" }+activity-compose = { group = "androidx.activity", name = "activity-compose", version.ref = "activityCompose" }+lifecycle-runtime-compose = { group = "androidx.lifecycle", name = "lifecycle-runtime-compose", version.ref = "lifecycleRuntime" }++# Glance (App Widgets)+glance-appwidget = { group = "androidx.glance", name = "glance-appwidget", version.ref = "glance" }+glance-material3 = { group = "androidx.glance", name = "glance-material3", version.ref = "glance" }++# Ktor+ktor-client-core = { group = "io.ktor", name = "ktor-client-core", version.ref = "ktor" }+ktor-client-okhttp = { group = "io.ktor", name = "ktor-client-okhttp", version.ref = "ktor" }+ktor-client-content-negotiation = { group = "io.ktor", name = "ktor-client-content-negotiation", version.ref = "ktor" }+ktor-client-encoding = { group = "io.ktor", name = "ktor-client-encoding", version.ref = "ktor" }+ktor-serialization-json = { group = "io.ktor", name = "ktor-serialization-kotlinx-json", version.ref = "ktor" }++# YouTube / NewPipe+newpipeextractor = { module = "com.github.TeamNewPipe:NewPipeExtractor", version.ref = "newpipe" }+brotli = { module = "org.brotli:dec", version.ref = "brotli" }++# Utils+okhttp = { module = "com.squareup.okhttp3:okhttp", version.ref = "okhttp" }++# Serialization+serialization-json = { module = "org.jetbrains.kotlinx:kotlinx-serialization-json", version.ref = "serialization" }++# Coroutines+coroutines-core = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-core", version.ref = "coroutines" }++# Tests+junit-bom = { module = "org.junit:junit-bom", version.ref = "junit" }+junit-jupiter = { module = "org.junit.jupiter:junit-jupiter" }+junit-launcher = { module = "org.junit.platform:junit-platform-launcher" }++# Desugaring+desugaring = { module = "com.android.tools:desugar_jdk_libs_nio", version.ref = "desugaring" }+++[plugins]+android-application = { id = "com.android.application", version.ref = "agp" }+android-library = { id = "com.android.library", version.ref = "agp" }+kotlin-jvm = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" }+kotlin-compose = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" }+kotlin-serialization = { id = "org.jetbrains.kotlin.plugin.serialization", version.ref = "kotlin" }diff --git a/base/gradle/wrapper/gradle-wrapper.jar b/base/gradle/wrapper/gradle-wrapper.jarnew file mode 100644index 00000000..eddabd2eBinary files /dev/null and b/base/gradle/wrapper/gradle-wrapper.jar differdiff --git a/base/gradle/wrapper/gradle-wrapper.properties b/base/gradle/wrapper/gradle-wrapper.propertiesnew file mode 100644index 00000000..ad7845be--- /dev/null+++ b/base/gradle/wrapper/gradle-wrapper.properties@@ -0,0 +1,9 @@+distributionBase=GRADLE_USER_HOME+distributionPath=wrapper/dists+distributionUrl=https\://services.gradle.org/distributions/gradle-9.7.1-bin.zip+networkTimeout=10000+retries=0+retryBackOffMs=500+validateDistributionUrl=true+zipStoreBase=GRADLE_USER_HOME+zipStorePath=wrapper/distsdiff --git a/base/gradlew b/base/gradlewnew file mode 100755index 00000000..249efbb0--- /dev/null+++ b/base/gradlew@@ -0,0 +1,248 @@+#!/bin/sh++#+# Copyright © 2015 the original authors.+#+# Licensed under the Apache License, Version 2.0 (the "License");+# you may not use this file except in compliance with the License.+# You may obtain a copy of the License at+#+# https://www.apache.org/licenses/LICENSE-2.0+#+# Unless required by applicable law or agreed to in writing, software+# distributed under the License is distributed on an "AS IS" BASIS,+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.+# See the License for the specific language governing permissions and+# limitations under the License.+#+# SPDX-License-Identifier: Apache-2.0+#++##############################################################################+#+# gradlew start up script for POSIX generated by Gradle.+#+# Important for running:+#+# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is+# noncompliant, but you have some other compliant shell such as ksh or+# bash, then to run this script, type that shell name before the whole+# command line, like:+#+# ksh gradlew+#+# Busybox and similar reduced shells will NOT work, because this script+# requires all of these POSIX shell features:+# * functions;+# * expansions «$var», «${var}», «${var:-default}», «${var+SET}»,+# «${var#prefix}», «${var%suffix}», and «$( cmd )»;+# * compound commands having a testable exit status, especially «case»;+# * various built-in commands including «command», «set», and «ulimit».+#+# Important for patching:+#+# (2) This script targets any POSIX shell, so it avoids extensions provided+# by Bash, Ksh, etc; in particular arrays are avoided.+#+# The "traditional" practice of packing multiple parameters into a+# space-separated string is a well documented source of bugs and security+# problems, so this is (mostly) avoided, by progressively accumulating+# options in "$@", and eventually passing that to Java.+#+# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS,+# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly;+# see the in-line comments for details.+#+# There are tweaks for specific operating systems such as AIX, CygWin,+# Darwin, MinGW, and NonStop.+#+# (3) This script is generated from the Groovy template+# https://github.com/gradle/gradle/blob/3d91ce3b8caaf77ad09f381f43615b715b53f72c/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt+# within the Gradle project.+#+# You can find Gradle at https://github.com/gradle/gradle/.+#+##############################################################################++# Attempt to set APP_HOME++# Resolve links: $0 may be a link+app_path=$0++# Need this for daisy-chained symlinks.+while+ APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path+ [ -h "$app_path" ]+do+ ls=$( ls -ld "$app_path" )+ link=${ls#*' -> '}+ case $link in #(+ /*) app_path=$link ;; #(+ *) app_path=$APP_HOME$link ;;+ esac+done++# This is normally unused+# shellcheck disable=SC2034+APP_BASE_NAME=${0##*/}+# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)+APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s\n' "$PWD" ) || exit++# Use the maximum available, or set MAX_FD != -1 to use that value.+MAX_FD=maximum++warn () {+ echo "$*"+} >&2++die () {+ echo+ echo "$*"+ echo+ exit 1+} >&2++# OS specific support (must be 'true' or 'false').+cygwin=false+msys=false+darwin=false+nonstop=false+case "$( uname )" in #(+ CYGWIN* ) cygwin=true ;; #(+ Darwin* ) darwin=true ;; #(+ MSYS* | MINGW* ) msys=true ;; #(+ NONSTOP* ) nonstop=true ;;+esac++++# Determine the Java command to use to start the JVM.+if [ -n "$JAVA_HOME" ] ; then+ if [ -x "$JAVA_HOME/jre/sh/java" ] ; then+ # IBM's JDK on AIX uses strange locations for the executables+ JAVACMD=$JAVA_HOME/jre/sh/java+ else+ JAVACMD=$JAVA_HOME/bin/java+ fi+ if [ ! -x "$JAVACMD" ] ; then+ die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME++Please set the JAVA_HOME variable in your environment to match the+location of your Java installation."+ fi+else+ JAVACMD=java+ if ! command -v java >/dev/null 2>&1+ then+ die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.++Please set the JAVA_HOME variable in your environment to match the+location of your Java installation."+ fi+fi++# Increase the maximum file descriptors if we can.+if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then+ case $MAX_FD in #(+ max*)+ # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.+ # shellcheck disable=SC2039,SC3045+ MAX_FD=$( ulimit -H -n ) ||+ warn "Could not query maximum file descriptor limit"+ esac+ case $MAX_FD in #(+ '' | soft) :;; #(+ *)+ # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.+ # shellcheck disable=SC2039,SC3045+ ulimit -n "$MAX_FD" ||+ warn "Could not set maximum file descriptor limit to $MAX_FD"+ esac+fi++# Collect all arguments for the java command, stacking in reverse order:+# * args from the command line+# * the main class name+# * -classpath+# * -D...appname settings+# * --module-path (only if needed)+# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables.++# For Cygwin or MSYS, switch paths to Windows format before running java+if "$cygwin" || "$msys" ; then+ APP_HOME=$( cygpath --path --mixed "$APP_HOME" )++ JAVACMD=$( cygpath --unix "$JAVACMD" )++ # Now convert the arguments - kludge to limit ourselves to /bin/sh+ for arg do+ if+ case $arg in #(+ -*) false ;; # don't mess with options #(+ /?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath+ [ -e "$t" ] ;; #(+ *) false ;;+ esac+ then+ arg=$( cygpath --path --ignore --mixed "$arg" )+ fi+ # Roll the args list around exactly as many times as the number of+ # args, so each arg winds up back in the position where it started, but+ # possibly modified.+ #+ # NB: a `for` loop captures its iteration list before it begins, so+ # changing the positional parameters here affects neither the number of+ # iterations, nor the values presented in `arg`.+ shift # remove old arg+ set -- "$@" "$arg" # push replacement arg+ done+fi+++# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.+DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'++# Collect all arguments for the java command:+# * DEFAULT_JVM_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,+# and any embedded shellness will be escaped.+# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be+# treated as '${Hostname}' itself on the command line.++set -- \+ "-Dorg.gradle.appname=$APP_BASE_NAME" \+ -jar "$APP_HOME/gradle/wrapper/gradle-wrapper.jar" \+ "$@"++# Stop when "xargs" is not available.+if ! command -v xargs >/dev/null 2>&1+then+ die "xargs is not available"+fi++# Use "xargs" to parse quoted args.+#+# With -n1 it outputs one arg per line, with the quotes and backslashes removed.+#+# In Bash we could simply go:+#+# readarray ARGS < <( xargs -n1 <<<"$var" ) &&+# set -- "${ARGS[@]}" "$@"+#+# but POSIX shell has neither arrays nor command substitution, so instead we+# post-process each arg (as a line of input to sed) to backslash-escape any+# character that might be a shell metacharacter, then use eval to reverse+# that process (while maintaining the separation between arguments), and wrap+# the whole thing up as a single "set" statement.+#+# This will of course break if any of these variables contains a newline or+# an unmatched quote.+#++eval "set -- $(+ printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" |+ xargs -n1 |+ sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' |+ tr '\n' ' '+ )" '"$@"'++exec "$JAVACMD" "$@"diff --git a/base/gradlew.bat b/base/gradlew.batnew file mode 100644index 00000000..8508ef68--- /dev/null+++ b/base/gradlew.bat@@ -0,0 +1,82 @@+@rem+@rem Copyright 2015 the original author or authors.+@rem+@rem Licensed under the Apache License, Version 2.0 (the "License");+@rem you may not use this file except in compliance with the License.+@rem You may obtain a copy of the License at+@rem+@rem https://www.apache.org/licenses/LICENSE-2.0+@rem+@rem Unless required by applicable law or agreed to in writing, software+@rem distributed under the License is distributed on an "AS IS" BASIS,+@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.+@rem See the License for the specific language governing permissions and+@rem limitations under the License.+@rem+@rem SPDX-License-Identifier: Apache-2.0+@rem++@if "%DEBUG%"=="" @echo off+@rem ##########################################################################+@rem+@rem gradlew startup script for Windows+@rem+@rem ##########################################################################++@rem Set local scope for the variables, and ensure extensions are enabled+setlocal EnableExtensions++set DIRNAME=%~dp0+if "%DIRNAME%"=="" set DIRNAME=.+@rem This is normally unused+set APP_BASE_NAME=%~n0+set APP_HOME=%DIRNAME%++@rem Resolve any "." and ".." in APP_HOME to make it shorter.+for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi++@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.+set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"++@rem Find java.exe+if defined JAVA_HOME goto findJavaFromJavaHome++set JAVA_EXE=java.exe+%JAVA_EXE% -version >NUL 2>&1+if %ERRORLEVEL% equ 0 goto execute++echo. 1>&2+echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2+echo. 1>&2+echo Please set the JAVA_HOME variable in your environment to match the 1>&2+echo location of your Java installation. 1>&2++"%COMSPEC%" /c exit 1++:findJavaFromJavaHome+set JAVA_HOME=%JAVA_HOME:"=%+set JAVA_EXE=%JAVA_HOME%/bin/java.exe++if exist "%JAVA_EXE%" goto execute++echo. 1>&2+echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2+echo. 1>&2+echo Please set the JAVA_HOME variable in your environment to match the 1>&2+echo location of your Java installation. 1>&2++"%COMSPEC%" /c exit 1++:execute+@rem Setup the command line++++@rem Execute gradlew+@rem endlocal doesn't take effect until after the line is parsed and variables are expanded+@rem which allows us to clear the local environment before executing the java command+endlocal & "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar" %* & call :exitWithErrorLevel++:exitWithErrorLevel+@rem Use "%COMSPEC%" /c exit to allow operators to work properly in scripts+"%COMSPEC%" /c exit %ERRORLEVEL%diff --git a/base/host-android/build.gradle.kts b/base/host-android/build.gradle.ktsnew file mode 100644index 00000000..20e8bd36--- /dev/null+++ b/base/host-android/build.gradle.kts@@ -0,0 +1,28 @@+// Android host: runs the Web Player in a WebView and exposes it as a MyspotiApi, plus the+// playback service (media session, notification, Android Auto browsing).+plugins {+ alias(libs.plugins.android.library)+}++android {+ namespace = "app.myspoti.host.android"+ compileSdk = 37++ defaultConfig {+ minSdk = 29+ }+ compileOptions {+ sourceCompatibility = JavaVersion.VERSION_17+ targetCompatibility = JavaVersion.VERSION_17+ }+}++dependencies {+ api(project(":api-spotify"))+ implementation(libs.androidx.core.ktx)+ implementation(libs.androidx.webkit)+ implementation(libs.androidx.media)+ implementation(libs.serialization.json)+ implementation(libs.okhttp)+ implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:1.10.2")+}diff --git a/base/host-android/src/main/AndroidManifest.xml b/base/host-android/src/main/AndroidManifest.xmlnew file mode 100644index 00000000..d34a70a8--- /dev/null+++ b/base/host-android/src/main/AndroidManifest.xml@@ -0,0 +1,17 @@+<?xml version="1.0" encoding="utf-8"?>+<manifest xmlns:android="http://schemas.android.com/apk/res/android">+ <uses-permission android:name="android.permission.INTERNET" />+ <uses-permission android:name="android.permission.FOREGROUND_SERVICE" />+ <uses-permission android:name="android.permission.FOREGROUND_SERVICE_MEDIA_PLAYBACK" />+ <uses-permission android:name="android.permission.POST_NOTIFICATIONS" />+ <application>+ <service+ android:name="app.myspoti.host.android.PlaybackService"+ android:exported="true"+ android:foregroundServiceType="mediaPlayback">+ <intent-filter>+ <action android:name="android.media.browse.MediaBrowserService" />+ </intent-filter>+ </service>+ </application>+</manifest>diff --git a/base/host-android/src/main/kotlin/app/myspoti/host/android/ControlRelay.kt b/base/host-android/src/main/kotlin/app/myspoti/host/android/ControlRelay.ktnew file mode 100644index 00000000..0e1863e1--- /dev/null+++ b/base/host-android/src/main/kotlin/app/myspoti/host/android/ControlRelay.kt@@ -0,0 +1,133 @@+package app.myspoti.host.android++import android.os.Handler+import android.os.Looper+import android.webkit.JavascriptInterface+import android.webkit.WebView+import okhttp3.Call+import okhttp3.Callback+import okhttp3.Headers+import okhttp3.OkHttpClient+import okhttp3.Request+import okhttp3.RequestBody.Companion.toRequestBody+import okhttp3.Response+import org.json.JSONObject+import java.io.IOException+import java.util.concurrent.TimeUnit++/**+ * Sends the Web Player's playback control requests (Spotify Connect commands, transfers,+ * device and track-playback state) from the app instead of the WebView.+ *+ * Every WebView request carries "X-Requested-With: <package>", and an app can no longer turn+ * that off (androidx.webkit's allow-list API is a no-op on current WebViews). Spotify+ * acknowledges Connect commands that carry it but never delivers them to the player, so+ * nothing plays. Tested on desktop Chrome: adding only that header to the command request+ * reproduces the silence, and removing it restores playback.+ *+ * The page's `fetch` is wrapped at document start. Matching requests go through+ * [MyspotiNet.send], which repeats them with OkHttp using the page's own headers (its token,+ * client token, connection id), then hands the response back to the page.+ */+internal class ControlRelay(private val view: WebView) {+ private val main = Handler(Looper.getMainLooper())+ private val http = OkHttpClient.Builder()+ .connectTimeout(15, TimeUnit.SECONDS)+ .readTimeout(30, TimeUnit.SECONDS)+ .build()++ fun install() {+ view.addJavascriptInterface(this, "MyspotiNet")+ val documentStart = androidx.webkit.WebViewFeature.isFeatureSupported(androidx.webkit.WebViewFeature.DOCUMENT_START_SCRIPT)+ if (documentStart) androidx.webkit.WebViewCompat.addDocumentStartJavaScript(view, SCRIPT, setOf("https://open.spotify.com"))+ android.util.Log.d(WebPlayerHost.LOG, "control relay installed (document start: $documentStart)")+ }++ /** Fallback for WebViews without document-start scripts; harmless when already installed. */+ fun injectNow() = view.evaluateJavascript(SCRIPT, null)++ @JavascriptInterface+ fun send(id: Int, url: String, method: String, headersJson: String, body: String?) {+ if (!isRelayed(url)) {+ reply(id, 0, "{}", "")+ return+ }+ val headers = Headers.Builder()+ val given = runCatching { JSONObject(headersJson) }.getOrDefault(JSONObject())+ given.keys().forEach { key ->+ // OkHttp sets the transport headers itself.+ if (key.lowercase() !in setOf("host", "content-length", "connection", "accept-encoding", "x-requested-with"))+ runCatching { headers.add(key, given.getString(key)) }+ }+ headers["User-Agent"] = WebPlayerHost.DESKTOP_UA+ headers["Origin"] = "https://open.spotify.com"+ headers["Referer"] = "https://open.spotify.com/"+ // Bytes, not a String body: OkHttp would append "; charset=utf-8" to the content type.+ val payload = if (method == "GET" || method == "HEAD") null else (body ?: "").toByteArray().toRequestBody(null)+ val request = Request.Builder().url(url).headers(headers.build()).method(method, payload).build()+ http.newCall(request).enqueue(object : Callback {+ override fun onFailure(call: Call, e: IOException) {+ android.util.Log.d(WebPlayerHost.LOG, "relay $method ${shortPath(url)} failed: ${e.message}")+ reply(id, 0, "{}", "")+ }++ override fun onResponse(call: Call, response: Response) {+ response.use {+ val out = JSONObject()+ it.headers.names().forEach { name -> out.put(name, it.header(name)) }+ val text = it.body.string()+ android.util.Log.d(WebPlayerHost.LOG, "relay $method ${shortPath(url)} -> ${it.code}")+ reply(id, it.code, out.toString(), text)+ }+ }+ })+ }++ private fun reply(id: Int, status: Int, headersJson: String, body: String) = main.post {+ view.evaluateJavascript(+ "window.__mspNetDone && window.__mspNetDone($id, $status, ${JSONObject.quote(headersJson)}, ${JSONObject.quote(body)})",+ null,+ )+ }++ private fun shortPath(url: String) = url.substringBefore('?').substringAfter(".com").replace(Regex("[0-9a-f]{20,}"), "…")++ companion object {+ private val RELAYED = Regex("^https://[a-z0-9-]+(\\.[a-z0-9-]+)*\\.spotify\\.com/(connect-state|track-playback)/v1/")++ fun isRelayed(url: String) = RELAYED.containsMatchIn(url)++ /** Wraps window.fetch; the same pattern as [RELAYED]. */+ private val SCRIPT = """+ (() => {+ if (window.__mspNetInstalled || !window.MyspotiNet) return;+ window.__mspNetInstalled = true;+ const relayed = /^https:\/\/[a-z0-9-]+(\.[a-z0-9-]+)*\.spotify\.com\/(connect-state|track-playback)\/v1\//;+ const pending = new Map();+ let seq = 0;+ window.__mspNetDone = (id, status, headers, body) => {+ const p = pending.get(id);+ if (!p) return;+ pending.delete(id);+ if (!status) return p.reject(new TypeError('Failed to fetch'));+ const noBody = status === 204 || status === 205 || status === 304;+ p.resolve(new Response(noBody ? null : body, { status, headers: JSON.parse(headers) }));+ };+ const original = window.fetch;+ window.fetch = function (input, init) {+ const url = typeof input === 'string' ? input : (input instanceof URL ? input.href : null);+ const body = init && init.body;+ if (!url || !relayed.test(url) || (body != null && typeof body !== 'string')) return original.apply(this, arguments);+ const headers = {};+ new Headers((init && init.headers) || {}).forEach((v, k) => { headers[k] = v; });+ const method = ((init && init.method) || 'GET').toUpperCase();+ return new Promise((resolve, reject) => {+ const id = ++seq;+ pending.set(id, { resolve, reject });+ window.MyspotiNet.send(id, url, method, JSON.stringify(headers), body == null ? null : body);+ });+ };+ })();+ """.trimIndent()+ }+}diff --git a/base/host-android/src/main/kotlin/app/myspoti/host/android/MyspotiRuntime.kt b/base/host-android/src/main/kotlin/app/myspoti/host/android/MyspotiRuntime.ktnew file mode 100644index 00000000..9f14f14d--- /dev/null+++ b/base/host-android/src/main/kotlin/app/myspoti/host/android/MyspotiRuntime.kt@@ -0,0 +1,62 @@+package app.myspoti.host.android++import android.content.Context+import app.myspoti.api.MyspotiApi+import app.myspoti.spotify.SpotifyApi+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.SupervisorJob+import kotlinx.coroutines.flow.StateFlow+import kotlinx.coroutines.launch+import java.util.Locale++/**+ * The app's single Spotify session: one WebView host and one [SpotifyApi] for the process.+ * Created on the main thread (WebView requirement), usually from Application.onCreate.+ */+object MyspotiRuntime {+ lateinit var host: WebPlayerHost+ private set+ lateinit var spotify: SpotifyApi+ private set+ val api: MyspotiApi get() = spotify+ val scope = CoroutineScope(SupervisorJob() + Dispatchers.Main.immediate)++ val isStarted: Boolean get() = ::host.isInitialized+ val loginRequired: StateFlow<Boolean> get() = host.loginRequired++ fun start(context: Context) {+ if (isStarted) return+ val updater = app.myspoti.spotify.gql.GqlOpsUpdater(okhttp3.OkHttpClient(), java.io.File(context.filesDir, "spotify/gql-ops.json"))+ host = WebPlayerHost(context)+ spotify = SpotifyApi(host, scope, language = Locale.getDefault().language, ops = updater.load())+ spotify.bridge.logger = { line -> android.util.Log.d(WebPlayerHost.LOG, line) }+ host.onPageLoaded = { scope.launch { spotify.onPageLoaded() } }+ // Every 10 s: is the bridge ready, what does the player say (diagnostics in Logcat).+ scope.launch {+ while (true) {+ kotlinx.coroutines.delay(10_000)+ val s = spotify.player.state.value+ android.util.Log.d(WebPlayerHost.LOG, "status ready=${spotify.ready.value} login=${host.loginRequired.value} " ++ "track=${s?.item?.name} paused=${s?.isPaused} buffering=${s?.isBuffering} url=${host.url.value.take(60)}")+ }+ }+ host.load()+ // New Spotify build: pick up its operation hashes (public bundles, no account).+ scope.launch {+ runCatching { updater.refresh(spotify.opsInUse) }.getOrNull()?.let(spotify::updateOps)+ }+ }++ /** True when the Web Player holds a signed-in user's token (not an anonymous one). */+ suspend fun isSignedIn(): Boolean {+ val token = spotify.bridge.call("token.get")+ return (token as? kotlinx.serialization.json.JsonObject)?.get("isAnonymous")?.let {+ (it as? kotlinx.serialization.json.JsonPrimitive)?.content == "false"+ } ?: false+ }++ /** Data saver: frees the page; [resume] loads it again. */+ fun suspendPlayer() = host.unload()+ fun resume() = host.load()+}diff --git a/base/host-android/src/main/kotlin/app/myspoti/host/android/PlaybackService.kt b/base/host-android/src/main/kotlin/app/myspoti/host/android/PlaybackService.ktnew file mode 100644index 00000000..7bcbd28f--- /dev/null+++ b/base/host-android/src/main/kotlin/app/myspoti/host/android/PlaybackService.kt@@ -0,0 +1,309 @@+package app.myspoti.host.android++import android.app.Notification+import android.app.NotificationChannel+import android.app.NotificationManager+import android.app.PendingIntent+import android.content.Context+import android.content.Intent+import android.content.pm.ServiceInfo+import android.graphics.Bitmap+import android.graphics.BitmapFactory+import android.os.Build+import android.os.Bundle+import android.support.v4.media.MediaBrowserCompat+import android.support.v4.media.MediaMetadataCompat+import android.support.v4.media.session.MediaSessionCompat+import android.support.v4.media.session.PlaybackStateCompat+import androidx.core.app.NotificationCompat+import androidx.core.app.NotificationManagerCompat+import androidx.core.app.ServiceCompat+import androidx.media.MediaBrowserServiceCompat+import androidx.media.VolumeProviderCompat+import androidx.media.app.NotificationCompat.MediaStyle+import androidx.media.session.MediaButtonReceiver+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.SupervisorJob+import kotlinx.coroutines.cancel+import kotlinx.coroutines.launch+import kotlinx.coroutines.withContext+import okhttp3.OkHttpClient+import okhttp3.Request++/** What the notification, lock screen, Bluetooth and Android Auto show. */+data class NowPlayingInfo(+ val id: String,+ val title: String,+ val artist: String,+ val album: String,+ val coverUrl: String?,+ val durationMs: Long,+ val positionMs: Long,+ val playing: Boolean,+ val buffering: Boolean = false,+ val liked: Boolean = false,+)++/** Commands from the system (notification buttons, headset, car, lock screen). */+interface PlaybackControls {+ fun play()+ fun pause()+ fun next()+ fun previous()+ fun seekTo(ms: Long)+ fun setLiked(liked: Boolean)+ fun playFromMediaId(mediaId: String)+ fun playFromSearch(query: String)+ fun setRemoteVolume(volume: Int)+}++/** Android Auto / media browser content. */+interface MediaLibrary {+ suspend fun children(context: Context, parentId: String): List<MediaBrowserCompat.MediaItem>+ suspend fun search(query: String): List<MediaBrowserCompat.MediaItem>+}++/**+ * Media session + notification + browser service. The app pushes the state with [update]+ * and receives commands through [controls]; the service never talks to Spotify itself.+ */+class PlaybackService : MediaBrowserServiceCompat() {+ private lateinit var session: MediaSessionCompat+ private val scope = CoroutineScope(SupervisorJob() + Dispatchers.Main)+ private var foreground = false+ private var lastCoverUrl: String? = null+ private var cover: Bitmap? = null++ override fun onCreate() {+ super.onCreate()+ instance = this+ session = MediaSessionCompat(this, "Myspoti").apply {+ setCallback(callback)+ setSessionActivity(launchIntent())+ isActive = true+ }+ sessionToken = session.sessionToken+ createChannel()+ current?.let { apply(it) }+ }++ override fun onStartCommand(intent: Intent?, flags: Int, startId: Int): Int {+ MediaButtonReceiver.handleIntent(session, intent)+ // Started for playback: Android needs the foreground notification right away.+ current?.let { show(it) } ?: startForegroundSafely(build(null))+ return START_NOT_STICKY+ }++ override fun onDestroy() {+ instance = null+ session.release()+ scope.cancel()+ super.onDestroy()+ }++ override fun onTaskRemoved(rootIntent: Intent?) {+ if (current?.playing != true) stopSelf()+ }++ private val callback = object : MediaSessionCompat.Callback() {+ override fun onPlay() { controls?.play() }+ override fun onPause() { controls?.pause() }+ override fun onSkipToNext() { controls?.next() }+ override fun onSkipToPrevious() { controls?.previous() }+ override fun onSeekTo(pos: Long) { controls?.seekTo(pos) }+ override fun onStop() { controls?.pause() }+ override fun onPlayFromMediaId(mediaId: String, extras: Bundle?) { controls?.playFromMediaId(mediaId) }+ override fun onPlayFromSearch(query: String, extras: Bundle?) { controls?.playFromSearch(query) }+ override fun onCustomAction(action: String, extras: Bundle?) {+ if (action == ACTION_LIKE) controls?.setLiked(!(current?.liked ?: false))+ }+ }++ private fun apply(info: NowPlayingInfo) {+ session.setMetadata(MediaMetadataCompat.Builder()+ .putString(MediaMetadataCompat.METADATA_KEY_MEDIA_ID, info.id)+ .putString(MediaMetadataCompat.METADATA_KEY_TITLE, info.title)+ .putString(MediaMetadataCompat.METADATA_KEY_ARTIST, info.artist)+ .putString(MediaMetadataCompat.METADATA_KEY_ALBUM, info.album)+ .putString(MediaMetadataCompat.METADATA_KEY_ALBUM_ART_URI, info.coverUrl)+ .putLong(MediaMetadataCompat.METADATA_KEY_DURATION, info.durationMs)+ .putBitmap(MediaMetadataCompat.METADATA_KEY_ALBUM_ART, cover.takeIf { info.coverUrl == lastCoverUrl })+ .build())+ val state = when {+ info.buffering && info.playing -> PlaybackStateCompat.STATE_BUFFERING+ info.playing -> PlaybackStateCompat.STATE_PLAYING+ else -> PlaybackStateCompat.STATE_PAUSED+ }+ session.setPlaybackState(PlaybackStateCompat.Builder()+ .setActions(+ PlaybackStateCompat.ACTION_PLAY or PlaybackStateCompat.ACTION_PAUSE or PlaybackStateCompat.ACTION_PLAY_PAUSE or+ PlaybackStateCompat.ACTION_SKIP_TO_NEXT or PlaybackStateCompat.ACTION_SKIP_TO_PREVIOUS or+ PlaybackStateCompat.ACTION_SEEK_TO or PlaybackStateCompat.ACTION_PLAY_FROM_MEDIA_ID or+ PlaybackStateCompat.ACTION_PLAY_FROM_SEARCH+ )+ .addCustomAction(ACTION_LIKE, if (info.liked) "Unlike" else "Like",+ if (info.liked) R.drawable.msp_ic_liked else R.drawable.msp_ic_like)+ .setState(state, info.positionMs, if (info.playing && !info.buffering) 1f else 0f)+ .build())+ if (info.coverUrl != lastCoverUrl) loadCover(info.coverUrl)+ }++ private fun loadCover(url: String?) {+ lastCoverUrl = url+ cover = null+ if (url.isNullOrBlank()) return+ scope.launch {+ val bitmap = withContext(Dispatchers.IO) {+ runCatching {+ http.newCall(Request.Builder().url(url).build()).execute().use { BitmapFactory.decodeStream(it.body.byteStream()) }+ }.getOrNull()+ }+ if (url == lastCoverUrl && bitmap != null) {+ cover = bitmap+ current?.let { apply(it); show(it) }+ }+ }+ }++ private val handler = android.os.Handler(android.os.Looper.getMainLooper())+ /** Leaves the foreground only after a real pause, never between two songs. */+ private val leaveForeground = Runnable {+ if (current?.playing != true && foreground) {+ ServiceCompat.stopForeground(this, ServiceCompat.STOP_FOREGROUND_DETACH)+ foreground = false+ }+ }++ private fun show(info: NowPlayingInfo) {+ val notification = build(info)+ if (info.playing || info.buffering) {+ handler.removeCallbacks(leaveForeground)+ startForegroundSafely(notification)+ } else {+ // The player is briefly "paused" while it loads the next song. Leaving the+ // foreground then let Android freeze the app with the screen off, and playback+ // stopped after one song: the service stays a minute in the foreground.+ if (foreground) {+ runCatching { NotificationManagerCompat.from(this).notify(NOTIFICATION_ID, notification) }+ handler.removeCallbacks(leaveForeground)+ handler.postDelayed(leaveForeground, PAUSE_GRACE_MS)+ } else runCatching { NotificationManagerCompat.from(this).notify(NOTIFICATION_ID, notification) }+ }+ }++ private fun startForegroundSafely(notification: Notification) {+ if (foreground) {+ runCatching { NotificationManagerCompat.from(this).notify(NOTIFICATION_ID, notification) }+ return+ }+ runCatching {+ ServiceCompat.startForeground(this, NOTIFICATION_ID, notification,+ if (Build.VERSION.SDK_INT >= 29) ServiceInfo.FOREGROUND_SERVICE_TYPE_MEDIA_PLAYBACK else 0)+ foreground = true+ }+ }++ private fun build(info: NowPlayingInfo?): Notification {+ val playing = info?.playing == true+ return NotificationCompat.Builder(this, CHANNEL_ID)+ .setSmallIcon(R.drawable.msp_ic_notification)+ .setContentTitle(info?.title ?: "")+ .setContentText(info?.artist ?: "")+ .setSubText(info?.album)+ .setLargeIcon(cover)+ .setContentIntent(launchIntent())+ .setDeleteIntent(MediaButtonReceiver.buildMediaButtonPendingIntent(this, PlaybackStateCompat.ACTION_STOP))+ .setVisibility(NotificationCompat.VISIBILITY_PUBLIC)+ .setOnlyAlertOnce(true)+ .setOngoing(playing)+ .addAction(R.drawable.msp_ic_previous, "Previous",+ MediaButtonReceiver.buildMediaButtonPendingIntent(this, PlaybackStateCompat.ACTION_SKIP_TO_PREVIOUS))+ .addAction(if (playing) R.drawable.msp_ic_pause else R.drawable.msp_ic_play, if (playing) "Pause" else "Play",+ MediaButtonReceiver.buildMediaButtonPendingIntent(this, PlaybackStateCompat.ACTION_PLAY_PAUSE))+ .addAction(R.drawable.msp_ic_next, "Next",+ MediaButtonReceiver.buildMediaButtonPendingIntent(this, PlaybackStateCompat.ACTION_SKIP_TO_NEXT))+ .setStyle(MediaStyle().setMediaSession(session.sessionToken).setShowActionsInCompactView(0, 1, 2))+ .build()+ }++ private fun launchIntent(): PendingIntent? {+ val intent = packageManager.getLaunchIntentForPackage(packageName) ?: return null+ return PendingIntent.getActivity(this, 0, intent, PendingIntent.FLAG_IMMUTABLE or PendingIntent.FLAG_UPDATE_CURRENT)+ }++ private fun createChannel() {+ val manager = getSystemService(NotificationManager::class.java)+ if (manager.getNotificationChannel(CHANNEL_ID) == null) {+ manager.createNotificationChannel(NotificationChannel(CHANNEL_ID, "Playback", NotificationManager.IMPORTANCE_LOW).apply {+ setShowBadge(false)+ })+ }+ }++ /** Playback on a Connect device: the volume keys drive that device instead of the phone. */+ private fun setRemote(remote: Boolean, volume: Int) {+ if (!remote) {+ session.setPlaybackToLocal(android.media.AudioManager.STREAM_MUSIC)+ return+ }+ session.setPlaybackToRemote(object : VolumeProviderCompat(VOLUME_CONTROL_ABSOLUTE, 100, volume) {+ override fun onSetVolumeTo(volume: Int) { currentVolume = volume; controls?.setRemoteVolume(volume) }+ override fun onAdjustVolume(direction: Int) {+ val v = (currentVolume + direction * 5).coerceIn(0, 100)+ currentVolume = v+ controls?.setRemoteVolume(v)+ }+ })+ }++ // Media browser (Android Auto).+ override fun onGetRoot(clientPackageName: String, clientUid: Int, rootHints: Bundle?) =+ BrowserRoot(ROOT_ID, Bundle().apply { putBoolean("android.media.browse.SEARCH_SUPPORTED", true) })++ override fun onLoadChildren(parentId: String, result: Result<MutableList<MediaBrowserCompat.MediaItem>>) {+ val lib = library ?: return result.sendResult(mutableListOf())+ result.detach()+ scope.launch { result.sendResult(runCatching { lib.children(this@PlaybackService, parentId).toMutableList() }.getOrElse { mutableListOf() }) }+ }++ override fun onSearch(query: String, extras: Bundle?, result: Result<MutableList<MediaBrowserCompat.MediaItem>>) {+ val lib = library ?: return result.sendResult(mutableListOf())+ result.detach()+ scope.launch { result.sendResult(runCatching { lib.search(query).toMutableList() }.getOrElse { mutableListOf() }) }+ }++ companion object {+ const val ROOT_ID = "root"+ private const val CHANNEL_ID = "playback"+ private const val NOTIFICATION_ID = 1+ private const val ACTION_LIKE = "like"+ private val http = OkHttpClient()++ @Volatile private var instance: PlaybackService? = null+ @Volatile private var current: NowPlayingInfo? = null++ private const val PAUSE_GRACE_MS = 60_000L++ /** Set once by the app. */+ @Volatile var controls: PlaybackControls? = null+ @Volatile var library: MediaLibrary? = null++ /** Pushes the now-playing state; starts the service when playback starts. */+ fun update(context: Context, info: NowPlayingInfo) {+ current = info+ val svc = instance+ if (svc == null) {+ if (info.playing) runCatching {+ androidx.core.content.ContextCompat.startForegroundService(context, Intent(context, PlaybackService::class.java))+ }+ return+ }+ svc.apply(info)+ svc.show(info)+ }++ /** [remote] when a Connect device plays; [volume] 0..100. */+ fun setPlaybackDevice(remote: Boolean, volume: Int) { instance?.setRemote(remote, volume) }+ }+}diff --git a/base/host-android/src/main/kotlin/app/myspoti/host/android/WebPlayerHost.kt b/base/host-android/src/main/kotlin/app/myspoti/host/android/WebPlayerHost.ktnew file mode 100644index 00000000..5c450597--- /dev/null+++ b/base/host-android/src/main/kotlin/app/myspoti/host/android/WebPlayerHost.kt@@ -0,0 +1,218 @@+package app.myspoti.host.android++import android.annotation.SuppressLint+import android.content.Context+import android.graphics.Bitmap+import android.os.Handler+import android.os.Looper+import android.view.View+import android.view.ViewGroup+import android.webkit.CookieManager+import android.webkit.JavascriptInterface+import android.webkit.PermissionRequest+import android.webkit.WebChromeClient+import android.webkit.WebResourceRequest+import android.webkit.WebResourceResponse+import android.webkit.WebSettings+import android.webkit.WebView+import android.webkit.WebViewClient+import app.myspoti.spotify.bridge.AdBlock+import app.myspoti.spotify.bridge.BridgeHost+import kotlinx.coroutines.CompletableDeferred+import kotlinx.coroutines.flow.MutableSharedFlow+import kotlinx.coroutines.flow.MutableStateFlow+import kotlinx.coroutines.flow.SharedFlow+import kotlinx.coroutines.flow.StateFlow+import java.io.ByteArrayInputStream++/**+ * [BridgeHost] on an Android WebView that loads the official Web Player.+ *+ * - The WebView is built on the application context, so playback outlives activities.+ * - Desktop user agent: on a phone UA the Web Player only offers to open the app.+ * - Protected media (Widevine) is allowed; ad audio requests ([AdBlock]) are refused.+ * - [loginRequired] turns true on Spotify's login pages: the UI then shows [view] so the+ * user signs in on Spotify's own page.+ */+class WebPlayerHost(context: Context) : BridgeHost {+ private val main = Handler(Looper.getMainLooper())++ private val _messages = MutableSharedFlow<String>(extraBufferCapacity = 256)+ override val messages: SharedFlow<String> = _messages++ private val _url = MutableStateFlow("")+ /** The page's current URL. */+ val url: StateFlow<String> = _url++ private val _loginRequired = MutableStateFlow(false)+ val loginRequired: StateFlow<Boolean> = _loginRequired++ /** Fires after each Web Player page load; the API injects the bridge then. */+ var onPageLoaded: (() -> Unit)? = null++ init {+ // Debug builds only: lets desktop tools (chrome://inspect, CDP) look at the page.+ val debuggable = context.applicationInfo.flags and android.content.pm.ApplicationInfo.FLAG_DEBUGGABLE != 0+ if (debuggable) WebView.setWebContentsDebuggingEnabled(true)+ }++ private lateinit var relay: ControlRelay++ @SuppressLint("SetJavaScriptEnabled")+ val view: WebView = WebView(context.applicationContext).apply {+ settings.apply {+ javaScriptEnabled = true+ domStorageEnabled = true+ mediaPlaybackRequiresUserGesture = false+ userAgentString = DESKTOP_UA+ cacheMode = WebSettings.LOAD_DEFAULT+ loadWithOverviewMode = true+ useWideViewPort = true+ }+ // Client hints must agree with the desktop user agent: by default the WebView announces+ // "Android WebView" / mobile in Sec-CH-UA headers and navigator.userAgentData.+ if (androidx.webkit.WebViewFeature.isFeatureSupported(androidx.webkit.WebViewFeature.USER_AGENT_METADATA)) {+ val brands = listOf(+ androidx.webkit.UserAgentMetadata.BrandVersion.Builder().setBrand("Chromium").setMajorVersion("155").setFullVersion("155.0.0.0").build(),+ androidx.webkit.UserAgentMetadata.BrandVersion.Builder().setBrand("Google Chrome").setMajorVersion("155").setFullVersion("155.0.0.0").build(),+ androidx.webkit.UserAgentMetadata.BrandVersion.Builder().setBrand("Not?A_Brand").setMajorVersion("24").setFullVersion("24.0.0.0").build(),+ )+ androidx.webkit.WebSettingsCompat.setUserAgentMetadata(settings, androidx.webkit.UserAgentMetadata.Builder()+ .setBrandVersionList(brands)+ .setFullVersion("155.0.0.0")+ .setPlatform("Linux")+ .setPlatformVersion("6.8.0")+ .setArchitecture("x86")+ .setBitness(64)+ .setMobile(false)+ .setModel("")+ .setWow64(false)+ .build())+ }+ // The page plays the audio: its renderer keeps its priority when the screen is off.+ setRendererPriorityPolicy(WebView.RENDERER_PRIORITY_IMPORTANT, false)+ // Playback control requests leave from the app, without the WebView's X-Requested-With.+ relay = ControlRelay(this).also { it.install() }+ val webView = this+ CookieManager.getInstance().apply {+ setAcceptCookie(true)+ setAcceptThirdPartyCookies(webView, true)+ }+ addJavascriptInterface(HostInterface(), "MyspotiHost")+ webChromeClient = object : WebChromeClient() {+ override fun onConsoleMessage(message: android.webkit.ConsoleMessage): Boolean {+ if (message.messageLevel() == android.webkit.ConsoleMessage.MessageLevel.ERROR ||+ message.messageLevel() == android.webkit.ConsoleMessage.MessageLevel.WARNING)+ android.util.Log.d(LOG, "console ${message.messageLevel()}: ${message.message().take(300)}")+ return true+ }++ override fun onPermissionRequest(request: PermissionRequest) {+ android.util.Log.d(LOG, "permission request: ${request.resources.joinToString()}")+ val allowed = request.resources.filter { it == PermissionRequest.RESOURCE_PROTECTED_MEDIA_ID }+ if (allowed.isNotEmpty()) request.grant(allowed.toTypedArray()) else request.deny()+ }+ }+ webViewClient = object : WebViewClient() {+ override fun shouldInterceptRequest(view: WebView, request: WebResourceRequest): WebResourceResponse? {+ if (!AdBlock.isBlocked(request.url.toString())) return null+ android.util.Log.d(LOG, "blocked ad request ${request.url.toString().take(120)}")+ // Refused like a blocked request: the player reports a failed ad and moves on.+ return WebResourceResponse("text/plain", "utf-8", 403, "Blocked", emptyMap(), ByteArrayInputStream(ByteArray(0)))+ }++ override fun onPageStarted(view: WebView, url: String, favicon: Bitmap?) {+ android.util.Log.d(LOG, "page start ${url.take(120)}")+ _url.value = url+ _loginRequired.value = isLoginPage(url)+ if (url.startsWith(PLAYER_URL)) relay.injectNow()+ }++ override fun onReceivedError(view: WebView, request: WebResourceRequest, error: android.webkit.WebResourceError) {+ if (request.url.host?.contains("spotify") == true)+ android.util.Log.d(LOG, "load error ${error.errorCode} ${error.description} ${request.url.toString().take(120)}")+ }++ override fun onReceivedHttpError(view: WebView, request: WebResourceRequest, response: WebResourceResponse) {+ if (request.url.host?.contains("spotify") == true)+ android.util.Log.d(LOG, "http ${response.statusCode} ${request.method} ${request.url.toString().substringBefore('?').take(120)}")+ }++ override fun onPageFinished(view: WebView, url: String) {+ android.util.Log.d(LOG, "page finished ${url.take(120)}")+ _url.value = url+ _loginRequired.value = isLoginPage(url)+ if (url.startsWith(PLAYER_URL)) onPageLoaded?.invoke()+ }++ override fun shouldOverrideUrlLoading(view: WebView, request: WebResourceRequest): Boolean {+ val host = request.url.host.orEmpty()+ // Stay on Spotify's own pages (player, login, consent); open nothing else.+ return !(host.endsWith("spotify.com") || host.endsWith("spotify.net") || host.endsWith("scdn.co") ||+ host.endsWith("google.com") || host.endsWith("facebook.com") || host.endsWith("apple.com"))+ }+ }+ }++ private fun isLoginPage(url: String?) =+ url != null && (url.contains("accounts.spotify.com") || url.contains("/login") || url.contains("challenge.spotify.com"))++ private inner class HostInterface {+ @JavascriptInterface+ fun post(json: String) { _messages.tryEmit(json) }+ }++ fun load() = main.post { view.loadUrl(PLAYER_URL) }++ fun reload() = main.post { view.reload() }++ fun openLogin() = main.post { view.loadUrl(LOGIN_URL) }++ /** Signs out of Spotify in this WebView, then shows the login page. */+ fun logout() = main.post {+ CookieManager.getInstance().removeAllCookies { main.post { view.clearCache(false); view.loadUrl(LOGIN_URL) } }+ }++ override suspend fun evaluate(script: String) {+ val done = CompletableDeferred<Unit>()+ main.post {+ runCatching { view.evaluateJavascript(script, null) }+ done.complete(Unit)+ }+ done.await()+ }++ /**+ * Keeps the page attached to a window so Chromium runs it at full speed: a tiny,+ * non-interactive view in [container] while the player is hidden.+ */+ fun attach(container: ViewGroup, visible: Boolean) = main.post {+ // Re-added each time: addView converts the params to the container's own type+ // (assigning plain ViewGroup.LayoutParams to a FrameLayout child crashes on measure).+ (view.parent as? ViewGroup)?.removeView(view)+ val size = if (visible) ViewGroup.LayoutParams.MATCH_PARENT else 1+ container.addView(view, ViewGroup.LayoutParams(size, size))+ view.alpha = if (visible) 1f else 0.01f+ view.importantForAccessibility = if (visible) View.IMPORTANT_FOR_ACCESSIBILITY_AUTO else View.IMPORTANT_FOR_ACCESSIBILITY_NO_HIDE_DESCENDANTS+ // Typing in the login form needs touch focus, or the keyboard never opens.+ view.isFocusable = visible+ view.isFocusableInTouchMode = visible+ view.descendantFocusability = if (visible) ViewGroup.FOCUS_AFTER_DESCENDANTS else ViewGroup.FOCUS_BLOCK_DESCENDANTS+ if (visible) view.requestFocus()+ view.requestLayout()+ }++ fun detach() = main.post { (view.parent as? ViewGroup)?.removeView(view) }++ /** Frees the page (data saver, low memory). [load] brings it back. */+ fun unload() = main.post { view.loadUrl("about:blank") }++ companion object {+ /** Logcat tag of the engine: `adb logcat -s Myspoti`. */+ const val LOG = "Myspoti"+ const val PLAYER_URL = "https://open.spotify.com/"+ const val LOGIN_URL = "https://accounts.spotify.com/login?continue=https%3A%2F%2Fopen.spotify.com%2F"+ const val DESKTOP_UA =+ "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/155.0.0.0 Safari/537.36"+ }+}diff --git a/base/host-android/src/main/res/drawable/msp_ic_like.xml b/base/host-android/src/main/res/drawable/msp_ic_like.xmlnew file mode 100644index 00000000..87a2d240--- /dev/null+++ b/base/host-android/src/main/res/drawable/msp_ic_like.xml@@ -0,0 +1,4 @@+<?xml version="1.0" encoding="utf-8"?>+<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M16.5,3c-1.74,0 -3.41,0.81 -4.5,2.09C10.91,3.81 9.24,3 7.5,3 4.42,3 2,5.42 2,8.5c0,3.78 3.4,6.86 8.55,11.54L12,21.35l1.45,-1.32C18.6,15.36 22,12.28 22,8.5 22,5.42 19.58,3 16.5,3zM12.1,18.55l-0.1,0.1 -0.1,-0.1C7.14,14.24 4,11.39 4,8.5 4,6.5 5.5,5 7.5,5c1.54,0 3.04,0.99 3.57,2.36h1.87C13.46,5.99 14.96,5 16.5,5c2,0 3.5,1.5 3.5,3.5 0,2.89 -3.14,5.74 -7.9,10.05z" />+</vector>diff --git a/base/host-android/src/main/res/drawable/msp_ic_liked.xml b/base/host-android/src/main/res/drawable/msp_ic_liked.xmlnew file mode 100644index 00000000..165a8921--- /dev/null+++ b/base/host-android/src/main/res/drawable/msp_ic_liked.xml@@ -0,0 +1,4 @@+<?xml version="1.0" encoding="utf-8"?>+<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M12,21.35l-1.45,-1.32C5.4,15.36 2,12.28 2,8.5 2,5.42 4.42,3 7.5,3c1.74,0 3.41,0.81 4.5,2.09C13.09,3.81 14.76,3 16.5,3 19.58,3 22,5.42 22,8.5c0,3.78 -3.4,6.86 -8.55,11.54L12,21.35z" />+</vector>diff --git a/base/host-android/src/main/res/drawable/msp_ic_next.xml b/base/host-android/src/main/res/drawable/msp_ic_next.xmlnew file mode 100644index 00000000..031414ca--- /dev/null+++ b/base/host-android/src/main/res/drawable/msp_ic_next.xml@@ -0,0 +1,4 @@+<?xml version="1.0" encoding="utf-8"?>+<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M6,18l8.5,-6L6,6v12zM16,6v12h2V6h-2z" />+</vector>diff --git a/base/host-android/src/main/res/drawable/msp_ic_notification.xml b/base/host-android/src/main/res/drawable/msp_ic_notification.xmlnew file mode 100644index 00000000..057d8738--- /dev/null+++ b/base/host-android/src/main/res/drawable/msp_ic_notification.xml@@ -0,0 +1,4 @@+<?xml version="1.0" encoding="utf-8"?>+<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M12,3v10.55c-0.59,-0.34 -1.27,-0.55 -2,-0.55 -2.21,0 -4,1.79 -4,4s1.79,4 4,4 4,-1.79 4,-4V7h4V3h-6z" />+</vector>diff --git a/base/host-android/src/main/res/drawable/msp_ic_pause.xml b/base/host-android/src/main/res/drawable/msp_ic_pause.xmlnew file mode 100644index 00000000..c413c6b7--- /dev/null+++ b/base/host-android/src/main/res/drawable/msp_ic_pause.xml@@ -0,0 +1,4 @@+<?xml version="1.0" encoding="utf-8"?>+<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M6,19h4V5H6v14zM14,5v14h4V5h-4z" />+</vector>diff --git a/base/host-android/src/main/res/drawable/msp_ic_play.xml b/base/host-android/src/main/res/drawable/msp_ic_play.xmlnew file mode 100644index 00000000..feccdcf1--- /dev/null+++ b/base/host-android/src/main/res/drawable/msp_ic_play.xml@@ -0,0 +1,4 @@+<?xml version="1.0" encoding="utf-8"?>+<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M8,5v14l11,-7z" />+</vector>diff --git a/base/host-android/src/main/res/drawable/msp_ic_previous.xml b/base/host-android/src/main/res/drawable/msp_ic_previous.xmlnew file mode 100644index 00000000..5b46973a--- /dev/null+++ b/base/host-android/src/main/res/drawable/msp_ic_previous.xml@@ -0,0 +1,4 @@+<?xml version="1.0" encoding="utf-8"?>+<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:viewportWidth="24" android:viewportHeight="24">+ <path android:fillColor="#FFFFFFFF" android:pathData="M6,6h2v12H6zM9.5,12l8.5,6V6z" />+</vector>diff --git a/base/host-cdp/build.gradle.kts b/base/host-cdp/build.gradle.ktsnew file mode 100644index 00000000..ce7b4e1e--- /dev/null+++ b/base/host-cdp/build.gradle.kts@@ -0,0 +1,27 @@+// Desktop host: drives the Web Player in a local Google Chrome over the DevTools protocol.+// Used by the integration tests, so the whole API runs on a PC without an emulator.+plugins {+ alias(libs.plugins.kotlin.jvm)+}++kotlin {+ jvmToolchain(17)+}++dependencies {+ api(project(":api-spotify"))+ implementation(libs.okhttp)+ implementation(libs.serialization.json)++ testImplementation(platform(libs.junit.bom))+ testImplementation(libs.junit.jupiter)+ testRuntimeOnly(libs.junit.launcher)+}++tasks.test {+ useJUnitPlatform()+ // Live tests need Chrome with --remote-debugging-port and a signed-in Web Player.+ systemProperty("myspoti.cdp", providers.gradleProperty("cdp").getOrElse(""))+ testLogging { events("passed", "failed", "skipped"); showStandardStreams = true }+ outputs.upToDateWhen { false }+}diff --git a/base/host-cdp/src/main/kotlin/app/myspoti/host/cdp/CdpHost.kt b/base/host-cdp/src/main/kotlin/app/myspoti/host/cdp/CdpHost.ktnew file mode 100644index 00000000..a2b36e2e--- /dev/null+++ b/base/host-cdp/src/main/kotlin/app/myspoti/host/cdp/CdpHost.kt@@ -0,0 +1,145 @@+package app.myspoti.host.cdp++import app.myspoti.spotify.bridge.AdBlock+import app.myspoti.spotify.bridge.BridgeHost+import kotlinx.coroutines.CompletableDeferred+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.flow.MutableSharedFlow+import kotlinx.coroutines.flow.SharedFlow+import kotlinx.coroutines.flow.first+import kotlinx.coroutines.withContext+import kotlinx.coroutines.withTimeout+import kotlinx.serialization.json.Json+import kotlinx.serialization.json.JsonObject+import kotlinx.serialization.json.buildJsonArray+import kotlinx.serialization.json.buildJsonObject+import kotlinx.serialization.json.int+import kotlinx.serialization.json.jsonArray+import kotlinx.serialization.json.jsonObject+import kotlinx.serialization.json.jsonPrimitive+import kotlinx.serialization.json.put+import kotlinx.serialization.json.putJsonObject+import okhttp3.OkHttpClient+import okhttp3.Request+import okhttp3.Response+import okhttp3.WebSocket+import okhttp3.WebSocketListener+import java.util.concurrent.ConcurrentHashMap+import java.util.concurrent.TimeUnit+import java.util.concurrent.atomic.AtomicInteger++/**+ * [BridgeHost] on a desktop Chrome started with `--remote-debugging-port`.+ *+ * Attaches to the open.spotify.com tab (or opens one), relays bridge messages through a CDP+ * binding, and fails ad audio requests ([AdBlock]) with `BlockedByClient`, like the+ * Android host does in `shouldInterceptRequest`.+ */+class CdpHost private constructor(private val socket: WebSocket, private val listener: Listener) : BridgeHost {++ override val messages: SharedFlow<String> = listener.messages++ /** Suspends until the next page load; the API re-injects the bridge then. */+ suspend fun awaitLoad() { listener.pageLoads.first() }++ override suspend fun evaluate(script: String) {+ send("Runtime.evaluate", buildJsonObject { put("expression", script); put("awaitPromise", false) })+ }++ suspend fun navigate(url: String) {+ send("Page.navigate", buildJsonObject { put("url", url) })+ }++ suspend fun reload() {+ send("Page.reload", buildJsonObject {})+ }++ fun close() = socket.close(1000, null)++ private suspend fun send(method: String, params: JsonObject): JsonObject = listener.send(socket, method, params)++ internal class Listener : WebSocketListener() {+ val messages = MutableSharedFlow<String>(extraBufferCapacity = 256)+ private val ids = AtomicInteger(0)+ private val pending = ConcurrentHashMap<Int, CompletableDeferred<JsonObject>>()+ val opened = CompletableDeferred<Unit>()+ private val loads = MutableSharedFlow<Unit>(extraBufferCapacity = 4)+ val pageLoads: SharedFlow<Unit> = loads++ suspend fun send(ws: WebSocket, method: String, params: JsonObject): JsonObject {+ val id = ids.incrementAndGet()+ val waiter = CompletableDeferred<JsonObject>()+ pending[id] = waiter+ ws.send(buildJsonObject { put("id", id); put("method", method); put("params", params) }.toString())+ return try { withTimeout(30_000) { waiter.await() } } finally { pending.remove(id) }+ }++ override fun onOpen(webSocket: WebSocket, response: Response) { opened.complete(Unit) }++ override fun onMessage(webSocket: WebSocket, text: String) {+ val msg = json.parseToJsonElement(text).jsonObject+ msg["id"]?.let { id ->+ val waiter = pending.remove(id.jsonPrimitive.int) ?: return+ msg["error"]?.let { waiter.completeExceptionally(IllegalStateException(it.toString())) }+ ?: waiter.complete(msg["result"]?.jsonObject ?: JsonObject(emptyMap()))+ return+ }+ val params = msg["params"]?.jsonObject ?: return+ when (msg["method"]?.jsonPrimitive?.content) {+ "Runtime.bindingCalled" ->+ if (params["name"]?.jsonPrimitive?.content == BINDING) messages.tryEmit(params["payload"]!!.jsonPrimitive.content)+ "Fetch.requestPaused" -> {+ val requestId = params["requestId"]!!.jsonPrimitive.content+ val url = params["request"]!!.jsonObject["url"]!!.jsonPrimitive.content+ val reply = if (AdBlock.isBlocked(url)) {+ buildJsonObject { put("id", ids.incrementAndGet()); put("method", "Fetch.failRequest"); putJsonObject("params") { put("requestId", requestId); put("errorReason", "BlockedByClient") } }+ } else {+ buildJsonObject { put("id", ids.incrementAndGet()); put("method", "Fetch.continueRequest"); putJsonObject("params") { put("requestId", requestId) } }+ }+ webSocket.send(reply.toString())+ }+ "Page.loadEventFired" -> loads.tryEmit(Unit)+ }+ }++ override fun onFailure(webSocket: WebSocket, t: Throwable, response: Response?) {+ opened.completeExceptionally(t)+ pending.values.forEach { it.completeExceptionally(t) }+ }+ }++ companion object {+ const val BINDING = "__mspHostPost"+ private val json = Json { ignoreUnknownKeys = true }++ /** Attaches to the Web Player tab of the Chrome listening on [cdpUrl]. */+ suspend fun connect(cdpUrl: String = "http://localhost:9222", http: OkHttpClient = defaultHttp): CdpHost {+ val targets = withContext(Dispatchers.IO) {+ http.newCall(Request.Builder().url("$cdpUrl/json/list").build()).execute().use { it.body.string() }+ }+ val page = json.parseToJsonElement(targets).jsonArray.map { it.jsonObject }.firstOrNull {+ it["type"]?.jsonPrimitive?.content == "page" && it["url"]!!.jsonPrimitive.content.startsWith("https://open.spotify.com")+ } ?: withContext(Dispatchers.IO) {+ val created = http.newCall(Request.Builder().url("$cdpUrl/json/new?https://open.spotify.com/").put(okhttp3.RequestBody.EMPTY).build())+ .execute().use { it.body.string() }+ json.parseToJsonElement(created).jsonObject+ }+ val wsUrl = page["webSocketDebuggerUrl"]!!.jsonPrimitive.content+ val listener = Listener()+ val socket = http.newWebSocket(Request.Builder().url(wsUrl).build(), listener)+ listener.opened.await()+ val host = CdpHost(socket, listener)+ host.send("Runtime.enable", buildJsonObject {})+ host.send("Page.enable", buildJsonObject {})+ host.send("Runtime.addBinding", buildJsonObject { put("name", BINDING) })+ host.send("Fetch.enable", buildJsonObject {+ put("patterns", buildJsonArray {+ AdBlock.blockedHosts.forEach { h -> add(buildJsonObject { put("urlPattern", "*://$h/*") }) }+ })+ })+ return host+ }++ private val defaultHttp = OkHttpClient.Builder().readTimeout(0, TimeUnit.MILLISECONDS).build()+ }+}diff --git a/base/host-cdp/src/test/kotlin/app/myspoti/host/cdp/LiveApiTest.kt b/base/host-cdp/src/test/kotlin/app/myspoti/host/cdp/LiveApiTest.ktnew file mode 100644index 00000000..02d24d55--- /dev/null+++ b/base/host-cdp/src/test/kotlin/app/myspoti/host/cdp/LiveApiTest.kt@@ -0,0 +1,173 @@+package app.myspoti.host.cdp++import app.myspoti.api.ItemKind+import app.myspoti.spotify.SpotifyApi+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.SupervisorJob+import kotlinx.coroutines.cancel+import kotlinx.coroutines.delay+import kotlinx.coroutines.flow.first+import kotlinx.coroutines.runBlocking+import kotlinx.coroutines.withTimeout+import org.junit.jupiter.api.AfterAll+import org.junit.jupiter.api.Assertions.assertEquals+import org.junit.jupiter.api.Assertions.assertNotEquals+import org.junit.jupiter.api.Assertions.assertTrue+import org.junit.jupiter.api.BeforeAll+import org.junit.jupiter.api.MethodOrderer+import org.junit.jupiter.api.Order+import org.junit.jupiter.api.Test+import org.junit.jupiter.api.TestInstance+import org.junit.jupiter.api.TestMethodOrder+import org.junit.jupiter.api.condition.EnabledIfSystemProperty+import kotlin.math.abs++/**+ * The whole API against a real, signed-in Web Player in desktop Chrome.+ *+ * google-chrome --user-data-dir=<profile> --remote-debugging-port=9222 # sign in once+ * ./gradlew :host-cdp:test -Pcdp=http://localhost:9222+ *+ * Every test restores what it changes (volume, queue, likes, pause).+ */+@TestInstance(TestInstance.Lifecycle.PER_CLASS)+@TestMethodOrder(MethodOrderer.OrderAnnotation::class)+@EnabledIfSystemProperty(named = "myspoti.cdp", matches = ".+")+class LiveApiTest {+ private val scope = CoroutineScope(SupervisorJob() + Dispatchers.Default)+ private lateinit var host: CdpHost+ private lateinit var api: SpotifyApi++ private fun live(block: suspend () -> Any?) { runBlocking { withTimeout(90_000) { block() } } }++ private suspend fun <T> eventually(timeoutMs: Long = 15_000, check: suspend () -> T?): T {+ val end = System.currentTimeMillis() + timeoutMs+ while (System.currentTimeMillis() < end) {+ check()?.let { return it }+ delay(300)+ }+ error("condition not reached in $timeoutMs ms")+ }++ @BeforeAll+ fun connect() = live {+ host = CdpHost.connect(System.getProperty("myspoti.cdp"))+ api = SpotifyApi(host, scope, language = "fr")+ host.reload()+ host.awaitLoad()+ api.onPageLoaded()+ api.awaitReady()+ }++ @AfterAll+ fun close() {+ runBlocking { runCatching { api.player.pause() } }+ host.close()+ scope.cancel()+ }++ @Test @Order(1)+ fun `search returns every kind in one round trip`() = live {+ val t0 = System.currentTimeMillis()+ val r = api.search.all("stromae", limit = 5)+ val ms = System.currentTimeMillis() - t0+ println("search.all: $ms ms")+ assertEquals(5, r.tracks.items.size)+ assertTrue(r.tracks.items.all { it.uri.startsWith("spotify:track:") && it.durationMs > 0 && it.artists.isNotEmpty() })+ println("artists: " + r.artists.items.map { it.name })+ assertTrue(r.artists.items.first().name.contains("Stromae", ignoreCase = true))+ assertTrue(r.albums.items.isNotEmpty() && r.playlists.items.isNotEmpty())+ assertTrue(r.tracks.total > 5 && r.tracks.nextOffset != null)+ assertTrue(api.search.suggestions("stro").isNotEmpty())+ assertEquals(0, api.httpGql.fellBack.get(), "reads must use the direct HTTP path")+ assertTrue(api.httpGql.direct.get() >= 5)+ }++ @Test @Order(2)+ fun `catalog reads track, album and artist`() = live {+ val hit = api.search.tracks("papaoutai", limit = 1).items.single()+ val track = api.catalog.track(hit.uri)+ assertEquals(hit.uri, track.uri)+ val album = api.catalog.album(track.album!!.uri)+ assertTrue(album.trackCount > 0 && album.images.isNotEmpty())+ val tracks = api.catalog.albumTracks(album.uri)+ assertEquals(album.trackCount.coerceAtMost(50), tracks.items.size)+ val artist = api.catalog.artist(track.artists.first().uri)+ assertTrue(artist.name.isNotBlank() && (artist.monthlyListeners ?: 0) > 0)+ assertTrue(api.catalog.artistTopTracks(artist.uri).isNotEmpty())+ }++ @Test @Order(3)+ fun `playlists page through their tracks`() = live {+ val pl = api.playlists.playlist(TOP_HITS)+ assertTrue(pl.name.isNotBlank() && pl.trackCount >= 50)+ val first = api.playlists.tracks(TOP_HITS, 0, 30)+ val second = api.playlists.tracks(TOP_HITS, 30, 30)+ assertEquals(30, first.items.size)+ assertTrue(second.items.isNotEmpty() && second.items.first().uri != first.items.first().uri)+ assertTrue(first.items.all { it.uid != null })+ api.playlists.mine() // the test account may have none; it must not fail+ }++ @Test @Order(4)+ fun `library toggles a like and restores it`() = live {+ val uri = api.playlists.tracks(TOP_HITS, 10, 1).items.single().uri+ val was = api.library.contains(listOf(uri)).single()+ if (was) api.library.remove(listOf(uri)) else api.library.add(listOf(uri))+ eventually { api.library.contains(listOf(uri)).single().takeIf { it != was } }+ if (was) api.library.add(listOf(uri)) else api.library.remove(listOf(uri))+ eventually { api.library.contains(listOf(uri)).single().takeIf { it == was } }+ }++ @Test @Order(5)+ fun `player plays, pauses, seeks and skips`() = live {+ api.player.play(TOP_HITS, index = 0)+ val playing = eventually { api.player.state.value?.takeIf { it.contextUri == TOP_HITS && !it.isPaused && it.item != null } }+ assertEquals(ItemKind.TRACK, playing.item!!.kind)+ delay(3_000)+ assertTrue(api.player.state.value!!.positionAt(System.currentTimeMillis()) > 1_000)++ api.player.pause()+ eventually { api.player.state.value?.takeIf { it.isPaused } }+ api.player.resume()+ eventually { api.player.state.value?.takeIf { !it.isPaused } }++ val target = playing.item!!.durationMs / 2+ api.player.seek(target)+ eventually { api.player.state.value?.takeIf { abs(it.positionAt(System.currentTimeMillis()) - target) < 3_000 } }++ val first = playing.item!!.uri+ api.player.next()+ eventually { api.player.state.value?.takeIf { it.item?.uri != first } }+ api.player.previous()+ delay(1_000)+ if (api.player.state.value?.item?.uri != first) {+ eventually { api.player.state.value?.takeIf { it.restrictions.canSkipPrevious } }+ api.player.previous()+ }+ eventually { api.player.state.value?.takeIf { it.item?.uri == first } }+ }++ @Test @Order(6)+ fun `queue adds and removes a track`() = live {+ val candidate = eventually { api.player.queue.value?.nextUp?.getOrNull(3) }+ api.player.addToQueue(listOf(candidate.uri))+ val queued = eventually { api.player.queue.value?.queued?.filter { it.uri == candidate.uri }?.takeIf { it.isNotEmpty() } }+ api.player.removeFromQueue(queued)+ eventually { api.player.queue.value?.queued?.takeIf { q -> q.none { it.uri == candidate.uri } } }+ }++ @Test @Order(7)+ fun `volume is set and restored`() = live {+ val old = api.player.volume()+ api.player.setVolume(0.3)+ eventually { api.player.volume().takeIf { abs(it - 0.3) < 0.02 } }+ api.player.setVolume(old)+ assertNotEquals(-1.0, old)+ }++ companion object {+ const val TOP_HITS = "spotify:playlist:37i9dQZF1DXcBWIGoYBM5M"+ }+}diff --git a/base/host-cdp/src/test/kotlin/app/myspoti/host/cdp/LiveDomainsTest.kt b/base/host-cdp/src/test/kotlin/app/myspoti/host/cdp/LiveDomainsTest.ktnew file mode 100644index 00000000..0d56c8ab--- /dev/null+++ b/base/host-cdp/src/test/kotlin/app/myspoti/host/cdp/LiveDomainsTest.kt@@ -0,0 +1,271 @@+package app.myspoti.host.cdp++import app.myspoti.api.HomeFilter+import app.myspoti.api.JamAvailability+import app.myspoti.api.LibraryFilter+import app.myspoti.api.LibrarySort+import app.myspoti.api.MediaKind+import app.myspoti.api.TimeRange+import app.myspoti.spotify.SpotifyApi+import kotlinx.coroutines.CoroutineScope+import kotlinx.coroutines.Dispatchers+import kotlinx.coroutines.SupervisorJob+import kotlinx.coroutines.cancel+import kotlinx.coroutines.delay+import kotlinx.coroutines.runBlocking+import kotlinx.coroutines.withTimeout+import org.junit.jupiter.api.AfterAll+import org.junit.jupiter.api.Assertions.assertEquals+import org.junit.jupiter.api.Assertions.assertNotNull+import org.junit.jupiter.api.Assertions.assertTrue+import org.junit.jupiter.api.BeforeAll+import org.junit.jupiter.api.Test+import org.junit.jupiter.api.TestInstance+import org.junit.jupiter.api.condition.EnabledIfSystemProperty++/** Every domain beyond playback, against the real Web Player. Writes are undone in the same test. */+@TestInstance(TestInstance.Lifecycle.PER_CLASS)+@EnabledIfSystemProperty(named = "myspoti.cdp", matches = ".+")+class LiveDomainsTest {+ private val scope = CoroutineScope(SupervisorJob() + Dispatchers.Default)+ private lateinit var host: CdpHost+ private lateinit var api: SpotifyApi++ private fun live(block: suspend () -> Any?) { runBlocking { withTimeout(120_000) { block() } } }++ private suspend fun <T> eventually(timeoutMs: Long = 15_000, check: suspend () -> T?): T = step("?", timeoutMs, check)++ private suspend fun <T> step(label: String, timeoutMs: Long = 15_000, check: suspend () -> T?): T {+ println("step: $label")+ val end = System.currentTimeMillis() + timeoutMs+ while (System.currentTimeMillis() < end) {+ runCatching { check() }.getOrNull()?.let { return it }+ delay(500)+ }+ error("$label: not reached in $timeoutMs ms")+ }++ @BeforeAll+ fun connect() = live {+ host = CdpHost.connect(System.getProperty("myspoti.cdp"))+ api = SpotifyApi(host, scope, language = "fr")+ host.reload()+ host.awaitLoad()+ api.onPageLoaded()+ api.awaitReady()+ }++ @AfterAll+ fun close() {+ host.close()+ scope.cancel()+ }++ @Test+ fun `home feed, filters and categories`() = live {+ val feed = api.home.feed()+ assertTrue(feed.greeting.isNotBlank())+ assertTrue(feed.shelves.size >= 5 && feed.shelves.all { it.items.isNotEmpty() })+ assertTrue(HomeFilter.PODCASTS in feed.filters)+ val podcasts = api.home.feed(HomeFilter.PODCASTS)+ assertTrue(podcasts.shelves.flatMap { it.items }.any { it.kind == MediaKind.SHOW || it.kind == MediaKind.EPISODE })+ val categories = api.home.categories()+ assertTrue(categories.size > 20 && categories.all { it.title.isNotBlank() })+ val news = api.home.whatsNew(0, 10)+ assertTrue(news.items.all { it.uri.startsWith("spotify:album:") && it.name.isNotBlank() })+ val page = api.home.category(categories.first().uri)+ assertTrue(page.title.isNotBlank() && page.shelves.isNotEmpty())+ }++ @Test+ fun `search every tab and recent searches`() = live {+ assertTrue(api.search.shows("france inter").items.first().kind == MediaKind.SHOW)+ assertTrue(api.search.episodes("france inter").items.first().durationMs > 0)+ assertTrue(api.search.audiobooks("harry potter").items.isNotEmpty())+ assertTrue(api.search.users("spotify").items.any { it.uri == "spotify:user:spotify" })+ assertTrue(api.search.genres("rap").items.isNotEmpty())+ api.search.recent()+ }++ @Test+ fun `artist pages beyond the overview`() = live {+ val artist = "spotify:artist:1McMsnEElThX1knmY4oliG"+ val disco = api.catalog.discography(artist, 0, 10)+ assertTrue(disco.items.size == 10 && disco.total > 10 && disco.items.all { it.uri.startsWith("spotify:album:") })+ assertTrue(api.catalog.relatedArtists(artist).size >= 10)+ assertTrue(api.catalog.appearsOn(artist).isNotEmpty())+ assertTrue(api.catalog.similarAlbums("spotify:track:4EoJ151oQ5jY48z4RhSE96").isNotEmpty())+ }++ @Test+ fun `library list, filters, liked songs and pins`() = live {+ val all = api.library.items()+ assertTrue(all.items.any { it.uri == "spotify:collection:tracks" })+ api.library.items(filter = LibraryFilter.PLAYLISTS, sort = LibrarySort.ALPHABETICAL)+ val liked = api.library.likedTracks()+ assertTrue(liked.items.all { it.track.uri.startsWith("spotify:track:") && it.track.durationMs > 0 })++ val target = all.items.first { it.uri != "spotify:collection:tracks" && !it.pinned }+ api.library.pin(target.uri)+ eventually { api.library.items().items.firstOrNull { it.uri == target.uri }?.takeIf { it.pinned } }+ api.library.unpin(target.uri)+ eventually { api.library.items().items.firstOrNull { it.uri == target.uri }?.takeIf { !it.pinned } }+ }++ @Test+ fun `folders and playlists are created, edited and removed`() = live {+ val folder = api.library.createFolder("Myspoti test folder")+ api.library.renameFolder(folder, "Myspoti test folder 2")+ step("folder renamed") { api.library.items().items.firstOrNull { it.uri == folder && it.name == "Myspoti test folder 2" } }++ val pl = api.playlists.create("Myspoti test playlist")+ step("playlist created") { api.playlists.mine().firstOrNull { it.uri == pl } }+ api.playlists.rename(pl, "Myspoti test playlist 2")+ api.playlists.setDescription(pl, "made by the live tests")+ step("playlist edited") { api.playlists.playlist(pl).takeIf { it.name == "Myspoti test playlist 2" && it.description == "made by the live tests" } }++ val songs = api.playlists.tracks(LiveApiTest.TOP_HITS, 0, 3).items.map { it.uri }+ api.playlists.addTracks(pl, songs)+ val rows = step("tracks added") { api.playlists.tracks(pl).items.takeIf { it.size == 3 } }+ api.playlists.moveTracks(pl, listOf(rows[2].uid!!), beforeUid = rows[0].uid)+ step("tracks moved") { api.playlists.tracks(pl).items.takeIf { it.first().uri == rows[2].uri } }+ api.playlists.removeTracks(pl, listOf(rows[1].uid!!))+ step("track removed") { api.playlists.tracks(pl).items.takeIf { it.size == 2 } }++ api.library.moveToFolder(pl, folder)+ step("moved to folder") { api.library.items(folderUri = folder).items.firstOrNull { it.uri == pl } }++ api.playlists.delete(pl)+ step("playlist deleted") { api.playlists.mine().none { it.uri == pl }.takeIf { it } }+ api.library.deleteFolder(folder)+ step("folder deleted") { api.library.items().items.none { it.uri == folder }.takeIf { it } }+ }++ @Test+ fun `podcasts shows and episodes`() = live {+ val show = api.podcasts.show("spotify:show:3vS7gWYpz4ry0yRnQ345hU")+ assertTrue(show.name.isNotBlank() && show.publisher.isNotBlank())+ val episodes = api.podcasts.episodes(show.uri, 0, 5)+ assertEquals(5, episodes.items.size)+ val ep = api.podcasts.episode(episodes.items.first().uri)+ assertTrue(ep.durationMs > 0 && ep.show?.uri == show.uri)+ val book = api.search.audiobooks("harry potter").items.first()+ val audiobook = api.podcasts.audiobook(book.uri)+ assertTrue(audiobook.name.isNotBlank())+ val chapters = api.podcasts.chapters(book.uri, 0, 3)+ assertTrue(chapters.items.isNotEmpty())++ val saved = api.library.contains(listOf(ep.uri)).single()+ if (!saved) api.library.add(listOf(ep.uri))+ eventually { api.podcasts.savedEpisodes().items.firstOrNull { it.uri == ep.uri } }+ if (!saved) {+ api.library.remove(listOf(ep.uri))+ eventually { api.podcasts.savedEpisodes().items.none { it.uri == ep.uri }.takeIf { it } }+ }+ }++ @Test+ fun `users, profile, top content and history`() = live {+ val me = api.users.me()+ assertTrue(me.uri.startsWith("spotify:user:") && !me.premium)+ val spotify = api.users.profile("spotify:user:spotify")+ assertTrue((spotify.followers ?: 0) > 1000 && spotify.publicPlaylists.isNotEmpty())+ api.users.top(TimeRange.SHORT_TERM)+ assertTrue(api.users.history().isNotEmpty())++ val was = api.users.isFollowing(listOf("spotify:user:spotify")).single()+ if (was) api.users.unfollow(listOf("spotify:user:spotify")) else api.users.follow(listOf("spotify:user:spotify"))+ eventually { api.users.isFollowing(listOf("spotify:user:spotify")).single().takeIf { it != was } }+ if (was) api.users.follow(listOf("spotify:user:spotify")) else api.users.unfollow(listOf("spotify:user:spotify"))+ eventually { api.users.isFollowing(listOf("spotify:user:spotify")).single().takeIf { it == was } }+ println("friend activity: " + api.users.friendActivity().size)+ }++ @Test+ fun `lyrics, canvas, credits and radio`() = live {+ val lyrics = api.extras.lyrics("spotify:track:4EoJ151oQ5jY48z4RhSE96")+ assertNotNull(lyrics)+ assertTrue(lyrics!!.synced && lyrics.lines.size > 10 && lyrics.background != null)+ assertNotNull(api.extras.canvas("spotify:track:55vPnuXfuzXNW75JpuSczF"))+ assertTrue(api.extras.credits("spotify:track:4EoJ151oQ5jY48z4RhSE96").roles.isNotEmpty())+ assertTrue(api.extras.radio("spotify:track:4EoJ151oQ5jY48z4RhSE96")!!.startsWith("spotify:playlist:"))+ assertTrue(api.extras.radio("spotify:artist:1McMsnEElThX1knmY4oliG")!!.startsWith("spotify:playlist:"))+ }++ @Test+ fun `devices and jam`() = live {+ api.devices.refresh()+ assertTrue(api.devices.devices.value.any { it.local })+ val availability = api.jam.availability()+ println("jam: $availability")+ assertTrue(availability != JamAvailability.UNKNOWN)+ api.jam.refresh()+ }++ @Test+ fun `taste exclusion, playlist suggestions and player modes`() = live {+ val track = "spotify:track:4EoJ151oQ5jY48z4RhSE96"+ api.extras.setExcludedFromTaste(track, true)+ step("excluded") { api.extras.isExcludedFromTaste(listOf(track)).single().takeIf { it } }+ api.extras.setExcludedFromTaste(track, false)+ step("included again") { api.extras.isExcludedFromTaste(listOf(track)).single().takeIf { !it } }++ val pl = api.playlists.create("Myspoti test suggestions")+ api.playlists.addTracks(pl, listOf(track))+ assertTrue(step("editable") { api.playlists.editable().firstOrNull { it.uri == pl } } != null)+ val recommended = api.playlists.recommended(pl, 5)+ assertTrue(recommended.isNotEmpty() && recommended.all { it.uri.startsWith("spotify:track:") && it.name.isNotBlank() })+ api.playlists.delete(pl)++ api.player.play(LiveApiTest.TOP_HITS, index = 0)+ step("playing") { api.player.state.value?.takeIf { !it.isPaused && it.item != null } }+ api.player.setRepeat(app.myspoti.api.Repeat.TRACK)+ step("repeat track") { api.player.state.value?.takeIf { it.repeat == app.myspoti.api.Repeat.TRACK } }+ api.player.setRepeat(app.myspoti.api.Repeat.OFF)+ step("repeat off") { api.player.state.value?.takeIf { it.repeat == app.myspoti.api.Repeat.OFF } }+ // Speed only applies to podcasts: Spotify refuses it on music.+ api.player.play("spotify:show:3vS7gWYpz4ry0yRnQ345hU", index = 0)+ step("episode playing") { api.player.state.value?.takeIf { it.item?.kind == app.myspoti.api.ItemKind.EPISODE && !it.isPaused } }+ api.player.setSpeed(1.5)+ step("speed 1.5") { api.player.state.value?.takeIf { it.speed == 1.5 } }+ api.player.setSpeed(1.0)+ api.player.play(LiveApiTest.TOP_HITS, index = 0)+ step("music again") { api.player.state.value?.takeIf { it.item?.kind == app.myspoti.api.ItemKind.TRACK && !it.isPaused } }+ api.player.addToQueue(listOf(track))+ step("queued") { api.player.queue.value?.queued?.takeIf { q -> q.any { it.uri == track } } }+ api.player.clearQueue()+ step("queue cleared") { api.player.queue.value?.queued?.takeIf { it.isEmpty() } }+ api.player.pause()+ }++ @Test+ fun `artist page, isrc and advanced queue`() = live {+ val page = api.catalog.artistPage("spotify:artist:1McMsnEElThX1knmY4oliG")+ assertTrue(page.topTracks.isNotEmpty() && page.topTracks.first().playcount != null && page.related.isNotEmpty())+ assertTrue(page.headerImages.isNotEmpty() || page.artist.images.isNotEmpty())+ assertEquals("USUG12601729", api.catalog.isrc("spotify:track:4EoJ151oQ5jY48z4RhSE96"))++ api.player.play(LiveApiTest.TOP_HITS, index = 0)+ step("playing") { api.player.state.value?.takeIf { !it.isPaused && it.item != null && it.next != null } }+ val upcoming = step("queue") { api.player.queue.value?.nextUp?.takeIf { it.size > 6 } }+ api.player.addToQueue(listOf(upcoming[5].uri))+ step("queued") { api.player.queue.value?.queued?.takeIf { it.isNotEmpty() } }+ api.player.playNext(listOf(upcoming[6].uri))+ val queued = step("play next first") { api.player.queue.value?.queued?.takeIf { it.size == 2 && it.first().uri == upcoming[6].uri } }+ api.player.moveInQueue(queued[0], queued[1], after = true)+ step("moved") { api.player.queue.value?.queued?.takeIf { it.size == 2 && it.first().uri == upcoming[5].uri } }+ api.player.clearQueue()+ step("cleared") { api.player.queue.value?.queued?.takeIf { it.isEmpty() } }+ val target = step("target") { api.player.queue.value?.nextUp?.getOrNull(2) }+ api.player.skipTo(target)+ step("skipped to") { api.player.state.value?.takeIf { it.item?.uri == target.uri } }+ api.player.pause()+ }++ @Test+ fun `raw access reaches untyped operations`() = live {+ val r = api.raw.gql("concertFeed", kotlinx.serialization.json.JsonObject(emptyMap()))+ assertNotNull(r)+ assertTrue(api.raw.operations.size >= 170)+ }+}diff --git a/base/licenses/Figtree-OFL.txt b/base/licenses/Figtree-OFL.txtnew file mode 100644index 00000000..80b12bb3--- /dev/null+++ b/base/licenses/Figtree-OFL.txt@@ -0,0 +1,93 @@+Copyright 2022 The Figtree Project Authors (https://github.com/erikdkennedy/figtree)++This Font Software is licensed under the SIL Open Font License, Version 1.1.+This license is copied below, and is also available with a FAQ at:+http://scripts.sil.org/OFL+++-----------------------------------------------------------+SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007+-----------------------------------------------------------++PREAMBLE+The goals of the Open Font License (OFL) are to stimulate worldwide+development of collaborative font projects, to support the font creation+efforts of academic and linguistic communities, and to provide a free and+open framework in which fonts may be shared and improved in partnership+with others.++The OFL allows the licensed fonts to be used, studied, modified and+redistributed freely as long as they are not sold by themselves. The+fonts, including any derivative works, can be bundled, embedded,+redistributed and/or sold with any software provided that any reserved+names are not used by derivative works. The fonts and derivatives,+however, cannot be released under any other type of license. The+requirement for fonts to remain under this license does not apply+to any document created using the fonts or their derivatives.++DEFINITIONS+"Font Software" refers to the set of files released by the Copyright+Holder(s) under this license and clearly marked as such. This may+include source files, build scripts and documentation.++"Reserved Font Name" refers to any names specified as such after the+copyright statement(s).++"Original Version" refers to the collection of Font Software components as+distributed by the Copyright Holder(s).++"Modified Version" refers to any derivative made by adding to, deleting,+or substituting -- in part or in whole -- any of the components of the+Original Version, by changing formats or by porting the Font Software to a+new environment.++"Author" refers to any designer, engineer, programmer, technical+writer or other person who contributed to the Font Software.++PERMISSION & CONDITIONS+Permission is hereby granted, free of charge, to any person obtaining+a copy of the Font Software, to use, study, copy, merge, embed, modify,+redistribute, and sell modified and unmodified copies of the Font+Software, subject to the following conditions:++1) Neither the Font Software nor any of its individual components,+in Original or Modified Versions, may be sold by itself.++2) Original or Modified Versions of the Font Software may be bundled,+redistributed and/or sold with any software, provided that each copy+contains the above copyright notice and this license. These can be+included either as stand-alone text files, human-readable headers or+in the appropriate machine-readable metadata fields within text or+binary files as long as those fields can be easily viewed by the user.++3) No Modified Version of the Font Software may use the Reserved Font+Name(s) unless explicit written permission is granted by the corresponding+Copyright Holder. This restriction only applies to the primary font name as+presented to the users.++4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font+Software shall not be used to promote, endorse or advertise any+Modified Version, except to acknowledge the contribution(s) of the+Copyright Holder(s) and the Author(s) or with their explicit written+permission.++5) The Font Software, modified or unmodified, in part or in whole,+must be distributed entirely under this license, and must not be+distributed under any other license. The requirement for fonts to+remain under this license does not apply to any document created+using the Font Software.++TERMINATION+This license becomes null and void if any of the above conditions are+not met.++DISCLAIMER+THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT+OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE+COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,+INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL+DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING+FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM+OTHER DEALINGS IN THE FONT SOFTWARE.diff --git a/base/settings.gradle.kts b/base/settings.gradle.ktsnew file mode 100644index 00000000..d855585c--- /dev/null+++ b/base/settings.gradle.kts@@ -0,0 +1,33 @@+pluginManagement {+ repositories {+ google {+ content {+ includeGroupByRegex("com\\.android.*")+ includeGroupByRegex("com\\.google.*")+ includeGroupByRegex("androidx.*")+ }+ }+ mavenCentral()+ gradlePluginPortal()+ }+}+plugins {+ id("org.gradle.toolchains.foojay-resolver-convention") version "1.0.0"+}+dependencyResolutionManagement {+ repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)+ repositories {+ google()+ mavenCentral()+ maven("https://jitpack.io") {+ content { includeGroupByRegex("com\\.github\\..*") }+ }+ }+}++rootProject.name = "Myspoti"+include(":app")+include(":api")+include(":api-spotify")+include(":host-cdp")+include(":host-android")diff --git a/docs/api/ADS.md b/docs/api/ADS.mdnew file mode 100644index 00000000..4d41fa36--- /dev/null+++ b/docs/api/ADS.md@@ -0,0 +1,89 @@+# Ads on a free account (Web Player)++Observed on 2026-10-15 with a free account in desktop Chrome, playing a playlist for+about 16 minutes. One audio ad break happened. Raw captures stay out of the repo.++## Where ads come from++| Kind | Source |+|---|---|+| Audio ad between tracks | Inserted by the server into the playback state machine |+| Banner ("leaderboard") | Page ad manager `leaderboard`, loaded into an iframe |+| Home ads, carousels | Page ad managers `home` and friends |+| Podcast pre/mid/post-rolls | Slots in the ad config, not observed yet |++The page groups its managers in `Platform.getAdManagers()`: `config`, `audio`,+`inStreamApi`, `leaderboard`, `home`, `vto`, `survey`, `adOpportunityLogger`. The registry+also has a `ForceVolumeAPI`.++## Audio ad timeline++1. At startup the page fetches `GET spclient.wg.spotify.com/ads/v2/config`. The `stream`+ slot carries `stream_time_elapsed_ms: 870000` (14.5 min) and `linear: true`.+2. Once enough listening time has passed, the server adds the ad to the reply of+ `PUT track-playback/v1/devices/{device}/state`. It arrives one track ahead: it was in+ the reply at the start of the previous track, about 4 minutes before it played.+3. The ad sits in `state_machine.tracks[]` like a track, with `content_type: "AD"`,+ `metadata.uri: "spotify:ad:{id}"`, a name, an advertiser, a duration (27 s here) and+ `manifest.file_urls_mp3`. The matching state has `disallow_seeking: true` and empty+ skip transitions (`disallow_seeking_reasons: ["ad_disallow"]`).+4. The audio is a plain MP3 from `adstudio-assets.scdn.co/mp3/{hash}.mp3`. It does not+ use Widevine.+5. During the ad, the page reports it like a track: `melody/v1/msg/batch`+ (`jssdk_playback_start` with `play_track: spotify:ad:…`), `gabo-receiver-service`+ events, `aet.spotify.com/v2/t`, and the usual `track-playback` state updates. The+ dealer WebSocket pushes the cluster state with the ad as current track.+6. After the ad ends, the next playlist track starts normally.++`PlayerAPI.getState().item` during the ad: `type: "ad"`, `uri: "spotify:ad:…"`, `title`+(no `name`), `advertiser`, `url` (click-through), `duration`, `images`. Restrictions:+`canSkipNext`, `canSkipPrevious` and `canSeek` are false; `canPause` is true.++## What the bridge does now++The bridge reports ads as items with `kind: "ad"`, plus `name`, `advertiser`, duration+and restrictions. The UI can show them: who the advertiser is, a countdown, and no skip+button.++## Options for the engine++| Option | What happens | Accounts risk | Notes |+|---|---|---|---|+| Show ads | The ad plays and the UI shows it | None | Matches Spotify's terms |+| Lower the volume during ads | The ad plays and is reported, the user hears little | Low to medium | `ForceVolumeAPI` exists. The page may push the volume back up or pause a muted ad. Needs a test. |+| Block the ad on the network | The ad item or its MP3 never plays | Higher | Changes what the page reports. It's the kind of tampering Spotify can detect, and it breaks if they change the format. |++Blocking ads goes against Spotify's Terms of Use (see the README disclaimer). Whatever+the choice, it should live in its own module behind the `:api` interface, so the policy+can change without touching the UI or the player bridge.++## Tested: blocking the ad audio (2026-10-16)++Setup: free account, desktop Chrome, requests to `adstudio-assets.scdn.co` aborted+(`blockedbyclient`) from the start of a long listening session.++1. At 00:20:13 the server put an ad (`spotify:ad:…`, 27 s) next in the state machine, as before.+2. The player tried to load its MP3; the request was aborted.+3. The page reported a playback error for the ad itself: `melody` `jssdk_playback_error`+ (`content_type: "ad"`), then `PUT track-playback/.../state` with `debug_source: "error"`.+4. The server moved on: the next state machine no longer held the ad, and the next playlist track+ started within one second (`jssdk_playback_start`, `started_playing`, then+ `played_threshold_reached` 30 s later, as for any track).+5. The ad was on screen for less than 0.5 s. No skip command was needed.++So the engine blocks ads by refusing the ad audio host, and lets the page report what really+happened (a failed ad load). It never reports an ad as played.++Engine rules:+- Android WebView: in `shouldInterceptRequest`, answer requests to `adstudio-assets.scdn.co` with an+ empty error response. Desktop CDP host: `Fetch.failRequest` (`BlockedByClient`) for the same pattern.+- Fallback, if an ad item stays current for more than 1 s (new ad host, video ad): play the next+ context track with `player.play {contextUri, trackUri}`, and add the new host to the block list.+- Banner, home and carousel ads never reach the user: the Web Player page is hidden and the UI is+ native. Their requests can still be blocked to save data.+- The UI drops `kind: "ad"` items from what it shows.++## Still to capture++- Whether blocked ads come back sooner (rhythm after a failed ad), over a 1-hour session.+- Video ads and podcast ad slots, which may use other hosts.diff --git a/docs/api/CAPABILITIES.md b/docs/api/CAPABILITIES.mdnew file mode 100644index 00000000..4280e6dc--- /dev/null+++ b/docs/api/CAPABILITIES.md@@ -0,0 +1,251 @@+# Web Player capabilities++Generated by `base/api-spotify/tools/capability_report.py` from build `web-player_2026-10-15_1792099594925_61b9bcdb1ef2`:+179 GraphQL operations. Every one can be called through the bridge with+`gql.query {name, hash, variables}`. Hashes: `base/api-spotify/src/main/resources/spotify/gql-ops.json`,+refreshed by `tools/refresh_gql_ops.py`.++Status: **spec** = documented in a docs/api file, **vars** = variables known from a capture.+Non-GraphQL capabilities (playback, queue, volume, Connect, playlist edits, folders) go through the+Coverage: 44 documented, 58 with known variables, out of 179.+player and `service.call`; see the bridge README.++## Search (21)++| Operation | Kind | Spec | Vars |+|---|---|---|---|+| `recentSearches` | query | yes | yes |+| `removeRecentSearches` | mutation | | |+| `saveRecentSearches` | mutation | | |+| `searchAlbums` | query | yes | yes |+| `searchArtists` | query | yes | yes |+| `searchAudiobooks` | query | | |+| `searchAuthors` | query | | |+| `searchConcertLocations` | query | | |+| `searchDesktop` | query | | |+| `searchEpisodes` | query | | |+| `searchFullEpisodes` | query | | yes |+| `searchGenres` | query | | yes |+| `searchModalEntityPage` | query | | |+| `searchModalResults` | query | | |+| `searchPlaylists` | query | yes | yes |+| `searchPodcasts` | query | | yes |+| `searchSuggestions` | query | yes | yes |+| `searchTopResultsList` | query | yes | yes |+| `searchTopResultsOnly` | query | | |+| `searchTracks` | query | yes | yes |+| `searchUsers` | query | | yes |++## Home and browse (14)++| Operation | Kind | Spec | Vars |+|---|---|---|---|+| `SetItemsStateInWhatsNewFeed` | mutation | | |+| `browseAll` | query | yes | yes |+| `browsePage` | query | | yes |+| `browseSection` | query | | |+| `countryHubContent` | query | | |+| `countryHubsPage` | query | | |+| `home` | query | yes | yes |+| `homePinnedSections` | query | | |+| `homeSection` | query | | |+| `queryWhatsNewFeed` | query | | |+| `seoRecommendedTrackPlaylistDesktop` | query | | |+| `watchFeedEntity` | query | | |+| `watchFeedView` | query | | |+| `whatsNewFeedNewItems` | query | | |++## Tracks (19)++| Operation | Kind | Spec | Vars |+|---|---|---|---|+| `albumPreReleaseTracks` | query | | |+| `canvas` | query | yes | yes |+| `decorateContextTracks` | query | yes | yes |+| `fetchLibraryTracks` | query | | |+| `getAlbumNameAndTracks` | query | | |+| `getArtistNameAndTracks` | query | | |+| `getTrack` | query | yes | yes |+| `getTrackName` | query | | |+| `getVideoTrackAssociatedAlbum` | query | | |+| `internalLinkRecommenderTrack` | query | yes | yes |+| `npvPageContent` | query | | |+| `npvV2TrackSupplementalSections` | query | yes | yes |+| `queryAlbumTrackUris` | query | | |+| `queryAlbumTracks` | query | yes | yes |+| `queryTrackArtists` | query | yes | yes |+| `queryTrackCreditsGroupedModal` | query | | |+| `similarAlbumsBasedOnThisTrack` | query | yes | yes |+| `smartShuffle` | query | | |+| `trackPreview` | query | | |++## Albums (7)++| Operation | Kind | Spec | Vars |+|---|---|---|---|+| `assistedCurationSearchAlbum` | query | | |+| `fetchExtractedColorAndImageForAlbumEntity` | query | | |+| `fetchExtractedColorForAlbumEntity` | query | | |+| `getAlbum` | query | yes | yes |+| `queryAlbumMerch` | query | yes | yes |+| `queryArtistDiscographyAlbums` | query | | |+| `queryInlineCurationSearchAlbum` | query | | |++## Artists (22)++| Operation | Kind | Spec | Vars |+|---|---|---|---|+| `ArtistConcerts` | query | | |+| `ArtistConcertsPageLocation` | query | | |+| `assistedCurationSearchArtist` | query | | |+| `fetchExtractedColorAndImageForArtistEntity` | query | | |+| `fetchExtractedColorForArtistEntity` | query | | |+| `queryArtistAboutModal` | query | | |+| `queryArtistAppearsOn` | query | | |+| `queryArtistDiscographyAll` | query | yes | yes |+| `queryArtistDiscographyCompilations` | query | | |+| `queryArtistDiscographyOverview` | query | | yes |+| `queryArtistDiscographySingles` | query | | |+| `queryArtistDiscoveredOn` | query | | |+| `queryArtistFeaturing` | query | | |+| `queryArtistMinimal` | query | | |+| `queryArtistOverview` | query | yes | yes |+| `queryArtistPlaylists` | query | | |+| `queryArtistRelated` | query | | yes |+| `queryArtistRelatedVideos` | query | | |+| `queryInlineCurationSearchArtist` | query | | |+| `queryMoreByArtist` | query | | |+| `queryNpvArtist` | query | yes | yes |+| `thisisPlaylistExtension` | query | | |++## Playlists (22)++| Operation | Kind | Spec | Vars |+|---|---|---|---|+| `addToPlaylist` | mutation | yes | yes |+| `applyCurations` | mutation | yes | yes |+| `applyCurationsV2` | mutation | | |+| `assistedCurationSearch` | query | | |+| `curateItems` | mutation | | |+| `editablePlaylists` | query | yes | yes |+| `fetchExtractedColorAndImageForPlaylistEntity` | query | | |+| `fetchExtractedColorForPlaylistEntity` | query | | |+| `fetchPlaylist` | query | yes | yes |+| `fetchPlaylistContents` | query | yes | yes |+| `fetchPlaylistMetadata` | query | yes | yes |+| `getLists` | query | | |+| `getListsContents` | query | | |+| `getListsMetadata` | query | | |+| `isCurated` | query | yes | yes |+| `isCuratedEntities` | query | | |+| `moveItemsInPlaylist` | mutation | | |+| `playlistPermissions` | query | yes | yes |+| `playlistSection` | query | | |+| `queryInlineCurationSearchV2` | query | | |+| `queryInlineCurationSearchV2Booklists` | query | | |+| `removeFromPlaylist` | mutation | yes | yes |++## Library (9)++| Operation | Kind | Spec | Vars |+|---|---|---|---|+| `addToLibrary` | mutation | yes | yes |+| `addVenueToLibrary` | mutation | | |+| `areEntitiesInLibrary` | query | yes | yes |+| `libraryV3` | query | yes | yes |+| `pinLibraryItem` | mutation | | |+| `recents` | query | yes | yes |+| `removeFromLibrary` | mutation | yes | yes |+| `removeVenueFromLibrary` | mutation | | |+| `unpinLibraryItem` | mutation | | |++## Podcasts and audiobooks (17)++| Operation | Kind | Spec | Vars |+|---|---|---|---|+| `decorateContextEpisodesOrChapters` | query | | |+| `fetchExtractedColorAndImageForEpisodeEntity` | query | | |+| `fetchExtractedColorAndImageForPodcastEntity` | query | | |+| `fetchExtractedColorForEpisodeEntity` | query | | |+| `fetchExtractedColorForPodcastEntity` | query | | |+| `getAudiobooksMetadata` | query | | |+| `getEpisodeName` | query | | |+| `getEpisodeOrChapter` | query | | yes |+| `getPodcastOrBookName` | query | | |+| `internalLinkRecommenderEpisode` | query | | yes |+| `internalLinkRecommenderShow` | query | | yes |+| `queryBookChapters` | query | | |+| `queryNpvEpisode` | query | | |+| `queryPodcastEpisodes` | query | | yes |+| `queryShowMetadataV2` | query | | yes |+| `showItemsPlayedState` | query | | |+| `similarAudiobooks` | query | | |++## User and social (19)++| Operation | Kind | Spec | Vars |+|---|---|---|---|+| `accountAttributes` | query | yes | yes |+| `addComment` | mutation | | |+| `addCommentReaction` | mutation | | |+| `addCommentReply` | mutation | | |+| `decorateQueuedByUsers` | query | yes | yes |+| `deleteComment` | mutation | | |+| `deleteCommentReaction` | mutation | | |+| `deleteCommentReply` | mutation | | |+| `followUsers` | mutation | | |+| `getCommentsForEntity` | query | | yes |+| `getReactions` | query | | |+| `getReplies` | query | | |+| `inferredUserLocation` | query | | |+| `isFollowingUsers` | query | | |+| `profileAttributes` | query | yes | yes |+| `unfollowUsers` | mutation | | |+| `userAccountId` | query | | |+| `userLocation` | query | | |+| `userTopContent` | query | | yes |++## Concerts and location (15)++| Operation | Kind | Spec | Vars |+|---|---|---|---|+| `ConcertCampaign` | query | | |+| `ConcertGallery` | query | | |+| `concert` | query | | |+| `concertConcepts` | query | | |+| `concertCount` | query | | |+| `concertFeed` | query | | |+| `concertLocationDetails` | query | | |+| `concertLocationsByLatLon` | query | | |+| `concertNotInterestedSet` | mutation | | |+| `concertNotInterestedUndo` | mutation | | |+| `concertRoutingCardVisuals` | query | | |+| `deleteLocation` | mutation | | |+| `saveLocation` | mutation | | |+| `undoConcertCampaignNotInterested` | mutation | | |+| `venue` | query | | |++## Colors and images (6)++| Operation | Kind | Spec | Vars |+|---|---|---|---|+| `fetchExtractedColorAndImageForTrackEntity` | query | | |+| `fetchExtractedColorForTrackEntity` | query | | |+| `fetchExtractedColors` | query | yes | yes |+| `getDynamicColors` | query | | |+| `getDynamicColorsByUris` | query | yes | yes |+| `lookupEntityImages` | query | | |++## Other (8)++| Operation | Kind | Spec | Vars |+|---|---|---|---|+| `albumPreRelease` | query | | |+| `centralisedStatePlayerOptions` | query | yes | yes |+| `changeAttributes` | mutation | | |+| `episodeSponsoredContent` | query | | |+| `fetchEntitiesForRecentlyPlayed` | query | yes | yes |+| `lookupChildEntities` | query | yes | yes |+| `lookupDebug` | query | | |+| `requestPromoCode` | mutation | | |+diff --git a/docs/api/CAPTURE-MAP.md b/docs/api/CAPTURE-MAP.mdnew file mode 100644index 00000000..74813dd8--- /dev/null+++ b/docs/api/CAPTURE-MAP.md@@ -0,0 +1,76 @@+# Web Player capture map++Clean-room notes for the new API, taken from network captures of open.spotify.com+(free account, Chrome 155 with Widevine, 2026-10-15). Raw captures hold tokens and+stay out of the repo. `{user}` is the account id, `{id}` a base62 id, `{hex}` a file+or device id. GraphQL calls all go to `POST api-partner.spotify.com/pathfinder/v2/query`+and are listed by `operationName`.++## Session++| Step | Calls |+|---|---|+| Login (Spotify's own page) | `accounts.spotify.com/login`, `login/code/send`, `login/code/verify` (e-mail code flow) |+| Web token | `GET open.spotify.com/api/token` |+| Client token | `POST clienttoken.spotify.com/v1/clienttoken` |+| Access points | `GET apresolve.spotify.com/` (spclient + dealer hosts) |+| Push channel | WebSocket `{region}-dealer.g2.spotify.com` |+| Config | `POST {spclient}/remote-config-resolver/v3/configuration`, gql `accountAttributes`, `profileAttributes` |++## Playback (Web Player device)++| Action | Calls |+|---|---|+| Register device | `POST {spclient}/track-playback/v1/devices`, `PUT connect-state/v1/devices/hobs_{hex}` |+| Play a context | `POST connect-state/v1/player/command/from/{hex}/to/{hex}` |+| Resolve audio | `GET manifests/v9/json/sources/{hex}/options/supports_drm`, `GET storage-resolve/v2/files/audio/interactive/10/{hex}`, `GET seektables.spotifycdn.com/v1/seektable/{hex}` |+| DRM | `GET widevine-license/v1/application-certificate`, `POST widevine-license/v1/audio/license` (EME, handled by the browser CDM) |+| Audio | `GET audio-fa.scdn.co/audio/{hex}` (encrypted segments) |+| Report state | `PUT track-playback/v1/devices/{hex}/state` (on play, pause, seek, skip) |+| Volume | `PUT track-playback/v1/devices/{hex}/volume` |+| Next track media | `GET track-playback/v1/media/{uri}` |+| Cluster state | `GET connect-state/v1/cluster`, then dealer pushes |+| Events | `POST gabo-receiver-service/v3/events` (playback and UI events) |++Free account: no shuffle button on a playlist context in the web UI.++## Catalog and search++| Action | GraphQL operations |+|---|---|+| Home | `home`, `feedBaselineLookup` |+| Search | `recentSearches`, `searchSuggestions` (as you type), `searchTopResultsList` (submit), `searchTracks`, `searchArtists`, `searchAlbums`, `searchPlaylists` |+| Browse | `browseAll` |+| Track | `getTrack`, `internalLinkRecommenderTrack`, `similarAlbumsBasedOnThisTrack`, `canvas`, `npvV2TrackSupplementalSections` |+| Album | `getAlbum` |+| Artist | `queryArtistOverview`, plus `GET playlist/v2/list/popular-release-segments-main-roles/artist_{id}` |+| Lyrics | `GET color-lyrics/v2/track/{id}/image/{cover}`, `GET timesynced-text-distribution/v0/get-timesynced-text/{uri}` |+| Extra metadata | `POST extended-metadata/v0/extended-metadata`, `GET metadata/4/track/{hex}` |++## Library and playlists++| Action | Calls |+|---|---|+| Library list | gql `libraryV3`, `GET playlist/v2/user/{user}/rootlist` |+| Liked Songs page | gql `fetchPlaylist` on `collection/tracks` |+| Playlist page | gql `fetchPlaylist`, `fetchPlaylistContents`, `fetchPlaylistMetadata`, `playlistPermissions`, `isCurated` |+| Follow / unfollow playlist | `POST playlist/v2/user/{user}/rootlist/changes` |+| Create playlist | `POST playlist/v2/playlist`, then `rootlist/changes` |+| Rename | `POST playlist/v2/playlist/{id}/changes` |+| Add track to playlist | gql `addToPlaylist` |+| Suggested tracks | `POST playlistextender/extendp/` |+| In library? | gql `areEntitiesInLibrary`, `POST collection/v2/contains` |++## Likes and follows++| Action | GraphQL operations |+|---|---|+| Like a track | `addToLibrary` |+| Unlike a track | `applyCurations` (with `editablePlaylists`) |+| Save / unsave album | `addToLibrary` / `removeFromLibrary` |+| Follow / unfollow artist | `addToLibrary` / `removeFromLibrary` |++## Not captured yet++Remove a track from a playlist, delete a playlist, reorder, Connect to another device,+podcasts, ads (`ads/v2/config` is fetched at startup).diff --git a/docs/api/CATALOG.md b/docs/api/CATALOG.mdnew file mode 100644index 00000000..2c43fd4b--- /dev/null+++ b/docs/api/CATALOG.md@@ -0,0 +1,414 @@+# Catalog API (Web Player)++Clean-room spec of how open.spotify.com (free account, 2026-10-15 captures) fetches+track, album, artist and playlist data. Derived only from network captures.+Placeholders: `{token}` web access token, `{client-token}`, `{id}` base62 id (22 chars),+`{hex}` 32-char hex id, `{user}` a user id. Ids in examples are fake.++## Common request shape++### GraphQL (pathfinder v2)++`POST https://api-partner.spotify.com/pathfinder/v2/query`++| Header | Holds |+|---|---|+| `authorization` | `Bearer {token}` (web token from `open.spotify.com/api/token`) |+| `client-token` | `{client-token}` from `clienttoken.spotify.com/v1/clienttoken` |+| `app-platform` | constant platform name of the web player (`WebPlayer`) |+| `spotify-app-version` | web player build string (`1.2.x.xxxx.gxxxxxxxx` shape) |+| `content-type` | `application/json;charset=UTF-8` |+| `accept` | `application/json` |+| `accept-language` | UI language (`fr` in captures); localises type labels such as `identityTrait.type` |++Body:++```json+{"variables": {...}, "operationName": "getAlbum",+ "extensions": {"persistedQuery": {"version": 1, "sha256Hash": "<hash>"}}}+```++Response: `{"data": {...}}`, `content-type: application/json`, gzip or zstd,+`cache-control: private, max-age=0`. No `errors` key appeared in any capture. A missing+or expired entity is not an HTTP error: it comes back as `200` with+`{"data":{"playlistV2":{"__typename":"NotFound","message":"Object with uri '...' not found"}}}`.+Always check `__typename` (`Track`, `Album`, `Artist`, `Playlist`, `NotFound`).++### spclient REST++Host `https://spclient.wg.spotify.com` (from `apresolve`). Same `authorization`,+`client-token`, `app-platform`, `spotify-app-version` headers as GraphQL.++## Operation index++| Operation | Hash (sha256, version 1) | Used for |+|---|---|---|+| `getTrack` | `a8ef9e9f02b836feb0da3003c31dbb30decc6f4b473ef89ca88c882386d668de` | Track page |+| `getAlbum` | `11c9cad9cb24c4f9e25ef9456f68621cfd6006a90f679e729c1d2f2fd70dfe16` | Album page (first page of tracks) |+| `queryArtistOverview` | `9f8134ef565e78621f1e1793555bd6633c5ac144ae0f89604ed3ae3f80b3c8e6` | Artist page |+| `queryNpvArtist` | `e1ae46a21911a3075c1aa29bf09a6c60f9a45b6a2b1132429f10ad06c299b5d7` | Now-playing view: artist card + track credits |+| `queryTrackArtists` | `ee2b038198f5e62c679c3996584d9249bbee55fe69fc212271c56492a022c798` | Artist list of one track |+| `queryAlbumMerch` | `3ef44ed6f17be67299538fe77faffab4075aeaf9e1085f10fc835592266711b5` | Merch row on album page (not needed) |+| `fetchPlaylist` | `21ea11a6ac75a5f3e01fd365d29c18e0a4a8b7dc09f89bbb5d73910190c6acaf` | Playlist page: header + first 25 items |+| `fetchPlaylistContents` | same hash as `fetchPlaylist` | Next pages of items |+| `fetchPlaylistMetadata` | same hash as `fetchPlaylist` | Header + light item list (uri, duration) |+| `playlistPermissions` | `e43d1d35f231cf289c23c9d9c489f4a4f502e4eda09839c530608f107b6556b8` | Owner/members, edit rights |+| `isCurated` | `e4ed1f91a2cc5415befedb85acf8671dc1a4bf3ca1a5b945a6386101a22e28a6` | "In your library/playlists" flag per uri |+| (unnamed, v1) | `f952da037440f694cc6925b9e3f649d39077a744c4db7dfba01cb883723f4f77` | Batch track lookup (`lookupEntities`) |++The three playlist operations share one persisted query; the server picks the selection+by `operationName`, so the name must be sent and must match.++## Shared fragments++| Fragment | JSON | Notes |+|---|---|---|+| Image list | `coverArt.sources[] {url, width, height}` | Album covers: 64, 300, 640 px (`i.scdn.co/image/ab67616d00004851…`, `…00001e02…`, `…0000b273…`). Artist avatars: 160, 320, 640. Playlist `images.items[].sources[]` often has `width`/`height` = `null` (mosaics, editorial covers). |+| ImageV2 | `data.sources[] {url, maxWidth, maxHeight, imageFormat}` | Header images, watch-feed thumbs, `itemV3` covers. `maxWidth`/`maxHeight` may be 0. |+| Colors | `coverArt.extractedColors.{colorRaw,colorDark,colorLight}.hex` (`"#D8B8C8"`) | `colorRaw` always present; dark/light on album. |+| Color set | `visualIdentity.squareCoverImage.extractedColorSet.{highContrast,higherContrast,minContrast}.{backgroundBase,backgroundTintedBase,textBase,textBrightAccent,textSubdued}.{red,green,blue,alpha}` | 0-255 ints. Also `encoreBaseSetTextColor`. |+| Artists | `artists.items[] {uri, profile.name}` (+ `id`, `visuals.avatarImage` on album/artist) | |+| Duration | `duration.totalMilliseconds` (track, album) / `trackDuration.totalMilliseconds` (playlist items) | |+| Playability | `playability {playable: bool, reason: "PLAYABLE"}` | Only `PLAYABLE` observed; `reason` sometimes absent. |+| Content rating | `contentRating.label` = `EXPLICIT` / `NONE`; `contentRatingV2.labels[]` (or `null`) | |+| Date | `date {isoString, precision, year, month?, day?}` | precision `DAY`, `YEAR`, `MINUTE` seen. |+| Album type | `type` = `ALBUM`, `SINGLE`, `EP`, `COMPILATION` | |+| Play count | `playcount` | String, not number (`"513599385"`). |+| Sharing | `sharingInfo {shareId, shareUrl}` | Not needed. |+| Paging | `{items[], totalCount, pagingInfo{offset, limit}}` | Some lists use `pagingInfo.nextOffset` (null = end). |++## getTrack++Variables: `uri` (string, `spotify:track:{id}`), `includeVideoAssociationItems` (bool, `true`).++Root `data.trackUnion` (`__typename: "Track"`):++| Path | Content |+|---|---|+| `id`, `uri`, `name`, `trackNumber`, `mediaType` (`AUDIO`) | identity |+| `duration.totalMilliseconds`, `playcount`, `saved` | |+| `playability`, `contentRating`, `contentRatingV2` | |+| `albumOfTrack {id, uri, name, type, date, coverArt, copyright.items[{text,type}], courtesyLine, playability, tracks{totalCount, items[].track{uri,trackNumber}}}` | album, with full track uri list |+| `firstArtist.items[0]` / `otherArtists.items[]` | `{id, uri, profile.name, visuals.avatarImage}`; first artist also has `discography {topTracks, popularReleasesAlbums, albums, singles}` (10 each) and `relatedContent.relatedArtists` (20 of `totalCount`) |+| `visualIdentity.squareCoverImage.extractedColorSet` | colors |+| `associationsV3.videoAssociations` | music video variant (`mediaType: VIDEO`), not needed |++No disc number in `getTrack` (use `metadata/4` or album).++```json+{"data":{"trackUnion":{"__typename":"Track","id":"{id}","uri":"spotify:track:{id}",+ "name":"Some Song","trackNumber":6,"mediaType":"AUDIO","saved":false,+ "duration":{"totalMilliseconds":317404},"playcount":"122666293",+ "playability":{"playable":true,"reason":"PLAYABLE"},+ "contentRating":{"label":"EXPLICIT"},"contentRatingV2":{"labels":["EXPLICIT"]},+ "albumOfTrack":{"id":"{id}","uri":"spotify:album:{id}","name":"Some Album","type":"ALBUM",+ "date":{"isoString":"2019-03-29T00:00:00Z","precision":"DAY","year":2019},+ "coverArt":{"extractedColors":{"colorRaw":{"hex":"#002858"}},+ "sources":[{"url":"https://i.scdn.co/image/{img}","width":300,"height":300}]},+ "tracks":{"totalCount":18,"items":[{"track":{"uri":"spotify:track:{id}","trackNumber":1}}]}},+ "firstArtist":{"totalCount":2,"items":[{"id":"{id}","uri":"spotify:artist:{id}",+ "profile":{"name":"Artist A"},+ "visuals":{"avatarImage":{"sources":[{"url":"…","width":640,"height":640}]}}}]},+ "otherArtists":{"items":[{"id":"{id}","uri":"spotify:artist:{id}","profile":{"name":"Artist B"}}]}}}}+```++## getAlbum++Variables: `uri` (`spotify:album:{id}`), `locale` (string, `intl-fr`, the URL locale+prefix; empty string likely for default), `offset` (int, `0`), `limit` (int, `50`).++Root `data.albumUnion` (`__typename: "Album"`), plus `data.meV2.ianaTimezoneId`.++| Path | Content |+|---|---|+| `uri`, `name`, `type`, `label`, `date {isoString, precision}` | |+| `isPreRelease`, `preReleaseEndDateTime` | pre-release flag |+| `coverArt {extractedColors{colorDark,colorLight,colorRaw}, sources[]}` | |+| `artists.items[] {id, uri, profile.name, visuals.avatarImage}` | |+| `copyright.items[{text, type}]` (`C`, `P`), `courtesyLine` | footer |+| `discs {totalCount, items[{number, tracks.totalCount}]}` | disc grouping |+| `tracksV2 {totalCount, items[]}` | page `offset..offset+limit` |+| `tracksV2.items[] {uid, track{uri, name, trackNumber, discNumber, duration, playcount, playability, contentRating, saved, relinkingInformation, artists.items[]}}` | track rows (no `id`; take it from `uri`) |+| `releases.items[{uri, name}]` | other editions |+| `moreAlbumsByArtist.items[0].discography.popularReleasesAlbums.items[]` | "More by" row |+| `playability`, `saved` | |++Paging: only `offset`/`limit` variables; `tracksV2` has `totalCount`. The captured album+had 2 tracks, so the follow-up request for albums over 50 tracks was not seen (see Gaps).++```json+{"data":{"albumUnion":{"__typename":"Album","uri":"spotify:album:{id}","name":"Some Single",+ "type":"SINGLE","label":"Some Label","isPreRelease":false,+ "date":{"isoString":"2026-05-22T00:00:00Z","precision":"DAY"},+ "playability":{"playable":true,"reason":"PLAYABLE"},"saved":false,+ "coverArt":{"extractedColors":{"colorDark":{"hex":"#86727C"},"colorLight":{"hex":"#D8B8C8"},+ "colorRaw":{"hex":"#D8B8C8"}},"sources":[{"url":"…","width":300,"height":300}]},+ "artists":{"totalCount":1,"items":[{"id":"{id}","uri":"spotify:artist:{id}",+ "profile":{"name":"Artist A"}}]},+ "copyright":{"totalCount":2,"items":[{"text":"© 2026 Label","type":"C"}]},+ "discs":{"totalCount":1,"items":[{"number":1,"tracks":{"totalCount":2}}]},+ "tracksV2":{"totalCount":2,"items":[{"uid":"1c367241bacbef393075","track":{+ "uri":"spotify:track:{id}","name":"Song","trackNumber":1,"discNumber":1,+ "duration":{"totalMilliseconds":297090},"playcount":"513599385",+ "contentRating":{"label":"EXPLICIT"},"playability":{"playable":true},"saved":false,+ "relinkingInformation":null,+ "artists":{"items":[{"uri":"spotify:artist:{id}","profile":{"name":"Artist A"}}]}}}]}},+ "meV2":{"ianaTimezoneId":"{tz}"}}}+```++## queryArtistOverview++Variables: `uri` (`spotify:artist:{id}`), `locale` (`intl-fr`), `preReleaseV2` (bool, `true`).++Root `data.artistUnion` (`__typename: "Artist"`):++| Path | Content |+|---|---|+| `id`, `uri`, `profile.name`, `saved` (= followed) | |+| `profile.biography {text, type}`, `profile.externalLinks.items[{name, url}]` | About |+| `onPlatformReputationTrait.verification {isVerified, isRegistered}` | verified badge |+| `stats {followers, monthlyListeners, worldRank, topCities.items[{city, country, region, numberOfListeners}]}` | |+| `visuals.avatarImage {sources[], extractedColors.colorRaw}`, `visuals.gallery.items[].sources[]` | |+| `headerImage.data.sources[] {url, maxWidth, maxHeight}` | banner (up to 1494x640) |+| `discography.topTracks.items[] {uid, track{id, uri, name, discNumber, duration, playcount, playability, contentRating, artists, albumOfTrack{uri, coverArt}}}` | Popular (10) |+| `discography.latest` | latest release (single object) |+| `discography.popularReleasesAlbums {totalCount, items[]}` | release objects directly |+| `discography.albums / singles / compilations {totalCount, items[].releases.items[0]}` | first 10 (albums 5 here); release = `{id, uri, name, type, label, date{year,month,day,precision}, coverArt, tracks.totalCount, playability, copyright}` |+| `relatedContent.relatedArtists {totalCount, items[{id, uri, profile.name, visuals.avatarImage}]}` | Fans also like (20) |+| `relatedContent.appearsOn {totalCount, items[].releases.items[0]{id, uri, name, type, date.year, coverArt, artists}}` | (20) |+| `relatedContent.featuringV2.items[].data {id, uri, name, description, images, ownerV2.data.name}` | "Featuring" playlists |+| `relatedContent.discoveredOnV2.items[]` | Discovered on playlists |+| `profile.playlistsV2.items[].data` | Artist playlists |+| `profile.pinnedItem {type, uri, title, subtitle, itemV2.data}` | Artist pick |+| `goods.concerts`, `goods.merch`, `relatedMusicVideos`, `unmappedMusicVideosV2`, `watchFeedEntrypoint`, `preReleaseV2` | not needed |++```json+{"data":{"artistUnion":{"__typename":"Artist","id":"{id}","uri":"spotify:artist:{id}",+ "saved":false,"profile":{"name":"Artist A","biography":{"text":"…","type":"AUTOBIOGRAPHY"}},+ "onPlatformReputationTrait":{"verification":{"isVerified":true,"isRegistered":true}},+ "stats":{"followers":57694926,"monthlyListeners":67636683,"worldRank":28},+ "visuals":{"avatarImage":{"sources":[{"url":"…","width":640,"height":640}]}},+ "headerImage":{"data":{"sources":[{"url":"…","maxWidth":1494,"maxHeight":640}]}},+ "discography":{+ "topTracks":{"items":[{"uid":"7f50dad9287d30ea940b","track":{"id":"{id}",+ "uri":"spotify:track:{id}","name":"Song","discNumber":1,+ "duration":{"totalMilliseconds":297090},"playcount":"513599385",+ "contentRating":{"label":"EXPLICIT"},"playability":{"playable":true,"reason":"PLAYABLE"},+ "artists":{"items":[{"uri":"spotify:artist:{id}","profile":{"name":"Artist A"}}]},+ "albumOfTrack":{"uri":"spotify:album:{id}","coverArt":{"sources":[]}}}}]},+ "albums":{"totalCount":5,"items":[{"releases":{"items":[{"id":"{id}",+ "uri":"spotify:album:{id}","name":"Album","type":"ALBUM",+ "date":{"year":2026,"month":6,"day":12,"precision":"DAY"},+ "tracks":{"totalCount":13},"coverArt":{"sources":[]}}]}}]},+ "singles":{"totalCount":25,"items":[]}},+ "relatedContent":{"relatedArtists":{"totalCount":40,"items":[{"id":"{id}",+ "uri":"spotify:artist:{id}","profile":{"name":"Artist B"}}]}}}}}+```++### Other artist operations++| Op | Variables | Returns |+|---|---|---|+| `queryNpvArtist` | `artistUri`, `trackUri`, `contributorsLimit` (10), `contributorsOffset` (0), `enableRelatedVideos` (true), `enableRelatedAudioTracks` (true) | `data.artistUnion {id, uri, profile{name, biography, externalLinks}, stats, visuals.avatarImage, headerImage, onPlatformReputationTrait, goods.concerts}` and `data.trackUnion {creditsTrait.contributors.items[{name, role, roleGroup.name, uri, url}], creditsTrait.sources.items[{name}], canvas, merch, relatedVideos}`. Credits roles are localised strings. |+| `queryTrackArtists` | `trackUri` | `data.trackUnion {uri, artists.items[{uri, profile.name}]}` |+| `queryAlbumMerch` | `uri` (album) | merch only |++## Playlists++### fetchPlaylist++Variables: `uri` (`spotify:playlist:{id}`), `offset` (0), `limit` (25),+`enableWatchFeedEntrypoint` (true), `includeEpisodeContentRatingsV2` (true).++Root `data.playlistV2` (`Playlist` or `NotFound`):++| Path | Content |+|---|---|+| `uri`, `name`, `description` | description may hold HTML links: `<a href=spotify:playlist:{id}>name</a>` |+| `images.items[].sources[] {url, width, height}` | usually one source, size `null`; empty `items` for an empty user playlist |+| `ownerV2.data {__typename:"User", uri, username, name, avatar.sources[]}` | owner |+| `members {totalCount, items[{isOwner, permissionLevel, user.data}]}` | |+| `followers`, `following`, `format` (`""` for user playlists, e.g. `artist-mix-reader`), `revisionId` | |+| `basePermission` (`VIEWER`), `currentUserCapabilities {canView, canEditItems, canEditMetadata, canAdministratePermissions, canCancelMembership, canAbuseReport, canMixPlaylist}` | edit rights |+| `attributes[{key, value}]` | e.g. `primary_color`, `header_image_url_desktop`, `status`, `autoplay` |+| `content {totalCount, pagingInfo{offset, limit}, items[]}` | first page |+| `content.items[] {uid, addedAt.isoString, addedBy, attributes[], itemV2, itemV3}` | |+| `addedBy` | `null` for editorial; `{data:{uri, username, name, avatar}}` on user playlists |+| `itemV2.__typename` / `itemV2.data.__typename` | `TrackResponseWrapper`/`Track` (only kind captured; episodes expected as `EpisodeOrChapterResponseWrapper`/`Episode`, as in `isCurated`) |+| `itemV2.data {uri, name, trackNumber, discNumber, trackDuration.totalMilliseconds, playcount, playability, contentRating, mediaType, artists.items[], albumOfTrack{uri, name, date, artists, coverArt}}` | row |+| `itemV2.data.playlistAudioAttributes {bpm, key{key, mode, camelotKey{value, color}}}` | optional |+| `itemV3.data` | trait form (`identityTrait`, `visualIdentityTrait`, `consumptionExperienceTrait`); duplicate of itemV2, not needed |++`uid` is the per-row id needed to address a row (remove, move, play from row).++### fetchPlaylistContents++Variables: `uri`, `offset`, `limit` (50), `includeEpisodeContentRatingsV2` (true).+Returns `data.playlistV2 {__typename, content}` only, same item shape.+Paging seen: first page `fetchPlaylist(offset 0, limit 25)`, then+`fetchPlaylistContents(offset 25, limit 50)`, next `offset 75`, until+`offset >= content.totalCount`. Note `pagingInfo.limit` echoes the request limit,+not the returned count.++### fetchPlaylistMetadata++Variables: `uri`, `offset` (0), `limit` (100), `enableWatchFeedEntrypoint` (true).+Same header fields as `fetchPlaylist`; `content.items[]` are light:+`{itemV2:{__typename, data:{__typename:"Track", uri, trackDuration.totalMilliseconds}}}`+(no `uid`). `pagingInfo` has only `limit`. Used for whole-playlist duration and+play/queue uri lists. Called repeatedly for library rows; returns `NotFound` for+expired personal mixes.++```json+{"data":{"playlistV2":{"__typename":"Playlist","uri":"spotify:playlist:{id}",+ "name":"Top Hits","description":"The hottest 50.","followers":33718960,"following":false,+ "format":"","revisionId":"AAAA…","basePermission":"VIEWER",+ "currentUserCapabilities":{"canView":true,"canEditItems":false,"canEditMetadata":false},+ "images":{"items":[{"sources":[{"url":"https://i.scdn.co/image/{img}","width":null,"height":null}]}]},+ "ownerV2":{"data":{"__typename":"User","uri":"spotify:user:{user}","username":"{user}",+ "name":"Owner","avatar":{"sources":[]}}},+ "content":{"__typename":"PlaylistItemsPage","totalCount":50,+ "pagingInfo":{"offset":0,"limit":25},+ "items":[{"uid":"654e44597543482f767755","addedAt":{"isoString":"2026-09-04T04:02:23.110Z"},+ "addedBy":null,"itemV2":{"__typename":"TrackResponseWrapper","data":{"__typename":"Track",+ "uri":"spotify:track:{id}","name":"Song","trackNumber":1,"discNumber":1,+ "trackDuration":{"totalMilliseconds":198840},"playcount":"100749741",+ "contentRating":{"label":"NONE"},"playability":{"playable":true,"reason":"PLAYABLE"},+ "artists":{"items":[{"uri":"spotify:artist:{id}","profile":{"name":"Artist"}}]},+ "albumOfTrack":{"uri":"spotify:album:{id}","name":"Album",+ "coverArt":{"sources":[{"url":"…","width":64,"height":64}]}}}}}]}}}}+```++### playlistPermissions++Variables: `uri`. Returns `data.playlistV2 {basePermission, currentUserCapabilities+{canAdministratePermissions, canCancelMembership, canEditItems, canEditMetadata, canView,+grantableLevel[]}, members.items[{isOwner, permissionLevel, user.data{uri, username, name, avatar}}]}`.++### isCurated++Variables: `uris` (string list; tracks, episodes, ads; 1 to ~25 seen).+Returns `data.lookup[]` in request order:+`{"__typename":"TrackResponseWrapper","data":{"__typename":"Track","isCurated":false}}`+(`EpisodeOrChapterResponseWrapper`/`Episode` for episodes). `isCurated` = already saved+somewhere in the user's library (drives the check vs plus icon).++## Batch track lookup (pathfinder v1, unnamed)++`POST https://api-partner.spotify.com/pathfinder/v1/query`, body without+`operationName`: `{"variables":{"uris":[…]},"extensions":{"persistedQuery":{"version":1,+"sha256Hash":"f952da03…4f77"}}}`. Sent without `app-platform`/`spotify-app-version`.+Returns `data.lookupEntities[] {uri, entityTypeTrait.type ("ENTITY_TYPE_TRACK"),+consumptionExperienceTrait.duration{seconds,nanoSeconds}, identityTrait{name,+contentHierarchyParent.uri}, typedEntity.data{uri, name, duration.totalMilliseconds,+playability.playable, relinkingInformation, albumOfTrack{uri, name, coverArt.sources[]},+artists.items[]}}`. Useful to hydrate a list of uris (queue, recently played) in one call.++## REST: extended-metadata++`POST {spclient}/extended-metadata/v0/extended-metadata`+Request headers add `content-type: application/json;charset=UTF-8`, `accept: application/protobuf`.+Request is JSON; response is protobuf (`application/protobuf`, zstd).++Request:++```json+{"entityRequest":[{"entityUri":"spotify:track:{id}",+ "query":[{"extensionKind":178,"etag":""},{"extensionKind":179,"etag":""}]}]}+```++Response (inferred field numbers):++```+BatchedExtensionResponse+ 2: repeated EntityExtensionDataArray // one per extensionKind+ 1: header {1: status(int, 200), 2: cache ttl s (3600), 3: offline ttl s (2592000)}+ 2: extension_kind (int)+ 3: repeated EntityExtensionData+ 1: header {1: status (200 / 404), 2: etag (string), 4: cache ttl, 5: offline ttl}+ 2: entity_uri (string)+ 3: google.protobuf.Any {1: type_url, 2: value} // absent when status 404+```++| Kind | Entities seen | `type_url` (`type.googleapis.com/…`) | Inferred value fields |+|---|---|---|---|+| 178 | track, artist, playlist, list | `spotify.contentagnostic.v2.IdentityTrait` | 1 type label (localised), 2 name, 3 description, 4 parent `{1 name, 2 uri}` (album), 5 repeated contributor `{1 name, 2 uri}` |+| 179 | track, artist, playlist | `…v2.VisualIdentityTrait` | 1 square cover `{1 repeated image {1 {1 url}, 2 size enum}, 2 color set}`; 2 16:9 image; 4 video (canvas url). Size enum: 1 = 64 px, 2 = 300, 3 = 640, 4 = large/640 |+| 182 | track | `…v2.ConsumptionExperienceTrait` | 1 duration `{1 seconds}`, 2 content ratings (packed enum), 4 formats (packed enum) |+| 184 | artist | `…v2.DetailedEvaluationTrait` | not decoded |+| 185 | track, artist | `…v2.OnPlatformReputationTrait` | track: 3 = unix seconds; artist: verification |+| 186 | track | `…v2.CreditsTrait` | 1 repeated contributor `{1 name, 2 role, 3 uri, 4 {1 uri}, 5 url, 6 {1 role group}}` |+| 205 | playlist | `spotify.list.v1.model.Attributes` | 3 name, 4 description, 5 `{1 timestamp}`, 7 owner username, 9 capabilities |+| 220 | track | `…v2.EntityTypeTrait` | 1 type enum (1 = track) |+| 246 | track, episode | `…v2.CurationExperienceTrait` | 1 uri, 2 `{2 {1 playlist uri}}`, 3 `{4 repeated playlist uri}` (where the item is saved) |+| 249 | track, ad | `…v2.ContentExperienceTrait` | 1 enum (1 = music) |+| 22, 80, 164, 270 | track, artist | none | always 404 for this account |++For catalog rows the GraphQL ops already carry everything; extended-metadata is only+needed if the client wants cheap batched name/cover/duration (178 + 179 + 182).++## REST: metadata/4/track++`GET {spclient}/metadata/4/track/{hex}?market=from_token`, `accept: application/json`.+Response JSON, `cache-control: public, max-age=…`, `etag`.++`{hex}` is the 128-bit base62 id as 32 lowercase hex chars. Alphabet+`0-9a-zA-Z` (`0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ`):++```kotlin+const val B62 = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"+fun base62ToHex(id: String): String =+ id.fold(BigInteger.ZERO) { n, c -> n * 62.toBigInteger() + B62.indexOf(c).toBigInteger() }+ .toString(16).padStart(32, '0')+fun hexToBase62(hex: String): String {+ var n = BigInteger(hex, 16); val sb = StringBuilder()+ while (n > BigInteger.ZERO) { val (q, r) = n.divideAndRemainder(62.toBigInteger()); sb.append(B62[r.toInt()]); n = q }+ return sb.reverse().toString().padStart(22, '0')+}+```++Verified on capture: `55vPnuXfuzXNW75JpuSczF` <-> `a734c1d4e4d84c4093c32d5bce9797a3`.++Fields: `gid` (hex), `name`, `number`, `disc_number`, `duration` (ms), `popularity`,+`external_id[{type:"isrc", id}]`, `has_lyrics`, `language_of_performance[]`,+`earliest_live_timestamp`, `artist[{gid, name}]`, `artist_with_role[{artist_gid,+artist_name, role:"ARTIST_ROLE_MAIN_ARTIST"}]`, `album{gid, name, type, label,+date{year,month,day}, artist[], cover_group.image[{file_id, size: SMALL|DEFAULT|LARGE,+width, height}]}`, `canonical_uri`, `original_audio{uuid, format}`, `audio_formats[]`,+`media_type`, `content_authorization_attributes` (opaque hex). Cover url =+`https://i.scdn.co/image/{file_id}`. Note `canonical_uri` may differ from the+requested id (relinking). No audio `file[]` list appeared in this web response.++## REST: artist popular-release segments++`GET {spclient}/playlist/v2/list/popular-release-segments-main-roles/artist_{id}?decorate=revision,length,attributes,timestamp,owner,capabilities`+(`decorate` URL-encoded), `accept: application/json`. Called on the artist page; the+list is the full "Popular" track list (used to play the artist).++```json+{"revision":"AAAA…","length":44,"timestamp":"1792099180000","ownerUsername":"spotify",+ "isUserCreated":false,"abuseReportingEnabled":false,+ "attributes":{"name":"Artist A Popular","collaborative":false,+ "format":"popular-release-segments-main-roles",+ "formatAttributes":[{"key":"reporting.uri","value":"spotify:artist:{id}"},+ {"key":"total_number_of_tracks","value":"44"}]},+ "capabilities":{"canView":true,"canEditItems":false,"canEditMetadata":false},+ "contents":{"pos":0,"truncated":false,+ "items":[{"uri":"spotify:track:{id}","attributes":{"itemId":"XU0dKAQW5IRVSA=="}}]}}+```++All `length` items came in one response (`truncated:false`); only uris, so hydrate with+the v1 batch lookup or extended-metadata.++## Gaps++| Missing | Capture that would answer it |+|---|---|+| Album track paging past 50 (op name/hash, e.g. a `queryAlbumTracks`) | Open an album with > 50 tracks and scroll to the end |+| Full artist discography (Albums / Singles "Show all", e.g. `queryArtistDiscographyAll/Albums/Singles`), "Appears on", related artists page | Artist page, click each "Show all" and scroll |+| Liked Songs listing op (CAPTURE-MAP says `fetchPlaylist` on `collection/tracks`, not present in these captures) | Open Liked Songs and scroll |+| Playlist items that are episodes, local files or unavailable tracks (`playable:false`, other `reason` values, `relinkingInformation` non-null) | Playlist containing a podcast episode, a local file and a region-blocked/removed track |+| `getAlbum` with empty `locale`, other `locale` values; whether `locale` changes text | Same album from `open.spotify.com/album/…` without `/intl-xx/` |+| GraphQL error format (`errors[]`), behaviour on expired token or wrong hash | Replay with an old token / bad hash (not done: offline rule) |+| Pre-release albums (`isPreRelease:true`, `preReleaseV2`) | Artist with an announced pre-save album |+| Extended-metadata kinds 22, 80, 164, 184, 270 payloads (404 or undecoded) | Premium account capture, or same calls on other entity types |diff --git a/docs/api/EXTRAS.md b/docs/api/EXTRAS.mdnew file mode 100644index 00000000..7d9f689d--- /dev/null+++ b/docs/api/EXTRAS.md@@ -0,0 +1,320 @@+# Track extras: lyrics, canvas, colors, recommendations, images++Clean-room notes from Web Player captures (free account, 2026-10-15). Companion to+`CAPTURE-MAP.md`. Ids below are placeholders: `{id}` base62 (22 chars), `{hex}` 32-hex+file id, `{img}` 40-hex image id.++## Common request shape++**GraphQL**: `POST https://api-partner.spotify.com/pathfinder/v2/query`++Headers (names only): `authorization` (Bearer web token), `client-token`, `app-platform`+(`WebPlayer`), `spotify-app-version`, `content-type: application/json;charset=UTF-8`,+`accept`, `accept-language` (drives localized strings and the pickasso locale).++```json+{"variables": {...}, "operationName": "canvas",+ "extensions": {"persistedQuery": {"version": 1, "sha256Hash": "<hash>"}}}+```++Errors come back as HTTP 200 with `data: null` and `errors[]`+(`extensions.classification`, e.g. `ValidationError`).++**spclient REST** (`spclient.wg.spotify.com` or the `{region}-spclient.spotify.com` host from+apresolve): the same headers minus `content-type`.++## Operation table++| operationName | sha256Hash | Trigger |+|---|---|---|+| `canvas` | `575138ab27cd5c1b3e54da54d0a7cc8d85485402de26340c2145f0f6bb5e7a9f` | each new now-playing track |+| `fetchExtractedColors` | `36e90fcaea00d47c695fce31874efeb2519b97d4cd0ee1abfb4f8dc9348596ea` | page headers (playlist, artist, album) |+| `getDynamicColorsByUris` | `f0f112945d6d745bd8ff790317bbf8d310036da75df33130490e9d6dc96c59d9` | now-playing view and lyrics background |+| `internalLinkRecommenderTrack` | `c77098ee9d6ee8ad3eb844938722db60570d040b49f41f5ec6e7be9160a7c86b` | track page, "Recommended" |+| `similarAlbumsBasedOnThisTrack` | `1d1f93a737498adca2c892c73af87fc0b052afe4e1a33c989540c32413dfae17` | track page, similar albums |+| `npvV2TrackSupplementalSections` | `3268e307f08330b620de5c161a03b48acf66ec57164eac446e0653694a485764` | now-playing panel (concerts, merch, videos) |+| `queryNpvArtist` | `e1ae46a21911a3075c1aa29bf09a6c60f9a45b6a2b1132429f10ad06c299b5d7` | now-playing panel, artist card and credits |+| `queryTrackArtists` | `ee2b038198f5e62c679c3996584d9249bbee55fe69fc212271c56492a022c798` | queue view / song menu |+| `decorateQueuedByUsers` | `33fe7085b4a9dde404955eeee4f8f93aa7a8e55028058354bc707727d8a7890d` | queue view ("added by") |+| `centralisedStatePlayerOptions` | `e2dcfcab470854d4d1c7cb1a851438f14fe0a94d57db7f0b9dde492559d5395d` | opening a playable context page |+| `queryAlbumMerch` | `3ef44ed6f17be67299538fe77faffab4075aeaf9e1085f10fc835592266711b5` | album page |++Hashes change when Spotify rebuilds the web player. Treat them as config, not constants.++## Lyrics++`GET https://spclient.wg.spotify.com/color-lyrics/v2/track/{trackId}/image/{coverUrlEncoded}?format=json&vocalRemoval=false&market=from_token`++- `{trackId}`: base62 track id (not the uri).+- `{coverUrlEncoded}`: the 640 px cover URL, fully percent-encoded+ (`https%3A%2F%2Fi.scdn.co%2Fimage%2Fab67616d0000b273{img}`). The cover is used to compute+ `colors`.+- Without `format=json` the server returns protobuf (not captured). Always send it.+- Response: `cache-control: public, max-age=900`. The web player fetches lyrics for the+ current track **and** pre-fetches the next one, even with the lyrics view closed.++```json+{"lyrics": {+ "syncType": "LINE_SYNCED",+ "lines": [+ {"startTimeMs": "11760", "words": "First line", "syllables": [], "endTimeMs": "0", "transliteratedWords": ""},+ {"startTimeMs": "14820", "words": "♪", "syllables": [], "endTimeMs": "0", "transliteratedWords": ""},+ {"startTimeMs": "168140", "words": "", "syllables": [], "endTimeMs": "0", "transliteratedWords": ""}],+ "provider": "MusixMatch", "providerLyricsId": "123", "providerDisplayName": "Musixmatch",+ "syncLyricsUri": "", "isDenseTypeface": false, "alternatives": [],+ "language": "fr", "isRtlLanguage": false, "capStatus": "UNCAPPED",+ "previewLines": [ /* first 5 lines, same shape */ ],+ "translationLanguages": []},+ "colors": {"background": -9472386, "text": -16777216, "highlightText": -1},+ "hasVocalRemoval": false}+```++UI notes:+- `startTimeMs` and `endTimeMs` are **strings**. `endTimeMs` is `"0"` in LINE_SYNCED: a line+ ends where the next line starts. The last line is often empty (end marker), and `♪` marks+ an instrumental gap.+- `syncType`: `LINE_SYNCED` (all captures) or `UNSYNCED` (all `startTimeMs` = `"0"`: show+ as static text). `SYLLABLE_SYNCED` would fill `syllables[]`; it was not seen.+- `colors.*` are signed 32-bit ARGB ints (`-1` = white, `-16777216` = black). In Kotlin,+ `Color(value)` works directly.+- `isRtlLanguage` sets the text direction. Credit `providerDisplayName` under the lyrics.+- `capStatus` probably limits free accounts (e.g. preview lines only). It was always+ `UNCAPPED` here.++## Episode transcripts: timesynced-text-distribution++`GET https://spclient.wg.spotify.com/timesynced-text-distribution/v0/get-timesynced-text/spotify:episode:{id}?start_time_ms=0&end_time_ms=60000`++This is **not** song lyrics. It is a word-level podcast transcript for an episode+**preview window**. The URL is not built by the client: it comes ready-made from gql+`feedBaselineLookup` (home feed preview cards), at+`...data.previewPlayback.audioPreview.transcriptUrl` and `...videoPreview.transcriptUrl`.+The audio preview itself is `previewPlayback.audioPreview.cdnUrl`+(`p.scdn.co/mp3-preview/{40hex}.mp3`). Response `cache-control: max-age=600`.++```json+{"words": [+ {"word": "Hello", "offsets": {"start": "4.480s", "end": "4.920s"}, "speakerId": "1"},+ {"word": "everyone,", "offsets": {"start": "4.920s", "end": "5s"}, "speakerId": "1"}],+ "speakers": {"1": {"id": "1", "displayName": "", "imageUrl": ""}},+ "next": ""}+```++Offsets are protobuf-style duration strings (`"631.68s"`): parse them as seconds. Speaker+names were always empty. `next` was always empty (pagination token).++## Canvas (looping track video)++gql `canvas`, variables `{"trackUri": "spotify:track:{id}"}`.++```json+{"data": {"trackUnion": {"__typename": "Track", "uri": "spotify:track:{id}",+ "canvas": {"fileId": "{hex}", "type": "VIDEO_LOOPING_RANDOM",+ "uri": "spotify:canvas:{id}",+ "url": "https://canvaz.scdn.co/upload/artist/{id}/video/{hex}.cnvs.mp4"}}}}+```++- `canvas: null` means the track has no canvas.+- `canvas.url` is a plain progressive MP4 (portrait, short loop). A client can play it+ directly in ExoPlayer with loop on. This is the simplest path.+- The web player does not fetch `canvaz.scdn.co`. It uses the adaptive pipeline with `fileId`:+ 1. `GET {spclient}/manifests/v9/json/sources/{fileId}/options/supports_drm` (gql headers).+ 2. `GET https://video-cf.spotifycdn.com/segments/v1/origins/{origin}/sources/{fileId}/encodings/{enc}/profiles/{profileId}/inits/mp4?<signed>`+ then `.../profiles/{profileId}/{segmentStartSeconds}.mp4?<signed>`.+- Manifest fields: `contents[0].encoding_id`, `segment_length` (4 s), `end_time_millis`,+ `profiles[]` (`id`, `file_type` mp4/ts/webm, `video_width`/`video_height`, `max_bitrate`),+ `encryption_infos: []` (canvas is unencrypted), `base_urls[]`+ (`video-cf.spotifycdn.com/segments/`, `video-fa.scdn.co/segments/`),+ `initialization_template` and `segment_template` (relative, with `{{profile_id}}`,+ `{{file_type}}` and `{{segment_timestamp}}`, already carrying signed query params+ `fauth`, `token_ak` and `token_cf`). Segment requests need no auth header. Segments are+ immutable (`max-age=315360000`).+- Canvas profiles are portrait: mp4 ids 9→4 = 180x320 … 1080x1920. The web player picked+ profile 6 (480x854) first, then 4 (1080x1920).+- Canvas also appears inline in `queryNpvArtist.trackUnion.canvas` and in+ `feedBaselineLookup` items, with an extra `thumbnail.sources[]` (`ab67ba69…`, 288x512 /+ 144x256).++### The other video-cf traffic: music-video prefetch (not canvas)++There are two `origins` ids in segment URLs. Canvas uses one; music videos use another.+Music video segments are fetched after `GET track-playback/v1/media/spotify:track:{id}?manifestFileFormat=…`.+For a track with a music video, the media response has a top-level+`video_version_uri: "spotify:track:{videoTrackId}"`, plus a second `media` entry for that+uri with `item.track_type: "VIDEO"`, `item.video_id: "{hex}"` and+`item.manifest.manifest_ids_video[].file_id`. The player then fetches the+`manifests/v9` for that id and **prefetches only the first segment** (init + `0.mp4` of+video profile 0 at 1080 and of an audio profile), so "Switch to video" starts at once.+This manifest has `encryption_infos` (Widevine/PlayReady `cenc/ctr`,+`license_server_endpoint: /widevine-license/v1/video/license`), 4x4 `background_profiles`,+`subtitle_template` (webvtt) and spritemaps. It needs DRM, so it is out of scope for a simple+client. To offer "has video", check `video_version_uri != null`.++## Colors++**fetchExtractedColors**: variables `{"imageUris": ["https://i.scdn.co/image/{img}", ...]}`+(pickasso URLs work too). Used for page header gradients.++```json+{"data": {"extractedColors": [{"__typename": "ExtractedColors",+ "colorDark": {"hex": "#505068", "isFallback": false},+ "colorLight": {"hex": "#737396", "isFallback": false},+ "colorRaw": {"hex": "#505068", "isFallback": false}}]}}+```+The output order follows the input order. Use `colorDark.hex` for a dark-theme header.++**getDynamicColorsByUris**: same variables (one 640 cover `ab67616d0000b273…`, or a+`ab67616d0000aa54…` variant). This is the full now-playing palette:++```+data.dynamicColors[].bestFit "DARK" | "LIGHT"+data.dynamicColors[].{dark|light}.encoreBaseSetTextColor {red,green,blue,alpha}+data.dynamicColors[].{dark|light}.{minContrast|highContrast|higherContrast}+ .backgroundBase / .backgroundTintedBase / .textBase / .textSubdued / .textBrightAccent+```+The colors are 0..255 RGBA objects. Most of the time `dark.highContrast.backgroundBase` is+the now-playing background. Lyrics carry their own `colors` (see above).++Many responses also embed colors in `coverArt.extractedColors.colorDark.hex`. Prefer those+when they are present, to save a call.++## Recommendations and now-playing sections++**internalLinkRecommenderTrack**: `{"uri": "spotify:track:{id}", "limit": 5}` → recommended tracks.+```+data.seoRecommendedTrack.items[].data: { uri, id, name, playcount (string),+ duration.totalMilliseconds, contentRating.label ("EXPLICIT"|"NONE"), playability.playable,+ artists.items[].{uri, profile.name}, albumOfTrack.{uri, coverArt.sources[] (300 px)} }+```++**similarAlbumsBasedOnThisTrack**: `{"uri": "spotify:track:{id}", "limit": 50, "albumsOnly": true}`.+```+data.seoRecommendedTrackAlbum.totalCount+data.seoRecommendedTrackAlbum.items[].data: { uri, name, type ("ALBUM"|"SINGLE"|…),+ date.{year,isoString,precision}, coverArt.sources[], artists.items[].{uri,profile.name},+ playability.playable, sharingInfo.shareUrl }+```++**npvV2TrackSupplementalSections**: `{"trackUri": "spotify:track:{id}", "enableRelatedVideos": true}`.+```+data.trackUnion.artists.items[].{id, goods.concerts.{totalCount, items[].data:+ {uri, title, startDateIsoString, location.{name, city}}}}+data.trackUnion.merch.items[].{uri, nameV2, description, price, url, image.sources[].url}+data.trackUnion.relatedVideos.items[].trackOfVideo.data.uri (uri only here)+```+Empty sections come back as `items: []`.++**queryNpvArtist**: variables+`{"artistUri", "trackUri", "contributorsLimit": 10, "contributorsOffset": 0, "enableRelatedVideos": true, "enableRelatedAudioTracks": true}`.+This is the "About the artist" card plus credits:+```+data.artistUnion: { uri, id, profile.name, profile.biography.{text,type},+ profile.externalLinks.items[].{name,url}, stats.{followers, monthlyListeners, worldRank,+ topCities.items[].{city,country,region,numberOfListeners}},+ visuals.avatarImage.sources[], visuals.gallery.items[].sources[], headerImage.data.sources[],+ onPlatformReputationTrait.verification.isVerified, goods.concerts }+data.trackUnion: { canvas, merch, creditsTrait.contributors.items[].{name, role, roleGroup.name, uri},+ creditsTrait.sources.items[].name (label/distributor),+ relatedVideos.items[].{uri "spotify:video:…", trackOfVideo.data.{uri,name,artists,+ albumOfTrack.coverArt.sources[] (16:9 ab6742d3…), associationsV3.audioAssociations.items[].trackAudio._uri}},+ associationsV3.unmappedVideoTrackAssociations }+```+The biography text can contain HTML links. `role` strings follow the UI language.++**queryTrackArtists**: `{"trackUri"}` → `data.trackUnion.artists.items[].{uri, profile.name}`+(drives "Go to artist" when there are several artists).++**decorateQueuedByUsers**: `{"userUris": ["spotify:user:{user}"]}` →+`data.users[].{uri, id, name, username, avatar, socialHandle}` (queue "added by").++**centralisedStatePlayerOptions**: variables+`{"uri": "<context uri>", "deviceInfo": {"deviceId", "deviceType": "computer", "clientId", "clientVersion", "productId": "1"}}`.+`deviceInfo` comes from the session (never hard-code it).+```json+{"data": {"playerOptions": {"__typename": "PlayerOptions", "shufflingContext": false,+ "modes": [{"modeKey": "context_enhancement", "modeValue": "NONE"},+ {"modeKey": "media", "modeValue": "audio"}, {"modeKey": "jam", "modeValue": "off"}],+ "restrictions": {"disallowTogglingShuffleReasons": [],+ "disallowSettingModes": [+ {"modeKey": "context_enhancement", "modeRestrictions": [+ {"modeValue": "NONE", "reasons": ["already_set"]},+ {"modeValue": "RECOMMENDATION", "reasons": ["not_supported_by_content_type"]}]},+ {"modeKey": "media", "modeRestrictions": [+ {"modeValue": "video", "reasons": ["not_playing_track"]}]}]}}}}+```+`context_enhancement = RECOMMENDATION` is Smart Shuffle / "enhance". It is allowed (empty+`reasons`) only on some playlists. Only ARTIST, ALBUM, PLAYLIST, PLAYLIST_V2, SHOW and+COLLECTION uris are valid. A `spotify:list:…` uri returns a `ValidationError`.++**queryAlbumMerch**: `{"uri": "spotify:album:{id}"}` →+`data.albumUnion.{name, merch.totalCount, merch.items[].{uri, nameV2, description, price, url, image.sources[].url}}`.+`price` is preformatted and localized (it can be `""`). `url` goes to the external store.++### Radio and mixes++No song-radio request was captured (the "Go to song radio" menu entry exists in the+locale strings, but it was not clicked). What was seen:+- An artist radio is a normal editorial **playlist** (`spotify:playlist:37i9dQZF1E4…`,+ name "Radio {artist}", owner Spotify), listed in `queryArtistOverview` related playlists.+ It plays like any playlist.+- `inspiredby-mix` is a playlist `format` value in `home` / search results (a "mix" built+ around an artist).+- No `radio-apollo`, `inspiredby-mix` endpoint or `spotify:station:` uri was observed.++## Images++### i.scdn.co++`https://i.scdn.co/image/{40-hex}` = an 8-hex **type** prefix, an 8-hex **size** code,+then a 24-hex **hash** shared across sizes. To change the size, swap the size code. The+`image-cdn-fa.spotifycdn.com` and `image-cdn-ak.spotifycdn.com` hosts serve the same ids.++| Kind | Type prefix | Size codes |+|---|---|---|+| Album cover | `ab67616d` | `00004851` 64, `00001e02` 300, `0000b273` 640 (also `0000aa54`, size unknown) |+| Artist avatar | `ab676161` | `0000f178` 160, `00005174` 320, `0000e5eb` 640 |+| Artist gallery | `ab676167` | `0000ecd4` 640 |+| Artist header | `ab676186` | `00000194` 1494x640, `0000101f`/`00001016`/`00001667`/`00009d80`/`0000eab1` (header variants, sizes unknown) |+| Playlist (editorial / uploaded) | `ab67706f` / `ab67706c` | `00000002` / `0000da84`, `0000d72c` (no size given, about 300-640) |+| Show / episode | `ab676563` | `0000f68d` 64, `00005f1f` 300, `0000ba8a` 640 |+| Episode (other) | `ab676663` | `0000703b` 64, `0000db5b` 300, `000022a8` 640 |+| User avatar | `ab677570` | `00003b82` 64, `0000ee85` 300 |+| Music video thumb (16:9) | `ab6742d3` | `000052b7` 640x360, `000053b7` 1280x720 |+| Video episode thumb | `ab6772ab` | `0000e0e7` 640x360, `000030ae` 1280x720 |+| Canvas thumbnail | `ab67ba69` | `00002ea6` 144x256, `00002e9f` 288x512 |+| Merch | `ab676d63` | `000076a0`, `0000e1f0` 300 |++Responses list `sources[]` with `width`/`height` (or `maxWidth`/`maxHeight`, or `null`).+Choose from those first, and fall back to swapping the size code.++### mosaic.scdn.co (user playlists without an uploaded cover)++`https://mosaic.scdn.co/{60|300|640}/{img1}{img2}{img3}{img4}`: four album-cover ids+(always the `ab67616d00001e02…` 300 px variant) concatenated with no separator. Change only+the leading size.++### pickasso.spotifycdn.com (generated covers)++`https://pickasso.spotifycdn.com/image/ab67c0de{size}/dt/v1/img/{kind}/{path}/{locale}`+- `{kind}/{path}`: `radio/artist/{artistId}`, `artistmix/{artistId}`, `thisisv3/{id}`,+ `topic/{topic}/{id}`, `dw/cover` (Discover Weekly).+- `{size}`: `0000f00d` 64, `0000cafe` 640, `0000bada` 1280, `0000deef` default (sent+ with `height: null`).+- `{locale}`: the UI language (`fr`, `en`), because the title is drawn into the image.++Other static images: `misc.scdn.co/liked-songs/liked-songs-{64|300}.{png|jpg}`.++## Gaps++- **Lyrics 404 / no lyrics**: every captured lyrics call returned 200 LINE_SYNCED. Expected+ behaviour: 404 for tracks without lyrics (hide the lyrics button), but this is not verified.+ No `UNSYNCED` or `SYLLABLE_SYNCED` sample, and no free-tier `capStatus` other than `UNCAPPED`.+- Lyrics protobuf form (without `format=json`) was not captured. `vocalRemoval=true` was not seen.+- Size of `ab67616d0000aa54` and the artist-header `ab676186` variants is unknown.+- **Song radio**: no request captured. The uri and endpoint used by "Go to song radio" are+ unknown and need a new capture (`__mark__/song-radio`).+- Canvas `type` values other than `VIDEO_LOOPING_RANDOM` (e.g. `VIDEO_LOOPING`, `IMAGE`)+ were not seen. Whether `canvaz.scdn.co` URLs need auth is not tested (offline).+- Music video playback (beyond the prefetch) and the video license flow were not captured.+- `timesynced-text` `next` pagination and speaker names were always empty.+- The `queryNpvArtist` contributors pagination beyond 10 was not exercised.diff --git a/docs/api/LIBRARY.md b/docs/api/LIBRARY.mdnew file mode 100644index 00000000..a5dde3e5--- /dev/null+++ b/docs/api/LIBRARY.md@@ -0,0 +1,489 @@+# Library and playlists (Web Player)++Clean-room notes from network captures of open.spotify.com (free account, 2026-10-15,+sessions `04-playlists`, `05-playlist-edit`, `06-likes`, plus the same calls seen in other+sessions). Nothing here is copied from Spotify code; it only describes what goes over the+wire. Placeholders: `{user}` account username, `{id}` base62 id, `{likedId}` the id of the+account's Liked Songs playlist, `{uuid}` a random client UUID, `{rev}` a playlist revision.+See [CAPTURE-MAP.md](CAPTURE-MAP.md) for the session setup (tokens, access points, dealer).++## Common request shape++### GraphQL (pathfinder)++`POST https://api-partner.spotify.com/pathfinder/v2/query`++Request headers (names only): `accept`, `accept-language`, `app-platform` (`WebPlayer`),+`authorization` (`Bearer` web token), `client-token`, `content-type` (JSON),+`spotify-app-version`, plus the browser's `origin`, `referer`, `user-agent`, `sec-*`.++```json+{"variables": {...}, "operationName": "<name>",+ "extensions": {"persistedQuery": {"version": 1, "sha256Hash": "<hash>"}}}+```++Response is `{"data": {...}}`. Errors were not captured; every call in the sessions+returned HTTP 200. The hash identifies a persisted query and changes when Spotify ships+a new web build, so keep hashes in one table that can be updated without code changes.++| operationName | sha256Hash |+|---|---|+| `profileAttributes` | `08ffb4730af3746e04a8301396f20875dbbce10c75243803091a9274eacc8ac0` |+| `accountAttributes` | `d48062d0df0a256ff78ed9e232b83d238dcd710b371efd304b0e178b62595582` |+| `libraryV3` | `390c78e5b951029bad359785e69b07b536a509c581cbcd0aded5e5067f187455` |+| `areEntitiesInLibrary` | `134337999233cc6fdd6b1e6dbf94841409f04a946c5c7b744b09ba0dfe5a85ed` |+| `isCurated` | `e4ed1f91a2cc5415befedb85acf8671dc1a4bf3ca1a5b945a6386101a22e28a6` |+| `editablePlaylists` | `d5c4b8096437dcc2ac9528c91dfcd299e35b747cda2f8f75d28f41f49c5092ba` |+| `addToLibrary` | `896ebcb47815681340860d121cb5d494e157e2a78d3950385cd54e0393c67148` |+| `removeFromLibrary` | `896ebcb47815681340860d121cb5d494e157e2a78d3950385cd54e0393c67148` (same document as `addToLibrary`) |+| `applyCurations` | `05b739a3a73091c213385233b9d3ed8a857c2ca29d2eebadb3d04ed12e288697` |+| `addToPlaylist` | `b907ad6b088d5bf7680fa81198996d58398c2d55dfcdf59fcc959e0be98a418a` |+| `fetchPlaylist`, `fetchPlaylistContents`, `fetchPlaylistMetadata` | `21ea11a6ac75a5f3e01fd365d29c18e0a4a8b7dc09f89bbb5d73910190c6acaf` (one document, three operations) |+| `playlistPermissions` | `e43d1d35f231cf289c23c9d9c489f4a4f502e4eda09839c530608f107b6556b8` |+| `lookupChildEntities` | `91ce02e32b19123de231dc8de91fe4b9ab84eca087d4c015549308d77fbb6d10` |++### spclient REST++Host `spclient.wg.spotify.com` (the Web Player also uses the `{region}-spclient` host from+`apresolve`). Request headers (names only): `accept` (`application/json`),+`accept-language`, `app-platform`, `authorization`, `client-token`, `spotify-app-version`,+and on POST `content-type` (`application/json;charset=UTF-8` for playlist calls,+`application/json` for collection calls). All bodies below are JSON; nothing in this area+used protobuf over HTTP. Only the dealer pushes are protobuf.++## Account++### profileAttributes++`variables: {}`. Fields used: `data.me.profile.username` (this is `{user}` for the+spclient URLs), `uri` (`spotify:user:{user}`), `name` (display name), `avatar`.++```json+{"data":{"me":{"profile":{"accountId":"…","avatar":null,"avatarBackgroundColor":1697420,+ "name":"…","socialHandle":null,"uri":"spotify:user:{user}","username":"{user}"}}}}+```++### accountAttributes++`variables: {}`. Fields used: `data.me.account.product` (`FREE`),+`attributes.catalogue` (`free`), `attributes.ads` (true), `attributes.onDemand`,+`country` (two letters), `features.personalizedRecommendations`,+`attributes.hasPodcastsAvailable`, `attributes.filterExplicitContent`.++```json+{"data":{"me":{"account":{"attributes":{"ads":true,"catalogue":"free","onDemand":true,+ "hasPodcastsAvailable":true,"filterExplicitContent":null,…},+ "country":"CH","features":{"personalizedRecommendations":"PERMITTED"},"product":"FREE"}}}}+```++## Reading the library++### libraryV3 (Your Library list)++Called on every page load and again after each library change (like, save, follow,+create, rename). Only the default request was captured:++```json+{"order": null, "textFilter": "", "features": ["LIKED_SONGS","YOUR_EPISODES_V2",+ "PRERELEASES","PRERELEASES_V2","CLIPS","EVENTS"], "limit": 50, "offset": 0,+ "flatten": false, "expandedFolders": [], "folderUri": null,+ "includeFoldersWhenFlattening": true}+```++Paging: `offset`/`limit`, stop when `offset >= totalCount`. Text search: `textFilter`.+Folders: `folderUri` opens one folder, `expandedFolders` lists folder URIs shown inline,+`flatten` lists everything without folders. The account had no folders, so these were+always the defaults (see Gaps).++Response `data.me.libraryV3` (`__typename: LibraryPage`):++| Field | Meaning |+|---|---|+| `totalCount`, `pagingInfo {limit, offset}` | paging |+| `availableFilters[] {id, name}` | ids seen: `Playlists`, `Artists`, `Albums` (only types present in the library are offered; `name` is localized) |+| `availableSortOrders[] {id, name}` | ids seen: `Recents`, `Recently Added`, `Alphabetical`, `Creator` |+| `selectedFilters[]`, `selectedSortOrder {id, name}` | current state (default `Recents`) |+| `breadcrumbs[]` | folder path when inside a folder |+| `items[]` | `{addedAt {isoString}, depth, item, pinnable, pinned, playedAt {isoString}\|null}` |++`item` is a wrapper with `__typename`, `_uri` and `data`:++| `item.__typename` | `data` fields used |+|---|---|+| `LibraryPseudoPlaylistResponseWrapper` (`spotify:collection:tracks`) | `name`, `count` (number of liked tracks), `image.sources[]` |+| `PlaylistResponseWrapper` | `name`, `description`, `uri`, `format`, `images.items[].sources[]`, `ownerV2.data {name, username, uri}`, `currentUserCapabilities {canEditItems, canView}`, `revisionId`, `attributes[] {key, value}` |+| `AlbumResponseWrapper` | `name`, `uri`, `type` (`ALBUM`, `SINGLE`…), `artists.items[] {profile.name, uri}`, `coverArt.sources[]`, `date {isoString, precision}`, `playability {playable, reason}` |+| `ArtistResponseWrapper` | `profile.name`, `uri`, `visuals.avatarImage.sources[]` |++Image `sources[]` are `{url, width, height}` (width/height may be null). Most entries also+carry `extractedColors.colorDark.hex`.++```json+{"addedAt":{"isoString":"2026-10-15T21:14:42.278Z"},"depth":0,"pinnable":true,"pinned":false,+ "playedAt":null,"item":{"__typename":"PlaylistResponseWrapper","_uri":"spotify:playlist:{id}",+ "data":{"__typename":"Playlist","name":"Myspoti capture test","description":"","format":"",+ "currentUserCapabilities":{"canEditItems":true,"canView":true},+ "images":{"items":[{"sources":[{"url":"https://i.scdn.co/image/…","width":null,"height":null}]}]},+ "ownerV2":{"data":{"__typename":"User","name":"…","uri":"spotify:user:{user}","username":"{user}"}},+ "revisionId":"AAAAA8Zc…","uri":"spotify:playlist:{id}"}}}+```++The Liked Songs entry is always first and `pinned: true`.++### playlist/v2/user/{user}/rootlist (followed and own playlists)++`GET https://spclient.wg.spotify.com/playlist/v2/user/{user}/rootlist?decorate=revision,length,attributes,timestamp,owner,capabilities&bustCache={ms}`++With `accept: application/json` the answer is JSON, not protobuf. After a change the+Web Player re-reads it with `&revision={n},{hash}` instead of `bustCache` (see Revisions).++```json+{"revision":"AAAAA6N1…","length":1,"attributes":{},"timestamp":"1792098820089",+ "contents":{"pos":0,"truncated":false,+ "items":[{"uri":"spotify:playlist:{id}","attributes":{"timestamp":"1792098882278","public":true}}],+ "metaItems":[{"revision":"AAAAAcQB…","length":0,"timestamp":"1792098882241",+ "ownerUsername":"{user}","attributes":{"name":"Ma playlist n° 2","description":"…",+ "format":"…","formatAttributes":[{"key":"…","value":"…"}],"pictureSize":[…]},+ "capabilities":{"canView":true,"canEditItems":true,"canEditMetadata":true,+ "canAdministratePermissions":true,"canDelete":…,"listAttributeCapabilities":{…},…}}]}}+```++`items[i]` and `metaItems[i]` match by index. An empty rootlist has `length: 0` and no+`items`. Only playlists live here; albums and artists come from the collection+(`libraryV3`). Folders were not present (see Gaps).++### areEntitiesInLibrary++`variables: {"uris": ["spotify:track:{id}", "spotify:album:{id}", "spotify:artist:{id}", "spotify:show:{id}", "spotify:episode:{id}", …]}`+(mixed types, up to about 30 per call).++Response `data.lookup[]`, same order as `uris`:++```json+{"data":{"lookup":[{"__typename":"TrackResponseWrapper","data":{"__typename":"Track","saved":false}},+ {"__typename":"AlbumResponseWrapper","data":{"__typename":"Album","saved":false}},+ {"__typename":"ArtistResponseWrapper","data":{"__typename":"Artist","saved":false}},+ {"__typename":"PodcastOrAudiobookResponseWrapper","data":{"__typename":"Audiobook","saved":false}}]}}+```++Use `saved` for the album Save button and the artist Follow button. For tracks the heart+follows `isCurated` (next section); `saved` never came back true in the captures.++### isCurated (track heart)++`variables: {"uris": ["spotify:track:{id}", …]}` (also sent with episode URIs).+Response `data.lookup[].data.isCurated` (bool), same order. True means the track is in+Liked Songs (seen true for the liked track, false after unliking).++### collection/v2/contains++`POST https://spclient.wg.spotify.com/collection/v2/contains?market=from_token`++```json+{"username":"{user}","set":"artistban","items":[{"uri":"spotify:artist:{id}"},{"uri":"spotify:artist:{id}"}]}+```+```json+{"found":[false,false]}+```++Sets seen: `artistban` (artist hidden by "don't play this artist", checked for every+artist on screen) and `ignoreinrecs` (track excluded from taste profile, checked for the+track whose menu is open). This endpoint was not used for likes or saves.++### editablePlaylists (the "Add to playlist" / heart sheet)++`variables: {"offset":0,"limit":50,"textFilter":"","uris":["spotify:track:{id}"]}`++Response `data.me.editablePlaylists` (`EditablePlaylistPage`): `totalCount`,+`pagingInfo`, `items[] {curates, pinned, item}`. `item` uses the same wrappers as+`libraryV3` (`LibraryPseudoPlaylistResponseWrapper` for Liked Songs, then+`PlaylistResponseWrapper` with `name`, `uri`, `images`). `curates` is true when the+given track is already in that list. Only playlists the user can edit are listed.++```json+{"data":{"me":{"editablePlaylists":{"__typename":"EditablePlaylistPage","totalCount":2,+ "pagingInfo":{"limit":50,"offset":0},"items":[+ {"curates":true,"pinned":true,"item":{"__typename":"LibraryPseudoPlaylistResponseWrapper",+ "_uri":"spotify:collection:tracks","data":{"name":"…","uri":"spotify:collection:tracks","image":{…}}}},+ {"curates":false,"pinned":false,"item":{"__typename":"PlaylistResponseWrapper",+ "_uri":"spotify:playlist:{id}","data":{"name":"Myspoti capture test","uri":"spotify:playlist:{id}","images":{…}}}}]}}}}+```++### Liked Songs++The Liked Songs page (`/collection/tracks`) is now a real playlist owned by the user:+`spotify:playlist:{likedId}` with `format: "liked-songs"`. The id is per account+(base62, in the `37i9dQZF1F…` range of Spotify-generated ids). Its tracks load with the+normal playlist operations:++- `fetchPlaylist` `{"uri":"spotify:playlist:{likedId}","offset":0,"limit":25,"enableWatchFeedEntrypoint":true,"includeEpisodeContentRatingsV2":true}`+- `fetchPlaylistContents` `{"uri":…,"offset":25,"limit":50,"includeEpisodeContentRatingsV2":true}` for the next pages+- `playlistPermissions` `{"uri":…}` (Liked Songs: `basePermission: CONTRIBUTOR`, `canEditItems: true`, `canEditMetadata: false`)++`fetchPlaylist` response `data.playlistV2`: `name`, `format`, `ownerV2`, `revisionId`,+`images`, `currentUserCapabilities`, `content {totalCount, pagingInfo, items[]}`.+Each item: `uid` (hex string, identifies the row), `addedAt.isoString`, `addedBy`,+`itemV2.data` (Track: `uri`, `name`, `artists.items[]`, `albumOfTrack {uri, name, coverArt}`,+`trackDuration.totalMilliseconds`, `playability`, `contentRating.label`), `itemV3`+(new trait-based form of the same entity).++`{likedId}` also appears in the answer of `POST spclient/extended-metadata/v0/extended-metadata`+with `extensionKind: 246` (`spotify.contentagnostic.v2.CurationExperienceTrait`), the first+extension answer after the id is already known (see "Finding the Liked Songs id"). Decoded+protobuf of that extension (from a track request in another session):++```+1: "spotify:track:{id}"+2 { 2 { 1: "spotify:playlist:{likedId}" } } default curation target = Liked Songs+3 { 4 { 1: "spotify:playlist:…" 1: "spotify:playlist:…" } } other targets+```++The same `{likedId}` is used as `contextUri` by `applyCurations` and in dealer pushes.+`libraryV3` and `editablePlaylists` still name it `spotify:collection:tracks`. Cache+`{likedId}` once found.++### Finding the Liked Songs id++Checked on the cold start capture `01-login` (login, then first load of the Web Player).++- First occurrence on the wire is the request of `lookupChildEntities`+ (`variables.uris: ["spotify:playlist:{likedId}"]`). The client already had the id when it+ sent that request, so the source is not in the capture. The response repeats it at+ `data.lookupEntities[0].uri`. No earlier request or response carries it, in base62, hex,+ raw 16-byte gid or base64 form. Dealer frames and navigation records do not either.+- Not present in `profileAttributes`, `accountAttributes`, `libraryV3` (it names Liked Songs+ `spotify:collection:tracks`), `home`, `feedBaselineLookup`, the rootlist, or the HTML pages.+- The first answer with it is `extended-metadata` (`extensionKind 246`), about 50 ms later.+ There it is in the other-targets list (CurationExperienceTrait field 3, `4 { 1 }`). That+ request was for episodes, and their default target is a different playlist, so do not+ assume the default is Liked Songs.+- Not captured: the body of `POST accounts.spotify.com/login/code/verify` (empty in the file)+ and about 90 static or redirect responses with no stored body. The true source is one of+ those, or browser storage, which the wire capture cannot show.++Fallback sources, in order:++1. `{likedId}` saved from an earlier session of the same account.+2. `extended-metadata` `extensionKind 246` for any track or episode (default target or+ other targets, see the decode above).+3. A dealer push on `hm://playlist/v2/playlist/{likedId}` (payload field 1), after the first+ like change.++## Editing the library++All mutations answered HTTP 200 with an empty typed payload. The UI then re-ran+`libraryV3` and relied on dealer pushes for the rest.++### addToLibrary (like a track, save an album, follow an artist)++```json+{"variables":{"libraryItemUris":["spotify:track:{id}"],"interactionId":"{uuid}"},+ "operationName":"addToLibrary","extensions":{…}}+```+`interactionId` is a fresh UUID (sent as `null` from some buttons). The same call was+used for `spotify:track:`, `spotify:album:` and `spotify:artist:`.++Response: `{"data":{"addLibraryItems":{"__typename":"AddLibraryItemsResponse"}}}`++### removeFromLibrary (unsave album, unfollow artist, unlike from the player bar)++```json+{"variables":{"libraryItemUris":["spotify:album:{id}"]},"operationName":"removeFromLibrary",…}+```+Response: `{"data":{"removeLibraryItems":{"__typename":"RemoveLibraryItemsResponse"}}}`.+Also seen for `spotify:track:` (unlike from the now-playing heart, session 08).++### applyCurations (unlike from a track row)++Clicking the filled heart on a row opens the sheet (`editablePlaylists`), unticking+Liked Songs sends:++```json+{"variables":{"input":{"itemUris":["spotify:track:{id}"],+ "curations":[{"contextUri":"spotify:playlist:{likedId}","curationType":"UNCURATE"}]}},+ "operationName":"applyCurations",…}+```+```json+{"data":{"applyCurations":[{"__typename":"TrackResponseWrapper","data":{"__typename":"Track","isCurated":false}}]}}+```+Only `UNCURATE` was captured. Several `curations` entries (one per playlist ticked or+unticked) are allowed by the shape. For a simple unlike, `removeFromLibrary` with the+track URI does the same job.++## Editing playlists++### Revisions++A revision is base64 of 24 bytes: 4-byte big-endian counter then a 20-byte hash.+Example `AAAAAU2+Oz2u…` = counter 1, hash `4dbe3b3d…`. The `revision=` query parameter+uses the decoded form `{counter},{hash hex}`.++Change responses share one shape:++```json+{"revision":"{rev}","syncResult":{"fromRevision":"{rev}","toRevision":"{rev}"},+ "resultingRevisions":["{rev}"],"multipleHeads":false,"changesRequireResync":false}+```+`playlist/{id}/changes` also returns `capabilities` (same object as in rootlist+`metaItems`).++### Create a playlist++1. `POST https://spclient.wg.spotify.com/playlist/v2/playlist`+ ```json+ {"ops":[{"kind":"UPDATE_LIST_ATTRIBUTES",+ "updateListAttributes":{"newAttributes":{"values":{"name":"Ma playlist n° 2"}}}}]}+ ```+ Response: `{"uri":"spotify:playlist:{id}","revision":"{rev}"}`+2. `POST https://spclient.wg.spotify.com/playlist/v2/user/{user}/rootlist/changes` (ADD below,+ `changesRequireResync: true` in this case)+3. `GET rootlist?…&revision={n},{hash}`, then `libraryV3`, `playlistPermissions`,+ `fetchPlaylist` on the new URI.++The default name is chosen by the client (localized "My Playlist #N").++### Rename (and other list attributes)++`POST https://spclient.wg.spotify.com/playlist/v2/playlist/{id}/changes`++```json+{"deltas":[{"ops":[{"kind":"UPDATE_LIST_ATTRIBUTES",+ "updateListAttributes":{"newAttributes":{"values":{"name":"Myspoti capture test"}}}}],+ "info":{"source":{"client":"WEBPLAYER"}}}]}+```+No base revision was sent. The UI then re-ran `fetchPlaylist` and `libraryV3`.+Description is presumably `values.description` (not captured).++### Follow / unfollow a playlist (rootlist changes)++`POST https://spclient.wg.spotify.com/playlist/v2/user/{user}/rootlist/changes`++Follow (also used after create):+```json+{"deltas":[{"ops":[{"kind":"ADD","add":{"items":[{"uri":"spotify:playlist:{id}",+ "attributes":{"timestamp":"1792098815150"}}],"addFirst":true}}],+ "info":{"source":{"client":"WEBPLAYER"}}}]}+```+`timestamp` is the client time in ms, as a string.++Unfollow:+```json+{"deltas":[{"ops":[{"kind":"REM","rem":{"items":[{"uri":"spotify:playlist:{id}"}],+ "itemsAsKey":true}}],"info":{"source":{"client":"WEBPLAYER"}}}]}+```+`itemsAsKey: true` removes by URI, no index needed. After each call: `GET rootlist`+with the new revision, then `libraryV3` twice.++### addToPlaylist++```json+{"variables":{"playlistUri":"spotify:playlist:{id}","playlistItemUris":["spotify:track:{id}"],+ "newPosition":{"moveType":"BOTTOM_OF_PLAYLIST","fromUid":null},"interactionId":"{uuid}"},+ "operationName":"addToPlaylist",…}+```+Response: `{"data":{"addItemsToPlaylist":{"__typename":"AddItemsToPlaylistPayload"}}}`.+Only `BOTTOM_OF_PLAYLIST` was seen; `fromUid` suggests other move types positioned+relative to a row `uid` (not captured). The UI then re-ran `fetchPlaylistMetadata`.++### playlistextender/extendp (Recommended songs under an own playlist)++`POST https://spclient.wg.spotify.com/playlistextender/extendp/`++```json+{"playlistURI":"spotify:playlist:{id}","trackSkipIDs":[],"numResults":20}+```+Response:+```json+{"recommendedTracks":[{"id":"6U9VpmP3dEinuezxCJ2Zg9","originalId":"spotify:track:6U9VpmP3dEinuezxCJ2Zg9",+ "name":"Ain't In LA","artists":[{"id":"2qanRMyA5bNuTvz1dK45OP","name":"ADÉLA"}],+ "album":{"id":"2yDFVH9CeOHt0sc9eI0aBs","name":"PRIMA","imageUrl":"https://i.scdn.co/image/…","largeImageUrl":"https://i.scdn.co/image/…"},+ "duration":184927,"explicit":true,"popularity":91,"score":98.0,"contentRating":[]}, …],+ "request":{"playlistURI":"spotify:user:{user}:playlist:{id}","trackIDs":[],"artistIDs":[],…},+ "details":{"playlistLoad":8.0,"totalTime":43.0}}+```+`trackSkipIDs` presumably holds ids already shown or dismissed (for "Refresh").+Adding one of them uses `addToPlaylist`.++## Dealer pushes++On the dealer WebSocket (see CAPTURE-MAP) each message is+`{"type":"message","uri":"hm://…","headers":{…},"payloads":["<base64 or text>"]}`.+They arrived before the HTTP response of the mutation that caused them, and also come+from changes made on other devices, so use them to refresh caches.++### Collection (likes, saved albums, followed artists)++| uri | Content-Type | payload |+|---|---|---|+| `hm://collection/collection/{user}` | `application/octet-stream` | protobuf, tracks and albums |+| `hm://collection/collection/{user}/json` | `text/plain` | JSON, same change |+| `hm://collection/artist/{user}` | `application/octet-stream` | protobuf, artists |+| `hm://collection/artist/{user}/json` | `text/plain` | JSON, same change |++Headers: `MC-ETag` (new collection version), `Collection-Source-Revision` (previous one),+sometimes `Collection-Update-Id`.++JSON form (easiest to use):+```json+{"items":[{"type":"track","unheard":false,"addedAt":1792099111,"removed":false,+ "identifier":"4EoJ151oQ5jY48z4RhSE96","itemData":{"saveSource":{"interactionId":"{uuid}"}}}]}+```+`type` seen: `track`, `album`, `artist`. Removal: `"removed":true,"addedAt":0`.++Protobuf form, field numbers:+```+1 (item, repeated) {+ 1: type varint: 0 = track, 1 = album, 4 = artist+ 2: gid 16 bytes (base62 id decoded)+ 5: addedAt varint, unix seconds (0 on removal)+ 6: removed varint 0/1+ 8: itemData { 1 { 2: interactionId string } }+}+```++### Playlists++| uri | When |+|---|---|+| `hm://playlist/v2/user/{user}/rootlist` and `hm://playlist/user/{user}/rootlist` | rootlist changed (follow, unfollow, create) |+| `hm://playlist/v2/playlist/{id}` | a playlist changed (items added, also seen when merely opening an editorial playlist) |+| `hm://playlist/v2/playlist/{likedId}` | Liked Songs changed (like/unlike) |+| `hm://playlist/v2/list/liked-songs-artist/{artistId}` | the per-artist liked-songs list of that track's artist changed |++Payload is base64 protobuf:+```+1: uri "spotify:user:{user}:rootlist" / "spotify:playlist:{id}" / "spotify:list:liked-songs-artist:{artistId}"+2: new revision 24 bytes (counter + hash, as above)+3: previous revision 24 bytes (when present)+4: ops (repeated) e.g. kind 2 = add:+ { 1: 2 2 { 1: fromIndex 2 { 1: "spotify:track:{id}"+ 2 { 1: addedBy "{user}" 2: timestamp ms 17 { 2: interactionId } } } } }+5: { 1: seconds 2: nanos } change time+6: string server name+9: varint 0 or 1+```+Rootlist and liked-songs-artist pushes carried only fields 1, 2 and 9. Simplest client+rule: on any playlist push, re-fetch that playlist (or the rootlist / `libraryV3`) unless+the revision equals the one already held.++## Gaps (not captured)++- Remove tracks from a playlist (expected `playlist/v2/playlist/{id}/changes` with a `REM`+ op, or a GraphQL `removeFromPlaylist`; unknown).+- Reorder tracks (`MOV`, or `addToPlaylist`/move with `fromUid`; unknown).+- Delete a playlist (for an own playlist the Web Player probably only does the rootlist+ `REM`; not confirmed).+- Folders: create, rename, move items into folders, rootlist folder markers, and+ `libraryV3` with `folderUri`/`expandedFolders`/`flatten` set.+- `libraryV3` with a filter or another sort: the variable names for the selected filter+ and sort (`order` is null by default, no filter key was sent) are not known.+- Pin / unpin in Your Library.+- Change description, cover image, public/private, collaborative.+- `applyCurations` with `CURATE` (adding through the heart sheet), multi-playlist curations.+- Liked Songs for podcasts (`YOUR_EPISODES_V2`), shows, audiobooks.+- Error responses (rate limit, revision conflict, permission denied).++## TODO++- TODO: libraryV3 filters and sorts — capture a session with a filter chip and each sort order to get the variable names.+- TODO: rootlist folders — capture folder create/move to see folder markers in rootlist `items` and the `changes` ops.diff --git a/docs/api/SEARCH-HOME.md b/docs/api/SEARCH-HOME.mdnew file mode 100644index 00000000..01f14bfb--- /dev/null+++ b/docs/api/SEARCH-HOME.md@@ -0,0 +1,252 @@+# Search, browse and home (Web Player, GraphQL)++Clean-room spec from captures `01-login`, `03-search`, `04-playlists` (free account,+Web Player `1.3.6.x`, locale `fr`, 2026-10-15). Ids below are examples or `{id}`;+no token, cookie or account value is reproduced.++## Transport++All ops: `POST https://api-partner.spotify.com/pathfinder/v2/query`, body:++```json+{"variables":{...},"operationName":"searchTracks",+ "extensions":{"persistedQuery":{"version":1,"sha256Hash":"<hash>"}}}+```++| Header | Holds |+|---|---|+| `authorization` | `Bearer {web access token}` (from `open.spotify.com/api/token`) |+| `client-token` | token from `clienttoken.spotify.com/v1/clienttoken` |+| `app-platform` | `WebPlayer` |+| `spotify-app-version` | web player build, e.g. `1.3.6.1858.g{hash}` |+| `content-type` | `application/json;charset=UTF-8` |+| `accept` | `application/json` |+| `accept-language` | UI locale (`fr`); drives every label (titles, greeting, chips) |+| `origin` / `referer` | `https://open.spotify.com` / `https://open.spotify.com/` |++Response: `{"data":{...},"extensions":{"requestIds":{...}}}`. Every entity comes as a+`*ResponseWrapper {__typename, data:{__typename, ...}}`; `data.__typename` may be+`NotFound` (seen in home) or a restricted type, so always switch on it.++## Operation table++| operationName | sha256Hash | Trigger |+|---|---|---|+| `recentSearches` | `ece96d7b82c820fb9938dd1df50dee3e53737d808c3883e3d01c467c423601b0` | open search page |+| `searchSuggestions` | `f244254b94c0e824d458ac216e0f8406a73f2f69a9ff52831a2f78fa774ff6ce` | each keystroke (debounced) |+| `searchTopResultsList` | `dd78eaff943eba629ed70ee25517b9cea0dcaa41193e2592ae2727660b21892c` | submit, "All" tab |+| `searchTracks` | `b02683192a98dde7966b5e6655a79eeb62713eab703eda9902c932818dd52751` | Songs tab |+| `searchArtists` | `7bf95d754fdbe32c8b161fbbe54d1ae50974900df4dce4c8f1afcbcad153224d` | Artists tab |+| `searchAlbums` | `202cb3305e31e5a0767ba7925f28bd728cf8f8b0217e6da43909056071cd70e9` | Albums tab |+| `searchPlaylists` | `d520014e748f9ea44f7707d8df1819867ac1205e8b7f3e28f22fe5fc858921b1` | Playlists tab |+| `browseAll` | `dbd8b55e09a58afc52eab438bc228ba28fd72ac2f2148c6c26354980e4579001` | search page, empty query |+| `home` | `5fb7da7a03ee2776c0670856609cb85a189a3cecc36cc160b91cde79063b9cf1` | home page |+| `feedBaselineLookup` | `318190494c436b51ab995367bffc66dcdb49dfa023792c60ac15dcb6dfbec42f` | home, after/with `home` |+| `lookupChildEntities` | `91ce02e32b19123de231dc8de91fe4b9ab84eca087d4c015549308d77fbb6d10` | home "Recents" child art |+| `fetchEntitiesForRecentlyPlayed` | `cf5d2e94ffd82788470788ae1f6090cc3e9e774fb8fd383580634c6e6f50f7be` | app boot (restored player context) |+| `decorateContextTracks` | `383de00240775c39a6afe0b1055dc562b2a3930894201f9762f3fc32a74971c7` | app boot (queue of restored context) |+| *(none)* `pathfinder/v1/query` | `f952da037440f694cc6925b9e3f649d39077a744c4db7dfba01cb883723f4f77` | app boot, alongside the above |++Not captured: podcast/episode/user/genre/audiobook search tabs, genre/category page,+home section paging, home chip filter. See Gaps.++## Search++UI routes: `/search` -> `/search/{q}` -> `/search/{q}/tracks|artists|albums|playlists`.++### Variables++| Op | Variables (observed) |+|---|---|+| `recentSearches` | `limit:Int=50, includeAuthors:Bool=true, includeEpisodeContentRatingsV2:Bool=true` |+| `searchSuggestions` | `query:String, limit:30, numberOfTopResults:30, offset:0, includeAuthors:true, includeAlbumPreReleases:false, includeEpisodeContentRatingsV2:true` |+| `searchTopResultsList` | `query:String, limit:50, offset:0, numberOfTopResults:50, includeArtistHasConcertsField:false, includeAudiobooks:true, includeAuthors:true, includePreReleases:true, includeAlbumPreReleases:false, includeEpisodeContentRatingsV2:true, isPrefix:null, sectionFilters:["GENERIC","VIDEO_CONTENT"]` |+| `searchTracks` | `searchTerm:String, offset:0, limit:20, numberOfTopResults:20, includeAudiobooks:true, includeAuthors:true, includePreReleases:false, includeAlbumPreReleases:false, includeEpisodeContentRatingsV2:true` |+| `searchArtists` / `searchAlbums` / `searchPlaylists` | same as `searchTracks` but `limit:30` |++Note: the name is `query` for suggestions/top results and `searchTerm` for the tab ops.++### Response paths++| Op | Root | Items |+|---|---|---|+| `recentSearches` | `data.recentSearches.recentSearchesItems.items[]` (`RecentSearchesPage`) | wrappers directly (`ArtistResponseWrapper`, ...) |+| `searchSuggestions` | `data.searchV2.topResultsV2.itemsV2[]` (`TopResultHit`) | `.item` = wrapper |+| `searchTopResultsList` | `data.searchV2.topResultsV2.itemsV2[]` | `.item` = wrapper or `SearchSectionEntity`; `.matchedFields[]` |+| `searchTracks` | `data.searchV2.tracksV2` | `items[].item` = `TrackResponseWrapper` (extra `item` level!) |+| `searchArtists` | `data.searchV2.artists` | `items[]` = `ArtistResponseWrapper` |+| `searchAlbums` | `data.searchV2.albumsV2` | `items[]` = `AlbumResponseWrapper` |+| `searchPlaylists` | `data.searchV2.playlists` | `items[]` = `PlaylistResponseWrapper` |++Tab paging: `{totalCount, pagingInfo:{limit, nextOffset}}` beside `items`; request the+next page with `offset = nextOffset` (presumably null on the last page).++`searchSuggestions` item types: `SearchAutoCompleteEntity` (`item.text` directly on the item, no `data` level; `uri =+spotify:search:{text}`; the UI shows these first as query completions),+`ArtistResponseWrapper`, `TrackResponseWrapper`, `PlaylistResponseWrapper`,+`EpisodeResponseWrapper` (also `AlbumResponseWrapper` in top results).++`searchTopResultsList` extras:+- `searchV2.{tracksV2,artists,albumsV2,playlists,episodes,podcasts,audiobooks,users,genres,authors}.totalCount` (counts only, no items).+- `searchV2.chipOrder.items[].typeName`: tab order, e.g. `TRACKS, VIDEOS, ARTISTS, EPISODES, PLAYLISTS, ALBUMS, USERS, PODCASTS, AUDIOBOOKS, GENRES`.+- The first hit is the "top result" card (here the artist). Hits interleave+ `SearchSectionEntity` shelves: `data:{title.transformedLabel, sectionType:"GENERIC"|"VIDEO_CONTENT", attributionUri, items:[wrappers]}` (e.g. "With {artist}" playlists, "Videos" tracks).++### Entity fields the UI needs (inside `wrapper.data`)++| Type | Fields |+|---|---|+| `Track` | `uri, id, name, duration.totalMilliseconds, contentRating.label (EXPLICIT/NONE), playability.{playable,reason}, trackMediaType (AUDIO), artists.items[].{uri,profile.name}, albumOfTrack.{uri,id,name,coverArt.sources[]}, associationsV3.videoAssociations.totalCount` |+| `Artist` | `uri, profile.name, visuals.avatarImage.sources[]` (may be null), `visuals.avatarImage.extractedColors.colorDark.hex` |+| `Album` | `uri, name, type (ALBUM/SINGLE/EP...), date.year, artists.items[], coverArt.sources[], playability, isAlbumPreRelease, preReleaseEndDateTime` |+| `Playlist` | `uri, name, description (may hold <a href=spotify:...> HTML), format, images.items[0].sources[], ownerV2.data.{uri,name,username,avatar}, attributes[{key,value}]` |+| `Episode` | `uri, name, description, duration, releaseDate.isoString, coverArt, podcastV2.data.{uri,name,publisher.name}, playedState, restrictions.paywallContent` |++Images: `sources[] {url, width, height}`; album covers come as 300/64/640, artists+640/160/320 (order not sorted, pick by size). Colors: `extractedColors.colorDark.{hex,isFallback}`;+`visualIdentity.squareCoverImage.extractedColorSet` holds richer RGBA palettes (ignorable).++```json+{"data":{"searchV2":{"query":"{q}","tracksV2":{+ "items":[{"matchedFields":[],"item":{"__typename":"TrackResponseWrapper","data":{+ "__typename":"Track","uri":"spotify:track:{id}","id":"{id}","name":"Song",+ "duration":{"totalMilliseconds":204664},"contentRating":{"label":"EXPLICIT"},+ "playability":{"playable":true,"reason":"PLAYABLE"},"trackMediaType":"AUDIO",+ "artists":{"items":[{"uri":"spotify:artist:{id}","profile":{"name":"Artist"}}]},+ "albumOfTrack":{"uri":"spotify:album:{id}","id":"{id}","name":"Album",+ "coverArt":{"extractedColors":{"colorDark":{"hex":"#305868","isFallback":false}},+ "sources":[{"url":"https://i.scdn.co/image/{hex}","width":300,"height":300}]}}}}}],+ "pagingInfo":{"limit":20,"nextOffset":20},"totalCount":429}}}}+```++## Browse (`browseAll`)++Variables: `pagePagination:{offset:0,limit:10}, sectionPagination:{offset:0,limit:99},+browseEndUserIntegration:"INTEGRATION_WEB_PLAYER"`.++Root `data.browseStart` (`BrowseSectionContainer`, `uri spotify:page:{id}`):+`sections.items[] {uri: spotify:section:{id}, data:{__typename, title.transformedLabel}, sectionItems.items[]}`.+No paging info was returned.++- Section `BrowseUnsupportedSectionData` holds a display ad slot (`spotify:promotion:...`, content `UnknownType`): skip.+- Section `BrowseGridSectionData` "Browse all": 70 cards.+ - `content.__typename = BrowseSectionContainerWrapper` (uri `spotify:page:{id}`, a category/genre page):+ `content.data.data.cardRepresentation.{title.transformedLabel, backgroundColor.hex, artwork.sources[]}`.+ - `content.__typename = BrowseXlinkResponseWrapper` (uri `spotify:xlink:{id}`, data `BrowseClientFeature`, e.g. live events):+ `content.data.{title.transformedLabel, backgroundColor.hex, artwork.sources[], iconOverlay.sources[], featureUri}`.++```json+{"uri":"spotify:page:{id}","content":{"__typename":"BrowseSectionContainerWrapper",+ "data":{"__typename":"BrowseSectionContainer","data":{"cardRepresentation":{+ "title":{"transformedLabel":"Music"},"backgroundColor":{"hex":"#dc148c"},+ "artwork":{"sources":[{"url":"https://i.scdn.co/image/{hex}","width":300,"height":300}]}}}}}}+```++## Home++### `home`++Variables: `timeZone:String` (IANA, e.g. `Europe/Zurich`), `sp_t:String` (value of the+`sp_t` cookie set on `.spotify.com` by the first accounts/open page; a per-browser id,+placeholder `{sp_t}`), `facet:""` (chip filter, empty = all), `sectionItemsLimit:10`,+`homeEndUserIntegration:"INTEGRATION_WEB_PLAYER"`, `includeHomeChapterVideoCards:false`,+`includeEpisodeContentRatingsV2:true`.++Root `data.home` (`HomeResponsePayload`):+- `greeting.transformedLabel` ("Good evening").+- `homeChips[] {id, label.transformedLabel, subChips[{id,label}]}`: ids `music-chip`,+ `podcasts-chip`, `audiobooks-chip`; sub `*-following-chip`. Presumably passed as `facet`.+- `sectionContainer.sections {totalCount, items[]}` (31 sections). Each section:+ `{uri: spotify:section:{id}, data:{__typename, title.transformedLabel, subtitle?, headerEntity?, iconName?},+ sectionItems:{items[], totalCount, pagingInfo.nextOffset}}`; each item:+ `{uri, data (HomeRecsItemData|null), content: wrapper}`.++| Section `data.__typename` | Seen titles | Items |+|---|---|---|+| `HomeShortsSectionData` | (none; top quick-access grid) | 1 `Playlist` |+| `HomeGenericSectionData` | "Recommended radios", "Your favourite mixes", "Your favourite artists", "For fans of {artist}", new audiobooks | up to 10 of `Playlist`, `Artist`, `Audiobook` (`PodcastOrAudiobookResponseWrapper`); `totalCount` larger, `nextOffset` 10 |+| `HomeRecentlyPlayedSectionData` | "Recents" | 1 `ListResponseWrapper/List` uri `spotify:list:recents:main` |+| `HomeFeedBaselineSectionData` | "Made for you", "Based on recent listening", "Videos you might like" | 1 `Playlist` or `EpisodeOrChapterResponseWrapper/Episode` (vertical feed cards) |++`headerEntity` is `ArtistResponseWrapper` (artist avatar + name before the title) or `UnknownType`.+Playlist cards: `name, description, format, images.items[0].sources[0].url, ownerV2.data.name`.+Artist cards: `profile.name, visuals.avatarImage`. Audiobook: `name, authorsV2[].name, coverArt`.++Recents list: `content.data.items.items[] {uid, entity, formatListAttributes[{key,value}]}`;+`entity` = `EntityResponseWrapper {_uri, data:{entityTypeTrait.type (ENTITY_TYPE_ARTIST|ENTITY_TYPE_PLAYLIST...),+identityTrait.{name,type,description,contributors}, visualIdentityTrait.squareCoverImage, typedEntity (wrapper or UnknownType), sharingInfo}}`.+`spotify:collection:tracks` (Liked Songs) appears here; its `group_metadata` attribute+(base64 protobuf) names a child playlist uri, which is then fetched with `lookupChildEntities`.++```json+{"data":{"home":{"__typename":"HomeResponsePayload","greeting":{"transformedLabel":"Good evening"},+ "homeChips":[{"id":"music-chip","label":{"transformedLabel":"Music"},"subChips":[{"id":"music-following-chip"}]}],+ "sectionContainer":{"uri":"spotify:page:{id}","sections":{"totalCount":31,"items":[+ {"uri":"spotify:section:{id}",+ "data":{"__typename":"HomeGenericSectionData","title":{"transformedLabel":"Recommended radios"},+ "subtitle":{"transformedLabel":"..."},"headerEntity":{"__typename":"UnknownType"}},+ "sectionItems":{"totalCount":15,"pagingInfo":{"nextOffset":10},"items":[+ {"uri":"spotify:playlist:{id}","data":{"__typename":"HomeRecsItemData"},+ "content":{"__typename":"PlaylistResponseWrapper","data":{"__typename":"Playlist",+ "uri":"spotify:playlist:{id}","name":"Radio X","format":"inspiredby-mix",+ "images":{"items":[{"sources":[{"url":"https://pickasso.spotifycdn.com/image/{...}"}]}]},+ "ownerV2":{"data":{"__typename":"User","name":"Spotify","uri":"spotify:user:spotify"}}}}}]}}]}}}}}+```++### `feedBaselineLookup`++Variables `uris:[String]`: the content uris of all `HomeFeedBaselineSectionData` items (19, playlists and episodes).+Response `data.lookup[]` wrappers (`_uri` + `data`) with preview media for the vertical feed:+- Playlist: `data.previewItems.items[]` = `TrackResponseWrapper` with `name, uri, albumOfTrack.coverArt,+ previews.audioPreviews.items[].url` (mp3 preview on `p.scdn.co`), `canvas.{url,type,thumbnail}` (may be null).+- Episode: `data.previewPlayback.{audioPreview.cdnUrl, videoPreview.{fileId, offset, placeholderImage}}`.+Optional for a client that does not show previews.++### `lookupChildEntities`++Variables `uris:["spotify:playlist:{id}"]`. Response `data.lookupEntities[] {__typename:"Entity", uri,+visualIdentityTrait.squareCoverImage.{image.data.sources[].url, originalInstances[].flatFile.cdnUrl}}`+(Liked Songs art `misc.scdn.co/liked-songs/liked-songs-{300|640}.png`).++## Boot-time player decoration++Fired on every app load (also after navigating to `/search` with reload) once the+restored player state is known (from Connect cluster, see CAPTURE-MAP).++| Call | Variables | Response |+|---|---|---|+| `decorateContextTracks` | `uris:[50 x spotify:track]` (queue of current context) | `data.tracks[] {__typename:"Track", uri, name, duration.totalMilliseconds, contentRating.label, artists.items[].{uri,profile.name}, albumOfTrack.{uri,name,coverArt.sources[]}, associationsV3}` |+| `fetchEntitiesForRecentlyPlayed` | `uris:[1 context uri]` (current/last playlist) | `data.lookup[]` wrapper: `Playlist {uri,name,description,format,images,ownerV2.data.{name,uri,username}, attributes[]}` |+| `pathfinder/v1/query` | `uris:[3..5 spotify:track]` (current track and its neighbours) | `data.lookupEntities[]` (see below) |++`pathfinder/v1/query` is an unnamed persisted query (no `operationName` in the body)+sent by a different client module: headers lack `app-platform` and `spotify-app-version`,+`accept: */*`, `content-type: application/json`; still `authorization` + `client-token`.+Body `{"variables":{"uris":[...]},"extensions":{"persistedQuery":{"version":1,"sha256Hash":"f952da03..."}}}`.+It is a generic entity lookup (likely now-playing / media-session metadata):++```json+{"data":{"lookupEntities":[{"__typename":"Entity","uri":"spotify:track:{id}",+ "entityTypeTrait":{"type":"ENTITY_TYPE_TRACK"},+ "consumptionExperienceTrait":{"duration":{"seconds":215,"nanoSeconds":0}},+ "identityTrait":{"name":"Song","contentHierarchyParent":{"uri":"spotify:album:{id}"}},+ "typedEntity":{"data":{"__typename":"Track","uri":"spotify:track:{id}","name":"Song",+ "albumOfTrack":{"uri":"spotify:album:{id}","name":"Album","coverArt":{"sources":[...]}},+ "artists":{"items":[{"uri":"spotify:artist:{id}","profile":{"name":"Artist"}}]},+ "duration":{"totalMilliseconds":215813},"playability":{"playable":true},+ "relinkingInformation":null}}}]}}+```++## Gaps++| Unknown | Capture that answers it |+|---|---|+| Search ops for podcasts, episodes, users, genres, audiobooks (names, hashes) | 03-search: click those chips on `/search/{q}` |+| Genre/category page op (`spotify:page:{id}` from browse cards) and its section layout | open a browse card (e.g. Pop) |+| Home section "Show all" / paging op (`nextOffset` use) | click a home section title |+| `home` with `facet` set (chip value format) | click the Music / Podcasts chip on home |+| Second page of a search tab (`nextOffset` null at end?) | scroll a tab to the end |+| Adding/removing/clearing recent searches (mutations) | click a result, then remove/clear recents |+| `searchSuggestions` with `offset>0`; `isPrefix` non-null | unknown trigger; type then scroll the dropdown |+| Error shapes (expired token, unknown hash -> `PersistedQueryNotFound`?) | replay with stale token / bad hash |+| Exact source of `fetchEntitiesForRecentlyPlayed` / v1 uris (cluster vs local storage) | boot capture with dealer frames correlated |diff --git a/docs/api/SESSION.md b/docs/api/SESSION.mdnew file mode 100644index 00000000..5f51f2ff--- /dev/null+++ b/docs/api/SESSION.md@@ -0,0 +1,392 @@+# Web Player session and transport++Clean-room notes from network captures of open.spotify.com (free account, Chrome on+Linux, 2026-10-15, builds `1.3.6.1858` and `1.3.6.1874`). Values below are placeholders:+`{token}` web access token, `{ct}` client token, `{dev}` 40-hex device id, `{conn}`+dealer connection id, `{user}` account id. See CAPTURE-MAP.md for the feature calls.++## 1. Tokens++### Web access token++`GET https://open.spotify.com/api/token?reason={r}&productType=web-player&totp={code}&totpServer={code}&totpVer={n}`++| Param | Meaning |+|---|---|+| `reason` | `init` on page load, `transport` when the player refreshes it before expiry |+| `productType` | always `web-player` |+| `totp`, `totpServer` | 6-digit TOTP codes, computed in the page from local time and from server time (usually equal) |+| `totpVer` | version of the TOTP secret (61 in the capture) |++Auth is the `sp_dc` cookie (session cookie set by accounts.spotify.com; `sp_t`, `sp_key`+also sent). No Authorization header. Before a `transport` refresh the page calls+`GET open.spotify.com/api/server-time` -> `{"serverTime": <unix seconds>}`.++Response (JSON): `clientId`, `accessToken`, `accessTokenExpirationTimestampMs`,+`isAnonymous`, `_notes`. Lifetime is about 1 hour (55 min left on first fetch). The+server caches the token per cookie: reloads within the hour return the same token and+expiry. A `transport` call returned a new token with a fresh hour.++The token is used as `authorization: Bearer {token}` on pathfinder and spclient, and as+the `access_token` query param of the dealer WebSocket.++### Client token++`POST https://clienttoken.spotify.com/v1/clienttoken`, `content-type` and `accept`+`application/json`, no auth header.++```json+{"client_data": {+ "client_version": "1.3.6.1858.gc66299947cb4",+ "client_id": "<same value as clientId from /api/token>",+ "js_sdk_data": {"device_brand": "unknown", "device_model": "unknown", "os": "linux",+ "os_version": "unknown", "device_id": "<36-char id, not {dev}>",+ "device_type": "computer"}}}+```++Response: `response_type` = `RESPONSE_GRANTED_TOKEN_RESPONSE`, `granted_token`:+`token`, `expires_after_seconds` (1216800, about 14 days), `refresh_after_seconds`+(1209600, 14 days), `domains` (`spotify.com`, `spotify.net`). Fetched once per page+load; can be cached for days.++### Headers on API calls++| Header | api-partner (pathfinder) | spclient.wg | {region}-spclient | Meaning |+|---|---|---|---|---|+| `authorization` | always | almost always | most | `Bearer {token}` |+| `client-token` | always | always | most | `{ct}` from clienttoken |+| `app-platform` | yes | yes | some | `WebPlayer` |+| `spotify-app-version` | yes | yes | some | build `clientVersion`, e.g. `1.3.6.1858.gc66299947cb4` |+| `accept-language` | `fr` (UI locale) | `fr` | browser list | content language |+| `accept` | `application/json` | `application/json` or `application/protobuf` | `*/*` | |+| `content-type` | `application/json;charset=UTF-8` | JSON | JSON or `text/plain` | |++Extra per-endpoint headers: `x-spotify-connection-id: {conn}` on+`PUT connect-state/v1/devices/hobs_*`; `x-cache-hint: <random 16-hex>` on+`GET connect-state/v1/cluster`; `x-client-id` on `pendragon/.../FetchMessageList`.++Exceptions: `gabo-receiver-service/public/v3/events` and+`widevine-license/v1/application-certificate` carry no `authorization`;+`gabo-receiver-service/*/events` carry no `client-token`. Every pathfinder call+sent both `authorization` and `client-token`, so a client should always send both;+whether the web token alone is accepted was not tested (offline capture).++Pathfinder calls of `getAlbum` and `queryArtistOverview` sometimes sent+`spotify-app-version: 896000000` instead of the dotted version; both were accepted.++## 2. Hosts++`GET https://apresolve.spotify.com/?type=dealer-g2&type=spclient` (no auth). Response:++```json+{"dealer-g2": ["gew4-dealer.g2.spotify.com:443", "guc3-dealer.g2.spotify.com:443", "..."],+ "spclient": ["gew4-spclient.spotify.com:443", "guc3-spclient.spotify.com:443", "..."]}+```++Lists are ordered by preference (nearest first); the page took the first entry of+each (`gew4-*` from Europe) and falls back to the next on failure. Called several+times per page load.++| Host | Used for |+|---|---|+| `api-partner.spotify.com` | GraphQL: `POST /pathfinder/v2/query` (plus one `v1` call, see 3) |+| `spclient.wg.spotify.com` | Fixed global alias. Content and library APIs: `metadata/4`, `extended-metadata`, `collection/v2`, `playlist/v2`, `playlistextender`, `color-lyrics`, `timesynced-text-distribution`, `ads/v2/config`, `gander`, `library-import`, `widevine-license/.../application-certificate` |+| `{region}-spclient.spotify.com` (from apresolve) | Session-bound and playback APIs: `track-playback/v1`, `connect-state/v1`, `manifests`, `storage-resolve`, `widevine-license/.../license`, `melody`, `gabo-receiver-service`, `remote-config-resolver`, `pendragon`, `social-connect` |++Both hosts accept the same auth headers. Connect-state and track-playback must use the+regional host (same region as the dealer, since the dealer connection id is bound to it).++## 3. GraphQL persisted queries++Body of `POST https://api-partner.spotify.com/pathfinder/v2/query`:++```json+{"variables": {...}, "operationName": "fetchPlaylist",+ "extensions": {"persistedQuery": {"version": 1, "sha256Hash": "<64 hex>"}}}+```++One odd call goes to `pathfinder/v1/query` without `operationName`+(`variables.uris` = list of track URIs, response `data.lookupEntities`, hash+`f952da037440f694cc6925b9e3f649d39077a744c4db7dfba01cb883723f4f77`); it is hard-coded+in `vendor~web-player.*.js` as a raw `sha256Hash:"..."` string.++### Where hashes live in the bundles++Each operation is a module constant built with a minified class constructor:++```js+let p=new C.l("concertCount","query","29be9d48...b141",null)+```++Extraction regex (worked on every bundle, no false positives; class alias varies):++```+new [\w$]+(?:\.[\w$]+)?\("(\w+)","(query|mutation|subscription)","([0-9a-f]{64})"+```++Groups: operationName, kind, sha256Hash. A second pass for raw literals:+`sha256Hash:"([0-9a-f]{64})"`.++Most operations of the main pages (`home`, `fetchPlaylist`, `libraryV3`, `getAlbum`,+`queryArtistOverview`, `addToLibrary`...) are defined in the 4.4 MB entry bundle+`web-player.{hash}.js`, whose body was not captured. Their hashes in the table come from+the request bodies instead. Every operation had a single hash across both builds seen.++### Refreshing hashes automatically++1. `GET https://open.spotify.com/` (HTML, with the session cookie or anonymous).+2. Read `<script id="appServerConfig" type="text/plain">` (base64 JSON): fields+ `clientVersion` (use for `spotify-app-version` and clienttoken `client_version`),+ `buildVersion` (`web-player_{date}_{ms}_{sha}`), `buildDate`, `serverTime`,+ `market`, `locale`, `isPremium`, `isAnonymous`. Compare `buildVersion` with the+ cached one; refresh only when it changed.+3. Read `<script id="__CDN_FILE_URLS__" type="text/plain">` (base64 JSON map, about+ 1000 entries): key `build/web-player/{chunk}.js` (and the hashed name) ->+ full URL `https://open.spotifycdn.com/cdn/build/web-player/{chunk}.{hash8}.js`.+ About 164 web-player JS chunks, plus `web-player.js` (entry),+ `vendor~web-player.js`, `encore~web-player.js`. The entry, vendor and encore+ scripts are also plain `<script src>` tags in the HTML.+4. Download the entry bundle and every `build/web-player/*.js` chunk, run the regex,+ merge into an `operationName -> hash` map, persist it with the build version.+5. Fallback at runtime: if pathfinder returns a `PersistedQueryNotFound`-style error+ for an op, trigger step 1-4 once and retry (error shape not captured).++### Table++99 operations: 69 defined in captured chunk bodies, 30 more only seen in request+bodies (they are in the uncaptured entry bundle). `kind` is `-` when only the request+was seen.++| operationName | kind | sha256Hash | seen in |+|---|---|---|---|+| `accountAttributes` | - | `d48062d0df0a256ff78ed9e232b83d238dcd710b371efd304b0e178b62595582` | request (main bundle) |+| `addToLibrary` | - | `896ebcb47815681340860d121cb5d494e157e2a78d3950385cd54e0393c67148` | request (main bundle) |+| `addToPlaylist` | - | `b907ad6b088d5bf7680fa81198996d58398c2d55dfcdf59fcc959e0be98a418a` | request (main bundle) |+| `applyCurations` | - | `05b739a3a73091c213385233b9d3ed8a857c2ca29d2eebadb3d04ed12e288697` | request (main bundle) |+| `areEntitiesInLibrary` | - | `134337999233cc6fdd6b1e6dbf94841409f04a946c5c7b744b09ba0dfe5a85ed` | request (main bundle) |+| `ArtistConcerts` | query | `ef53c43b865496b9890b7167eab1dc614a8949ef9451b3c41184ea888de8bd2b` | bundle `xpui-routes-artist.8dd6925c` |+| `ArtistConcertsPageLocation` | query | `320698465a352f0d0247ec8ed02471244106d4199820f99de4d0a785561c2b03` | bundle `xpui-routes-artist.8dd6925c` |+| `browseAll` | query | `dbd8b55e09a58afc52eab438bc228ba28fd72ac2f2148c6c26354980e4579001` | bundle `xpui-routes-search.1472683a` + request |+| `canvas` | - | `575138ab27cd5c1b3e54da54d0a7cc8d85485402de26340c2145f0f6bb5e7a9f` | request (main bundle) |+| `centralisedStatePlayerOptions` | - | `e2dcfcab470854d4d1c7cb1a851438f14fe0a94d57db7f0b9dde492559d5395d` | request (main bundle) |+| `concert` | query | `9b582a69061f6648858515c2aa6d4a2273ac49b74eb5dbc612bc1299a9f2f13e` | bundle `xpui-root-dialogs.7582d917` |+| `concertCount` | query | `29be9d486e073a49268e13ed9e2d2180187e669fcb7a19b98011aca7ab61b141` | bundle `1272.990d4950` |+| `concertLocationsByLatLon` | query | `8a059d072a17a1199feb21fe846271f1680eda87010c832852ced0c55c6c7c96` | bundle `1272.990d4950` |+| `decorateContextTracks` | - | `383de00240775c39a6afe0b1055dc562b2a3930894201f9762f3fc32a74971c7` | request (main bundle) |+| `decorateQueuedByUsers` | query | `33fe7085b4a9dde404955eeee4f8f93aa7a8e55028058354bc707727d8a7890d` | bundle `dwp-panel-section.0a1acab1` + request |+| `deleteLocation` | mutation | `2f681a7c30da3bc905c469374aa2983d0d00a1b6ba88e5fdd6a23caa02057971` | bundle `1272.990d4950` |+| `editablePlaylists` | - | `d5c4b8096437dcc2ac9528c91dfcd299e35b747cda2f8f75d28f41f49c5092ba` | request (main bundle) |+| `feedBaselineLookup` | - | `318190494c436b51ab995367bffc66dcdb49dfa023792c60ac15dcb6dfbec42f` | request (main bundle) |+| `fetchEntitiesForRecentlyPlayed` | - | `cf5d2e94ffd82788470788ae1f6090cc3e9e774fb8fd383580634c6e6f50f7be` | request (main bundle) |+| `fetchExtractedColorAndImageForAlbumEntity` | query | `b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f` | bundle `xpui-root-dialogs.7582d917` |+| `fetchExtractedColorAndImageForArtistEntity` | query | `b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f` | bundle `xpui-root-dialogs.7582d917` |+| `fetchExtractedColorAndImageForEpisodeEntity` | query | `b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f` | bundle `xpui-root-dialogs.7582d917` |+| `fetchExtractedColorAndImageForPlaylistEntity` | query | `b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f` | bundle `xpui-root-dialogs.7582d917` |+| `fetchExtractedColorAndImageForPodcastEntity` | query | `b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f` | bundle `xpui-root-dialogs.7582d917` |+| `fetchExtractedColorAndImageForTrackEntity` | query | `b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f` | bundle `xpui-root-dialogs.7582d917` |+| `fetchExtractedColorForAlbumEntity` | query | `b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f` | bundle `xpui-root-dialogs.7582d917` |+| `fetchExtractedColorForArtistEntity` | query | `b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f` | bundle `xpui-root-dialogs.7582d917` |+| `fetchExtractedColorForEpisodeEntity` | query | `b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f` | bundle `xpui-root-dialogs.7582d917` |+| `fetchExtractedColorForPlaylistEntity` | query | `b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f` | bundle `xpui-root-dialogs.7582d917` |+| `fetchExtractedColorForPodcastEntity` | query | `b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f` | bundle `xpui-root-dialogs.7582d917` |+| `fetchExtractedColorForTrackEntity` | query | `b2d6d99fb6237952dfa6638385f9c6085f1b1fb9d0468753ca6ad98ff45adc6f` | bundle `xpui-root-dialogs.7582d917` |+| `fetchExtractedColors` | - | `36e90fcaea00d47c695fce31874efeb2519b97d4cd0ee1abfb4f8dc9348596ea` | request (main bundle) |+| `fetchPlaylist` | - | `21ea11a6ac75a5f3e01fd365d29c18e0a4a8b7dc09f89bbb5d73910190c6acaf` | request (main bundle) |+| `fetchPlaylistContents` | - | `21ea11a6ac75a5f3e01fd365d29c18e0a4a8b7dc09f89bbb5d73910190c6acaf` | request (main bundle) |+| `fetchPlaylistMetadata` | - | `21ea11a6ac75a5f3e01fd365d29c18e0a4a8b7dc09f89bbb5d73910190c6acaf` | request (main bundle) |+| `getAlbum` | - | `11c9cad9cb24c4f9e25ef9456f68621cfd6006a90f679e729c1d2f2fd70dfe16` | request (main bundle) |+| `getAudiobooksMetadata` | query | `523c71c64749a628f83e6b31a122c76663243730bf02df01fd64abf0f62f572f` | bundle `1675.fa3bc7da` |+| `getDynamicColorsByUris` | - | `f0f112945d6d745bd8ff790317bbf8d310036da75df33130490e9d6dc96c59d9` | request (main bundle) |+| `getTrack` | - | `a8ef9e9f02b836feb0da3003c31dbb30decc6f4b473ef89ca88c882386d668de` | request (main bundle) |+| `home` | - | `5fb7da7a03ee2776c0670856609cb85a189a3cecc36cc160b91cde79063b9cf1` | request (main bundle) |+| `inferredUserLocation` | query | `5db4c507ea735d2a1f37bd1166eca2c1a0e3387bb875ebca5d6031b6eccceeba` | bundle `1272.990d4950` |+| `internalLinkRecommenderTrack` | query | `c77098ee9d6ee8ad3eb844938722db60570d040b49f41f5ec6e7be9160a7c86b` | bundle `xpui-routes-track-v2.f48fb16e` + request |+| `isCurated` | - | `e4ed1f91a2cc5415befedb85acf8671dc1a4bf3ca1a5b945a6386101a22e28a6` | request (main bundle) |+| `libraryV3` | - | `390c78e5b951029bad359785e69b07b536a509c581cbcd0aded5e5067f187455` | request (main bundle) |+| `lookupChildEntities` | query | `91ce02e32b19123de231dc8de91fe4b9ab84eca087d4c015549308d77fbb6d10` | bundle `7338.5565a19f` + request |+| `npvV2TrackSupplementalSections` | query | `3268e307f08330b620de5c161a03b48acf66ec57164eac446e0653694a485764` | bundle `dwp-panel-section.0a1acab1` + request |+| `playlistPermissions` | - | `e43d1d35f231cf289c23c9d9c489f4a4f502e4eda09839c530608f107b6556b8` | request (main bundle) |+| `playlistSection` | query | `2615df403a9043c1d7d3094fbeb4c9653b07b11a33d8081fbd31f0f7959ff4a1` | bundle `xpui-routes-playlist.7090f328` |+| `profileAttributes` | - | `08ffb4730af3746e04a8301396f20875dbbce10c75243803091a9274eacc8ac0` | request (main bundle) |+| `queryAlbumMerch` | query | `3ef44ed6f17be67299538fe77faffab4075aeaf9e1085f10fc835592266711b5` | bundle `xpui-routes-album.7c466d0f` + request |+| `queryArtistAboutModal` | query | `702e29a866e0b4b4fabdf974454512a2c32d93643b1969b7a3a0dd92084f05f6` | bundle `xpui-root-dialogs.7582d917` |+| `queryArtistAppearsOn` | query | `9a4bb7a20d6720fe52d7b47bc001cfa91940ddf5e7113761460b4a288d18a4c1` | bundle `xpui-routes-artist.8dd6925c` |+| `queryArtistDiscographyAlbums` | query | `5e07d323febb57b4a56a42abbf781490e58764aa45feb6e3dc0591564fc56599` | bundle `xpui-routes-artist.8dd6925c` |+| `queryArtistDiscographyAll` | query | `5e07d323febb57b4a56a42abbf781490e58764aa45feb6e3dc0591564fc56599` | bundle `xpui-routes-artist.8dd6925c` |+| `queryArtistDiscographyCompilations` | query | `5e07d323febb57b4a56a42abbf781490e58764aa45feb6e3dc0591564fc56599` | bundle `xpui-routes-artist.8dd6925c` |+| `queryArtistDiscographyOverview` | query | `5e07d323febb57b4a56a42abbf781490e58764aa45feb6e3dc0591564fc56599` | bundle `xpui-routes-artist.8dd6925c` |+| `queryArtistDiscographySingles` | query | `5e07d323febb57b4a56a42abbf781490e58764aa45feb6e3dc0591564fc56599` | bundle `xpui-routes-artist.8dd6925c` |+| `queryArtistDiscoveredOn` | query | `71c2392e4cecf6b48b9ad1311ae08838cbdabcfd189c6bf0c66c2430b8dcfdb1` | bundle `xpui-routes-artist.8dd6925c` |+| `queryArtistFeaturing` | query | `20842d6d9d2d28ef945984b68cb927bb33edd00eab84a8da1667def21f1f2c54` | bundle `xpui-routes-artist.8dd6925c` |+| `queryArtistMinimal` | query | `53d3f76582c49ad0a05dc685955f20dc2a5f2209b192e5446e5e4e623ce23a48` | bundle `xpui-routes-artist.8dd6925c` |+| `queryArtistOverview` | - | `9f8134ef565e78621f1e1793555bd6633c5ac144ae0f89604ed3ae3f80b3c8e6` | request (main bundle) |+| `queryArtistPlaylists` | query | `54f7e5a5a2af05b7dc98526df376a46c6b15c05440c8dfdc8f6cecb1a807eca7` | bundle `xpui-routes-artist.8dd6925c` |+| `queryArtistRelated` | query | `3d031d6cb22a2aa7c8d203d49b49df731f58b1e2799cc38d9876d58771aa66f3` | bundle `xpui-routes-artist.8dd6925c` |+| `queryArtistRelatedVideos` | query | `e4bbb4f420ad5786caa7028e2943542f13c8138f5c40736292b8499ac9672ce6` | bundle `xpui-routes-artist.8dd6925c` |+| `queryInlineCurationSearchAlbum` | query | `122fd4817f7e9cd7b944c3103d9c81a950668423ba9d2008413b5291f9d7e547` | bundle `xpui-routes-playlist.7090f328` |+| `queryInlineCurationSearchArtist` | query | `be42f25d92bdadac4082e6581d35b771c3b5e8bbdd1b76c279d0924a5975f12e` | bundle `xpui-routes-playlist.7090f328` |+| `queryInlineCurationSearchV2` | query | `331ddd828a4db217046345833863f59f907d269947dd6f924009f6ab35743b70` | bundle `xpui-routes-playlist.7090f328` |+| `queryInlineCurationSearchV2Booklists` | query | `331ddd828a4db217046345833863f59f907d269947dd6f924009f6ab35743b70` | bundle `xpui-routes-playlist.7090f328` |+| `queryNpvArtist` | - | `e1ae46a21911a3075c1aa29bf09a6c60f9a45b6a2b1132429f10ad06c299b5d7` | request (main bundle) |+| `queryTrackArtists` | - | `ee2b038198f5e62c679c3996584d9249bbee55fe69fc212271c56492a022c798` | request (main bundle) |+| `queryTrackCreditsGroupedModal` | query | `f135fb9be58a72d041ab5d214d817021a272405d883860468e2627afb01a3ca9` | bundle `xpui-root-dialogs.7582d917` |+| `recentSearches` | - | `ece96d7b82c820fb9938dd1df50dee3e53737d808c3883e3d01c467c423601b0` | request (main bundle) |+| `removeFromLibrary` | - | `896ebcb47815681340860d121cb5d494e157e2a78d3950385cd54e0393c67148` | request (main bundle) |+| `saveLocation` | mutation | `5502351e9f201ae29014ca55d3b24b755ba261a1a9eb35fb498cb4c7df419353` | bundle `1272.990d4950` |+| `searchAlbums` | query | `202cb3305e31e5a0767ba7925f28bd728cf8f8b0217e6da43909056071cd70e9` | bundle `xpui-routes-search.1472683a` + request |+| `searchArtists` | query | `7bf95d754fdbe32c8b161fbbe54d1ae50974900df4dce4c8f1afcbcad153224d` | bundle `xpui-routes-search.1472683a` + request |+| `searchAudiobooks` | query | `e05ac765d02c084f8783d3c1572b23d57761c43f47eb8b87ce2f9ccced3fa068` | bundle `xpui-routes-search.1472683a` |+| `searchAuthors` | query | `4a9d403a7cbc7e19da5520d619a865472b35382b043bfa458154e73a5c6f46bd` | bundle `xpui-routes-search.1472683a` |+| `searchConcertLocations` | query | `43ededefcba8b3f519fd0c2d6c025dfeec9f742cf47d04a3c3711d95b27deda3` | bundle `1272.990d4950` |+| `searchDesktop` | query | `eef7cc54888d91bdd6802623477873caa3948ae173a0c34fd86827b267e94c03` | bundle `xpui-routes-search.1472683a` |+| `searchEpisodes` | query | `dbc56e15e7c1254f11d499e8647343bbf28a5594e14a8f5c8b1e7eee67a55740` | bundle `xpui-routes-search.1472683a` |+| `searchFullEpisodes` | query | `397a4e93a21d140d088cfd26641133c5146a2f5f08e420654868153e720f5571` | bundle `xpui-routes-search.1472683a` |+| `searchGenres` | query | `9e1c0e056c46239dd1956ea915b988913c87c04ce3dadccdb537774490266f46` | bundle `xpui-routes-search.1472683a` |+| `searchModalEntityPage` | query | `25d73ce01f3011ff8b37f44c23ebbad18610db1a2cec2c84f20c1e822c748524` | bundle `xpui-root-dialogs.7582d917` |+| `searchModalResults` | query | `9a79751378a306d87d9789fa0c4a8f7c7213891c47a3993a0d0b58ff26514e59` | bundle `xpui-root-dialogs.7582d917` |+| `searchPlaylists` | query | `d520014e748f9ea44f7707d8df1819867ac1205e8b7f3e28f22fe5fc858921b1` | bundle `xpui-routes-search.1472683a` + request |+| `searchPodcasts` | query | `0195d9f61b43606d490bca64c3456e3593528cea6cc05c7e822c7c42beed0f4e` | bundle `xpui-routes-search.1472683a` |+| `searchSuggestions` | - | `f244254b94c0e824d458ac216e0f8406a73f2f69a9ff52831a2f78fa774ff6ce` | request (main bundle) |+| `searchTopResultsList` | query | `dd78eaff943eba629ed70ee25517b9cea0dcaa41193e2592ae2727660b21892c` | bundle `xpui-routes-search.1472683a` + request |+| `searchTopResultsOnly` | query | `cb32d0ff697131db6d34f174f7d2fa931c6a8b6be22aabc8c6cc086da4a0f744` | bundle `xpui-routes-search.1472683a` |+| `searchTracks` | query | `b02683192a98dde7966b5e6655a79eeb62713eab703eda9902c932818dd52751` | bundle `xpui-routes-search.1472683a` + request |+| `searchUsers` | query | `8f358dd82e62f61dd4ceaa9f8cd0889e644c9b707f1b724fbfb356a757cb7e5a` | bundle `xpui-routes-search.1472683a` |+| `showItemsPlayedState` | query | `4a070b9bfab2e8537a5271e6839bc3ef51501dcac8170b5fb69a98f967c5fb60` | bundle `xpui-root-dialogs.7582d917` |+| `similarAlbumsBasedOnThisTrack` | - | `1d1f93a737498adca2c892c73af87fc0b052afe4e1a33c989540c32413dfae17` | request (main bundle) |+| `thisisPlaylistExtension` | query | `906c2e14927400c8a71645c647576ce032f837a112d5e6f9375b19c80445c8cf` | bundle `xpui-routes-playlist.7090f328` |+| `trackPreview` | query | `fc26ffc7a1a4f93bd4c2d705649f7dba1de34005b3dc2915549847a9959405d8` | bundle `1675.fa3bc7da` |+| `userLocation` | query | `079939378ca79b67c6d047be9152ea940d21f10bbfa2f5d4cf4d8320d87774c2` | bundle `1272.990d4950` |+| `watchFeedEntity` | query | `d1a805f815ee0c20281330317d8c00c8fce9026686a86c38bc700ccaefb9ac5c` | bundle `dwp-watch-feed-view-container.7da8db88` |+| `watchFeedView` | query | `ce10864fccc53ca77c422143ee027bacf220f9d714e27ec592905334079ad743` | bundle `dwp-watch-feed-view-container.7da8db88` |++## 4. Dealer WebSocket++Connect: `wss://{dealer-host}/?access_token={token}` (host from apresolve+`dealer-g2`, e.g. `gew4-dealer.g2.spotify.com`; only query param is `access_token`).+Reconnect (new socket, new `{conn}`, re-register) with a fresh token when it expires; the+capture shows a new socket per page load, and the exact refresh behaviour was not isolated.++Frames are JSON text.++- Client -> server: only `{"type":"ping"}` every 30 s.+- Server -> client: `{"type":"pong"}` per ping.+- First server frame right after open: the connection id:++```json+{"type": "message", "method": "PUT",+ "uri": "hm://pusher/v1/connections/{conn, url-encoded base64}",+ "headers": {"Spotify-Connection-Id": "{conn}"}}+```++ `{conn}` goes into the `x-spotify-connection-id` header of+ `PUT connect-state/v1/devices/hobs_*` and into `connection_id` of the+ track-playback register body. No subscribe message is sent: the server pushes+ everything for the user once the device is registered.++- Push messages: `{"type":"message","uri":"hm://...","headers":{...},"payloads":[...]}`.+ `payloads` items are either JSON objects or strings (base64 protobuf, or plain JSON+ text). No message in the capture used `Transfer-Encoding: gzip`, but a client should+ gunzip when that header is present or bytes start with `1f 8b`.+- No `type:"request"` frames (with reply) were seen.++| uri pattern | headers | payload | carries |+|---|---|---|---|+| `hm://pusher/v1/connections/{conn}` | `Spotify-Connection-Id` | none (`method: PUT`) | connection id, once per socket |+| `hm://connect-state/v1/cluster` | `content-type: application/json` | JSON object: `cluster`, `update_reason`, `ack_id`, `devices_that_changed` | full cluster (`active_device_id`, `devices`, `player_state`, `timestamp`, `started_playing_at`, `not_playing_since_timestamp`...). Reasons seen: `DEVICE_STATE_CHANGED`, `DEVICE_VOLUME_CHANGED` |+| `hm://track-playback/v1/command` | `content-type: application/json` | JSON object, `type` = `replace_state` (`state_machine`, `state_ref`, `prev_state_ref`, `seek_to`, `selected_alias_id`, `context_metadata`, `registration_token`) or `set_volume` (`volume`, `command_id`, `registration_token`) | commands to the local player (play queue state machine) |+| `hm://collection/collection/{user}` | `Content-Type: application/octet-stream`, `MC-ETag`, `Collection-Source-Revision`, sometimes `Collection-Update-Id` | base64 protobuf | Liked Songs change |+| `hm://collection/collection/{user}/json` | same, `Content-Type: text/plain` | JSON string `{"items":[{"type":"track","unheard","addedAt","removed","identifier","itemData"?}]}` | same change, JSON form (easier to use) |+| `hm://collection/artist/{user}` and `.../json` | same as above | protobuf / JSON with `type:"artist"` | followed artists change |+| `hm://playlist/v2/playlist/{id}` | none | base64 protobuf: field 1 playlist URI, then revision bytes and ops | playlist content or attributes changed |+| `hm://playlist/v2/user/{user}/rootlist`, `hm://playlist/user/{user}/rootlist` | none | base64 protobuf: rootlist URI + revision | library playlist list changed (both forms pushed) |+| `hm://playlist/v2/list/liked-songs-artist/{artistId}` | none | base64 protobuf: `spotify:list:liked-songs-artist:{id}` | liked-songs-by-artist list changed |+| `hm://herodotus/uri/spotify:list:play-history:v1/resume-point-revision/{uuid}` | `Content-Type: application/octet-stream` | base64 protobuf: uuid, `spotify:list:play-history:v1`, track or ad URI | play history entry added (one per played track/ad) |++## 5. Connect state and device registration++Order on startup: token + client token -> apresolve -> dealer open (get `{conn}`) ->+register track-playback device -> PUT connect-state -> pathfinder calls.++### Register the player: `POST {spclient}/track-playback/v1/devices`++```json+{"device": {+ "brand": "spotify", "model": "web_player", "name": "Web Player (Chrome)",+ "device_type": "computer", "device_id": "{dev}",+ "platform_identifier": "web_player linux undefined;chrome 155.0.0.0;desktop",+ "is_group": false, "is_public": false, "metadata": {},+ "correlation_id": "<uuid>", "client_version": "harmony:4.81.1-1f3d48b7f",+ "capabilities": {"change_volume": true, "enable_play_token": true,+ "supports_file_media_type": true, "play_token_lost_behavior": "pause",+ "disable_connect": false, "audio_podcasts": true, "video_playback": true,+ "manifest_formats": ["file_ids_mp3", "file_urls_mp3", "manifest_urls_audio_ad",+ "manifest_ids_video", "file_urls_external", "file_ids_mp4", "file_ids_mp4_dual"],+ "supports_preferred_media_type": true, "supports_playback_offsets": true,+ "supports_playback_speed": true}},+ "connection_id": "{conn}", "client_version": "harmony:4.81.1-1f3d48b7f",+ "outro_endcontent_snooping": false, "volume": 65535}+```++`{dev}` is 40 hex chars, random per page load. Response: `initial_seq_num`,+`device_keep_alive_update_seconds` (21600), `endsongs`, `file_format_filter`,+`supports_observing`, `effective_license` (`tft` on free). Unregister:+`DELETE track-playback/v1/devices/{dev}` with body `seq_num`, `state_ref`, `sub_state`,+`previous_position`, `debug_source: "deregister"`.++### Join connect-state: `PUT {spclient}/connect-state/v1/devices/hobs_{dev35}`++Path id = `"hobs_" + first 35 chars of {dev}` (40 chars total). Header+`x-spotify-connection-id: {conn}`. Body:++```json+{"member_type": "CONNECT_STATE",+ "device": {"device_info": {"capabilities": {"can_be_player": false, "hidden": true,+ "needs_full_player_state": true}}}}+```++The hobs entry is a hidden observer; the real playable device is the track-playback+one. Response is the cluster JSON (same as GET below). Leave with+`DELETE connect-state/v1/devices/hobs_{dev35}` (204).++### `GET {spclient}/connect-state/v1/cluster`++Header `x-cache-hint`. Response: `timestamp`, `server_timestamp_ms`,+`active_device_id`, `devices` (map `{dev}` -> `can_play`, `volume` (0..65535), `name`,+`capabilities` (`can_be_player`, `is_controllable`, `volume_steps`, `supported_types`,+`command_acks`, `supports_*`...), `device_software_version`, `device_type`, `device_id`,+`client_id`, `brand`, `model`, `license`, `is_same_network`, `public_ip`),+`player_state`, `started_playing_at`, `need_full_player_state`,+`needs_state_updates`, `needs_local_devices`.++### Commands: `POST {spclient}/connect-state/v1/player/command/from/{dev}/to/{target}`++`from` = own device, `to` = target device (both own `{dev}` when playing locally).+Body `{"command": {"endpoint": "...", "logging_params": {"command_id": "<hex>", ...}, ...}}`.+Response `{"ack_id": "..."}`; the effect arrives as a dealer `track-playback/v1/command`+and a `connect-state/v1/cluster` push.++| endpoint | extra fields |+|---|---|+| `play` | `context` (`uri`, `url` = `context://{uri}`, `metadata`), `play_origin` (`feature_identifier`, `feature_version`, `referrer_identifier`), `options` (`license: "tft"`, `skip_to` {`track_index`/...}, `player_options_override`), `logging_params.page_instance_ids`, `interaction_ids` |+| `set_options` | `repeating_context`, `repeating_track` |+| `add_to_queue` | `track` (`uri`, `metadata.is_queued: "true"`, `provider: "queue"`) |++Volume: `PUT connect-state/v1/connect/volume/from/{dev}/to/{target}` body+`{"volume": 0..65535}` -> `{"ack_id"}`.++## Gaps++- Main entry bundle `web-player.{hash}.js` body not captured: 30 op hashes come only from+ requests, and their `query`/`mutation` kind and any never-called main-bundle ops are+ unknown. Re-capture it (or download it at refresh time) to complete the table.+- TOTP algorithm and secret behind `totp`/`totpVer` are not documented here (live in+ the page JS); without them `/api/token` needs a valid `sp_dc` cookie and fresh codes.+- Whether pathfinder or spclient accept a request without `client-token` was not tested.+- Error shapes: expired token (401), unknown persisted query, apresolve fallback were+ not observed.+- No gzip dealer payloads and no `type:"request"` dealer frames seen; Connect to+ another device (transfer, remote commands) not captured.+- Protobuf schemas of collection, playlist and herodotus pushes are only described by+ their visible fields.+- No connect-state command was seen for pause, resume, next or seek on the local device;+ those only showed `PUT track-playback/v1/devices/{dev}/state` reports (playback doc).diff --git a/docs/api/gql-variables-inferred.json b/docs/api/gql-variables-inferred.jsonnew file mode 100644index 00000000..0c91730e--- /dev/null+++ b/docs/api/gql-variables-inferred.json@@ -0,0 +1,1624 @@+{+ "ArtistConcerts": [],+ "ArtistConcertsPageLocation": [],+ "ConcertCampaign": [],+ "ConcertGallery": [],+ "SetItemsStateInWhatsNewFeed": [+ "animationData",+ "block",+ "children",+ "desiredLabel",+ "desiredSize",+ "desiredWidth",+ "forceNewExperience",+ "getRowText",+ "global",+ "height",+ "inline",+ "isOpen",+ "key",+ "path",+ "property",+ "renderNewExperience",+ "renderOldExperience",+ "target",+ "transitionTimingFunction",+ "variant"+ ],+ "accountAttributes": [],+ "addComment": [+ "entityUri",+ "text"+ ],+ "addCommentReaction": [+ "commentUri",+ "reactionUnicode"+ ],+ "addCommentReply": [+ "commentUri",+ "text"+ ],+ "addToLibrary": [+ "interactionId",+ "libraryItemUris"+ ],+ "addToPlaylist": [+ "interactionId",+ "newPosition",+ "playlistItemUris",+ "playlistUri"+ ],+ "addVenueToLibrary": [+ "venueUri"+ ],+ "albumPreRelease": [],+ "albumPreReleaseTracks": [+ "limit",+ "offset",+ "uri"+ ],+ "applyCurations": [+ "input"+ ],+ "applyCurationsV2": [+ "input"+ ],+ "areEntitiesInLibrary": [+ "uris"+ ],+ "assistedCurationSearch": [+ "term"+ ],+ "assistedCurationSearchAlbum": [+ "limit",+ "offset",+ "uris"+ ],+ "assistedCurationSearchArtist": [+ "limit",+ "offset",+ "topTracksLimit",+ "uris"+ ],+ "browseAll": [],+ "browsePage": [],+ "browseSection": [],+ "canvas": [+ "F",+ "K",+ "P",+ "_n",+ "async",+ "authorize",+ "cacheStatus",+ "cancellable",+ "children",+ "className",+ "configurable",+ "count",+ "customData",+ "data",+ "decode",+ "devicePixelRatio",+ "direction",+ "duration",+ "easing",+ "enabledCollectionIdsSet",+ "encode",+ "enumerable",+ "etag",+ "fill",+ "forget",+ "headers",+ "homeAd",+ "isRefreshing",+ "isRewriteImageSrcForPlatformEnabled",+ "isSaveDataEnabled",+ "isSessionOwner",+ "iterations",+ "keyAttrs",+ "keyMap",+ "ln",+ "maxStringLength",+ "mechanism",+ "metadata",+ "method",+ "onClick",+ "owner",+ "parseResponseHeaders",+ "parseUnknown",+ "passive",+ "payload",+ "range",+ "ref",+ "responseType",+ "saveSource",+ "seekTo",+ "sessionId",+ "setHomeAd",+ "size",+ "sourceContext",+ "synthetic",+ "users",+ "value",+ "viewKey",+ "writable"+ ],+ "centralisedStatePlayerOptions": [+ "deviceInfo",+ "uri"+ ],+ "changeAttributes": [+ "children",+ "input"+ ],+ "concert": [],+ "concertConcepts": [],+ "concertCount": [],+ "concertFeed": [],+ "concertLocationDetails": [],+ "concertLocationsByLatLon": [],+ "concertNotInterestedSet": [],+ "concertNotInterestedUndo": [],+ "concertRoutingCardVisuals": [],+ "countryHubContent": [],+ "countryHubsPage": [],+ "curateItems": [+ "input"+ ],+ "decorateContextEpisodesOrChapters": [+ "includeEpisodeContentRatingsV2",+ "uris"+ ],+ "decorateContextTracks": [+ "uris"+ ],+ "decorateQueuedByUsers": [],+ "deleteComment": [+ "commentUri"+ ],+ "deleteCommentReaction": [+ "commentUri",+ "fallback"+ ],+ "deleteCommentReply": [+ "replyUri"+ ],+ "deleteLocation": [],+ "editablePlaylists": [+ "features",+ "folderUri",+ "limit",+ "offset",+ "textFilter",+ "uris"+ ],+ "episodeSponsoredContent": [+ "J0RhdTt4GEF31Paju6QD",+ "J53K2EJtVyrqqDVTZ87Q",+ "JraMqx9ZQax6C3ZIaMn2",+ "Parent",+ "QmjlcIKAfV1i5f6Gjdas",+ "S",+ "ariaColIndex",+ "before",+ "capture",+ "children",+ "columnType",+ "durationThreshold",+ "lAoB7tmnqvsDRQg7GjYf",+ "m",+ "manual",+ "map",+ "once",+ "oyiGllT0XXVKM06Gqp2H",+ "p",+ "sf",+ "size",+ "synthetic",+ "uAitQqKNjqPhhjRFnFSN",+ "v",+ "value",+ "withPurge"+ ],+ "fetchEntitiesForRecentlyPlayed": [+ "uris"+ ],+ "fetchExtractedColorAndImageForAlbumEntity": [],+ "fetchExtractedColorAndImageForArtistEntity": [],+ "fetchExtractedColorAndImageForEpisodeEntity": [],+ "fetchExtractedColorAndImageForPlaylistEntity": [],+ "fetchExtractedColorAndImageForPodcastEntity": [],+ "fetchExtractedColorAndImageForTrackEntity": [],+ "fetchExtractedColorForAlbumEntity": [],+ "fetchExtractedColorForArtistEntity": [],+ "fetchExtractedColorForEpisodeEntity": [],+ "fetchExtractedColorForPlaylistEntity": [],+ "fetchExtractedColorForPodcastEntity": [],+ "fetchExtractedColorForTrackEntity": [],+ "fetchExtractedColors": [+ "F",+ "K",+ "P",+ "_n",+ "async",+ "authorize",+ "cacheStatus",+ "cancellable",+ "children",+ "className",+ "configurable",+ "count",+ "customData",+ "data",+ "decode",+ "devicePixelRatio",+ "direction",+ "duration",+ "easing",+ "enabledCollectionIdsSet",+ "encode",+ "enumerable",+ "etag",+ "fill",+ "forget",+ "headers",+ "homeAd",+ "isRefreshing",+ "isRewriteImageSrcForPlatformEnabled",+ "isSaveDataEnabled",+ "isSessionOwner",+ "iterations",+ "keyAttrs",+ "keyMap",+ "ln",+ "maxStringLength",+ "mechanism",+ "metadata",+ "method",+ "onClick",+ "owner",+ "parseResponseHeaders",+ "parseUnknown",+ "passive",+ "payload",+ "range",+ "ref",+ "responseType",+ "saveSource",+ "seekTo",+ "sessionId",+ "setHomeAd",+ "size",+ "sourceContext",+ "synthetic",+ "users",+ "value",+ "viewKey",+ "writable"+ ],+ "fetchLibraryTracks": [+ "limit",+ "offset"+ ],+ "fetchPlaylist": [+ "enableWatchFeedEntrypoint",+ "includeEpisodeContentRatingsV2",+ "limit",+ "offset",+ "uri"+ ],+ "fetchPlaylistContents": [+ "includeEpisodeContentRatingsV2",+ "limit",+ "offset",+ "uri"+ ],+ "fetchPlaylistMetadata": [+ "enableWatchFeedEntrypoint",+ "limit",+ "offset",+ "uri"+ ],+ "followUsers": [+ "usernames"+ ],+ "getAlbum": [+ "F",+ "K",+ "P",+ "_n",+ "async",+ "authorize",+ "cacheStatus",+ "cancellable",+ "children",+ "className",+ "configurable",+ "count",+ "customData",+ "data",+ "decode",+ "devicePixelRatio",+ "direction",+ "duration",+ "easing",+ "enabledCollectionIdsSet",+ "encode",+ "enumerable",+ "etag",+ "fill",+ "forget",+ "headers",+ "homeAd",+ "isRefreshing",+ "isRewriteImageSrcForPlatformEnabled",+ "isSaveDataEnabled",+ "isSessionOwner",+ "iterations",+ "keyAttrs",+ "keyMap",+ "ln",+ "maxStringLength",+ "mechanism",+ "metadata",+ "method",+ "onClick",+ "owner",+ "parseResponseHeaders",+ "parseUnknown",+ "passive",+ "payload",+ "range",+ "ref",+ "responseType",+ "saveSource",+ "seekTo",+ "sessionId",+ "setHomeAd",+ "size",+ "sourceContext",+ "synthetic",+ "users",+ "value",+ "viewKey",+ "writable"+ ],+ "getAlbumNameAndTracks": [+ "F",+ "K",+ "P",+ "_n",+ "async",+ "authorize",+ "cacheStatus",+ "cancellable",+ "children",+ "className",+ "configurable",+ "count",+ "customData",+ "data",+ "decode",+ "devicePixelRatio",+ "direction",+ "duration",+ "easing",+ "enabledCollectionIdsSet",+ "encode",+ "enumerable",+ "etag",+ "fill",+ "forget",+ "headers",+ "homeAd",+ "isRefreshing",+ "isRewriteImageSrcForPlatformEnabled",+ "isSaveDataEnabled",+ "isSessionOwner",+ "iterations",+ "keyAttrs",+ "keyMap",+ "ln",+ "maxStringLength",+ "mechanism",+ "metadata",+ "method",+ "onClick",+ "owner",+ "parseResponseHeaders",+ "parseUnknown",+ "passive",+ "payload",+ "range",+ "ref",+ "responseType",+ "saveSource",+ "seekTo",+ "sessionId",+ "setHomeAd",+ "size",+ "sourceContext",+ "synthetic",+ "users",+ "value",+ "viewKey",+ "writable"+ ],+ "getArtistNameAndTracks": [+ "F",+ "K",+ "P",+ "_n",+ "async",+ "authorize",+ "cacheStatus",+ "cancellable",+ "children",+ "className",+ "configurable",+ "count",+ "customData",+ "data",+ "decode",+ "devicePixelRatio",+ "direction",+ "duration",+ "easing",+ "enabledCollectionIdsSet",+ "encode",+ "enumerable",+ "etag",+ "fill",+ "forget",+ "headers",+ "homeAd",+ "isRefreshing",+ "isRewriteImageSrcForPlatformEnabled",+ "isSaveDataEnabled",+ "isSessionOwner",+ "iterations",+ "keyAttrs",+ "keyMap",+ "ln",+ "maxStringLength",+ "mechanism",+ "metadata",+ "method",+ "onClick",+ "owner",+ "parseResponseHeaders",+ "parseUnknown",+ "passive",+ "payload",+ "range",+ "ref",+ "responseType",+ "saveSource",+ "seekTo",+ "sessionId",+ "setHomeAd",+ "size",+ "sourceContext",+ "synthetic",+ "users",+ "value",+ "viewKey",+ "writable"+ ],+ "getAudiobooksMetadata": [+ "uris"+ ],+ "getCommentsForEntity": [+ "token",+ "uri"+ ],+ "getDynamicColorsByUris": [+ "F",+ "K",+ "P",+ "_n",+ "async",+ "authorize",+ "cacheStatus",+ "cancellable",+ "children",+ "className",+ "configurable",+ "count",+ "customData",+ "data",+ "decode",+ "devicePixelRatio",+ "direction",+ "duration",+ "easing",+ "enabledCollectionIdsSet",+ "encode",+ "enumerable",+ "etag",+ "fill",+ "forget",+ "headers",+ "homeAd",+ "isRefreshing",+ "isRewriteImageSrcForPlatformEnabled",+ "isSaveDataEnabled",+ "isSessionOwner",+ "iterations",+ "keyAttrs",+ "keyMap",+ "ln",+ "maxStringLength",+ "mechanism",+ "metadata",+ "method",+ "onClick",+ "owner",+ "parseResponseHeaders",+ "parseUnknown",+ "passive",+ "payload",+ "range",+ "ref",+ "responseType",+ "saveSource",+ "seekTo",+ "sessionId",+ "setHomeAd",+ "size",+ "sourceContext",+ "synthetic",+ "users",+ "value",+ "viewKey",+ "writable"+ ],+ "getEpisodeName": [+ "F",+ "K",+ "P",+ "_n",+ "async",+ "authorize",+ "cacheStatus",+ "cancellable",+ "children",+ "className",+ "configurable",+ "count",+ "customData",+ "data",+ "decode",+ "devicePixelRatio",+ "direction",+ "duration",+ "easing",+ "enabledCollectionIdsSet",+ "encode",+ "enumerable",+ "etag",+ "fill",+ "forget",+ "headers",+ "homeAd",+ "isRefreshing",+ "isRewriteImageSrcForPlatformEnabled",+ "isSaveDataEnabled",+ "isSessionOwner",+ "iterations",+ "keyAttrs",+ "keyMap",+ "ln",+ "maxStringLength",+ "mechanism",+ "metadata",+ "method",+ "onClick",+ "owner",+ "parseResponseHeaders",+ "parseUnknown",+ "passive",+ "payload",+ "range",+ "ref",+ "responseType",+ "saveSource",+ "seekTo",+ "sessionId",+ "setHomeAd",+ "size",+ "sourceContext",+ "synthetic",+ "users",+ "value",+ "viewKey",+ "writable"+ ],+ "getEpisodeOrChapter": [+ "includeEpisodeContentRatingsV2",+ "uri"+ ],+ "getLists": [+ "limit",+ "offset",+ "uris"+ ],+ "getListsContents": [+ "limit",+ "offset",+ "uris"+ ],+ "getListsMetadata": [+ "uris"+ ],+ "getPodcastOrBookName": [+ "F",+ "K",+ "P",+ "_n",+ "async",+ "authorize",+ "cacheStatus",+ "cancellable",+ "children",+ "className",+ "configurable",+ "count",+ "customData",+ "data",+ "decode",+ "devicePixelRatio",+ "direction",+ "duration",+ "easing",+ "enabledCollectionIdsSet",+ "encode",+ "enumerable",+ "etag",+ "fill",+ "forget",+ "headers",+ "homeAd",+ "isRefreshing",+ "isRewriteImageSrcForPlatformEnabled",+ "isSaveDataEnabled",+ "isSessionOwner",+ "iterations",+ "keyAttrs",+ "keyMap",+ "ln",+ "maxStringLength",+ "mechanism",+ "metadata",+ "method",+ "onClick",+ "owner",+ "parseResponseHeaders",+ "parseUnknown",+ "passive",+ "payload",+ "range",+ "ref",+ "responseType",+ "saveSource",+ "seekTo",+ "sessionId",+ "setHomeAd",+ "size",+ "sourceContext",+ "synthetic",+ "users",+ "value",+ "viewKey",+ "writable"+ ],+ "getReactions": [+ "reactionUnicode",+ "token",+ "uri"+ ],+ "getReplies": [+ "commentUri",+ "pageToken"+ ],+ "getTrack": [+ "J0RhdTt4GEF31Paju6QD",+ "J53K2EJtVyrqqDVTZ87Q",+ "JraMqx9ZQax6C3ZIaMn2",+ "Parent",+ "QmjlcIKAfV1i5f6Gjdas",+ "S",+ "ariaColIndex",+ "before",+ "capture",+ "children",+ "columnType",+ "durationThreshold",+ "lAoB7tmnqvsDRQg7GjYf",+ "m",+ "manual",+ "map",+ "once",+ "oyiGllT0XXVKM06Gqp2H",+ "p",+ "sf",+ "size",+ "synthetic",+ "uAitQqKNjqPhhjRFnFSN",+ "v",+ "value",+ "withPurge"+ ],+ "getTrackName": [+ "F",+ "K",+ "P",+ "_n",+ "async",+ "authorize",+ "cacheStatus",+ "cancellable",+ "children",+ "className",+ "configurable",+ "count",+ "customData",+ "data",+ "decode",+ "devicePixelRatio",+ "direction",+ "duration",+ "easing",+ "enabledCollectionIdsSet",+ "encode",+ "enumerable",+ "etag",+ "fill",+ "forget",+ "headers",+ "homeAd",+ "isRefreshing",+ "isRewriteImageSrcForPlatformEnabled",+ "isSaveDataEnabled",+ "isSessionOwner",+ "iterations",+ "keyAttrs",+ "keyMap",+ "ln",+ "maxStringLength",+ "mechanism",+ "metadata",+ "method",+ "onClick",+ "owner",+ "parseResponseHeaders",+ "parseUnknown",+ "passive",+ "payload",+ "range",+ "ref",+ "responseType",+ "saveSource",+ "seekTo",+ "sessionId",+ "setHomeAd",+ "size",+ "sourceContext",+ "synthetic",+ "users",+ "value",+ "viewKey",+ "writable"+ ],+ "getVideoTrackAssociatedAlbum": [+ "J0RhdTt4GEF31Paju6QD",+ "J53K2EJtVyrqqDVTZ87Q",+ "JraMqx9ZQax6C3ZIaMn2",+ "Parent",+ "QmjlcIKAfV1i5f6Gjdas",+ "S",+ "ariaColIndex",+ "before",+ "capture",+ "children",+ "columnType",+ "durationThreshold",+ "lAoB7tmnqvsDRQg7GjYf",+ "m",+ "manual",+ "map",+ "once",+ "oyiGllT0XXVKM06Gqp2H",+ "p",+ "sf",+ "size",+ "synthetic",+ "uAitQqKNjqPhhjRFnFSN",+ "v",+ "value",+ "withPurge"+ ],+ "home": [+ "J0RhdTt4GEF31Paju6QD",+ "J53K2EJtVyrqqDVTZ87Q",+ "JraMqx9ZQax6C3ZIaMn2",+ "Parent",+ "QmjlcIKAfV1i5f6Gjdas",+ "S",+ "ariaColIndex",+ "before",+ "capture",+ "children",+ "columnType",+ "durationThreshold",+ "lAoB7tmnqvsDRQg7GjYf",+ "m",+ "manual",+ "map",+ "once",+ "oyiGllT0XXVKM06Gqp2H",+ "p",+ "sf",+ "size",+ "synthetic",+ "uAitQqKNjqPhhjRFnFSN",+ "v",+ "value",+ "withPurge"+ ],+ "homePinnedSections": [+ "actions",+ "adaptive",+ "app",+ "appUri",+ "children",+ "creativeId",+ "current",+ "durationThreshold",+ "enableLogs",+ "formats",+ "getItemKey",+ "isTouching",+ "locale",+ "offsets",+ "openContextMenu",+ "position",+ "replace",+ "roundOffsets",+ "setIsTouching",+ "state",+ "totalCount",+ "triggers",+ "uri",+ "value"+ ],+ "homeSection": [+ "animationData",+ "block",+ "children",+ "desiredLabel",+ "desiredSize",+ "desiredWidth",+ "forceNewExperience",+ "getRowText",+ "global",+ "height",+ "inline",+ "isOpen",+ "key",+ "path",+ "property",+ "renderNewExperience",+ "renderOldExperience",+ "target",+ "transitionTimingFunction",+ "variant"+ ],+ "inferredUserLocation": [],+ "internalLinkRecommenderEpisode": [+ "children"+ ],+ "internalLinkRecommenderShow": [],+ "internalLinkRecommenderTrack": [+ "creator",+ "isSmallIcon",+ "leading",+ "onClick",+ "prefix",+ "suffix"+ ],+ "isCurated": [+ "uris"+ ],+ "isCuratedEntities": [+ "uris"+ ],+ "isFollowingUsers": [+ "uris"+ ],+ "libraryV3": [+ "expandedFolders",+ "features",+ "filters",+ "flatten",+ "folderUri",+ "includeFoldersWhenFlattening",+ "limit",+ "offset",+ "order",+ "textFilter"+ ],+ "lookupChildEntities": [],+ "lookupDebug": [],+ "lookupEntityImages": [],+ "moveItemsInPlaylist": [+ "newPosition",+ "playlistUri",+ "uids"+ ],+ "npvPageContent": [+ "J0RhdTt4GEF31Paju6QD",+ "J53K2EJtVyrqqDVTZ87Q",+ "JraMqx9ZQax6C3ZIaMn2",+ "Parent",+ "QmjlcIKAfV1i5f6Gjdas",+ "S",+ "ariaColIndex",+ "before",+ "capture",+ "children",+ "columnType",+ "durationThreshold",+ "lAoB7tmnqvsDRQg7GjYf",+ "m",+ "manual",+ "map",+ "once",+ "oyiGllT0XXVKM06Gqp2H",+ "p",+ "sf",+ "size",+ "synthetic",+ "uAitQqKNjqPhhjRFnFSN",+ "v",+ "value",+ "withPurge"+ ],+ "npvV2TrackSupplementalSections": [],+ "pinLibraryItem": [+ "pinnableItemUri"+ ],+ "playlistPermissions": [+ "uri"+ ],+ "playlistSection": [],+ "profileAttributes": [],+ "queryAlbumMerch": [],+ "queryAlbumTrackUris": [+ "F",+ "K",+ "P",+ "_n",+ "async",+ "authorize",+ "cacheStatus",+ "cancellable",+ "children",+ "className",+ "configurable",+ "count",+ "customData",+ "data",+ "decode",+ "devicePixelRatio",+ "direction",+ "duration",+ "easing",+ "enabledCollectionIdsSet",+ "encode",+ "enumerable",+ "etag",+ "fill",+ "forget",+ "headers",+ "homeAd",+ "isRefreshing",+ "isRewriteImageSrcForPlatformEnabled",+ "isSaveDataEnabled",+ "isSessionOwner",+ "iterations",+ "keyAttrs",+ "keyMap",+ "ln",+ "maxStringLength",+ "mechanism",+ "metadata",+ "method",+ "onClick",+ "owner",+ "parseResponseHeaders",+ "parseUnknown",+ "passive",+ "payload",+ "range",+ "ref",+ "responseType",+ "saveSource",+ "seekTo",+ "sessionId",+ "setHomeAd",+ "size",+ "sourceContext",+ "synthetic",+ "users",+ "value",+ "viewKey",+ "writable"+ ],+ "queryAlbumTracks": [+ "J0RhdTt4GEF31Paju6QD",+ "J53K2EJtVyrqqDVTZ87Q",+ "JraMqx9ZQax6C3ZIaMn2",+ "Parent",+ "QmjlcIKAfV1i5f6Gjdas",+ "S",+ "ariaColIndex",+ "before",+ "capture",+ "children",+ "columnType",+ "durationThreshold",+ "lAoB7tmnqvsDRQg7GjYf",+ "m",+ "manual",+ "map",+ "once",+ "oyiGllT0XXVKM06Gqp2H",+ "p",+ "sf",+ "size",+ "synthetic",+ "uAitQqKNjqPhhjRFnFSN",+ "v",+ "value",+ "withPurge"+ ],+ "queryArtistAboutModal": [],+ "queryArtistAppearsOn": [],+ "queryArtistDiscographyAlbums": [+ "limit",+ "offset",+ "order",+ "uri"+ ],+ "queryArtistDiscographyAll": [+ "limit",+ "offset",+ "order",+ "uri"+ ],+ "queryArtistDiscographyCompilations": [+ "limit",+ "offset",+ "order",+ "uri"+ ],+ "queryArtistDiscographyOverview": [],+ "queryArtistDiscographySingles": [+ "limit",+ "offset",+ "order",+ "uri"+ ],+ "queryArtistDiscoveredOn": [],+ "queryArtistFeaturing": [],+ "queryArtistMinimal": [],+ "queryArtistOverview": [+ "G2",+ "animated",+ "ariaLabel",+ "attributes",+ "borderRadius",+ "children",+ "className",+ "colorSet",+ "contentLabel",+ "correlationId",+ "countryHub",+ "defaultProps",+ "event",+ "excludePlanLinks",+ "global",+ "gn",+ "impressionRef",+ "isOpen",+ "language",+ "locationKey",+ "lyricsHub",+ "market",+ "name",+ "onOpen",+ "onRequestClose",+ "op",+ "openContextMenu",+ "openUrlLocale",+ "pathname",+ "role",+ "routeName",+ "shouldCloseOnEsc",+ "shouldCloseOnOverlayClick",+ "size",+ "span",+ "status",+ "sv",+ "updateProps",+ "uri"+ ],+ "queryArtistPlaylists": [],+ "queryArtistRelated": [],+ "queryArtistRelatedVideos": [],+ "queryBookChapters": [+ "limit",+ "offset",+ "uri"+ ],+ "queryInlineCurationSearchAlbum": [+ "limit",+ "offset",+ "uris"+ ],+ "queryInlineCurationSearchArtist": [+ "limit",+ "offset",+ "uris"+ ],+ "queryInlineCurationSearchV2": [],+ "queryInlineCurationSearchV2Booklists": [],+ "queryMoreByArtist": [],+ "queryNpvArtist": [+ "animationData",+ "block",+ "children",+ "desiredLabel",+ "desiredSize",+ "desiredWidth",+ "forceNewExperience",+ "getRowText",+ "global",+ "height",+ "inline",+ "isOpen",+ "key",+ "path",+ "property",+ "renderNewExperience",+ "renderOldExperience",+ "target",+ "transitionTimingFunction",+ "variant"+ ],+ "queryNpvEpisode": [+ "animationData",+ "block",+ "children",+ "desiredLabel",+ "desiredSize",+ "desiredWidth",+ "forceNewExperience",+ "getRowText",+ "global",+ "height",+ "inline",+ "isOpen",+ "key",+ "path",+ "property",+ "renderNewExperience",+ "renderOldExperience",+ "target",+ "transitionTimingFunction",+ "variant"+ ],+ "queryPodcastEpisodes": [+ "includeEpisodeContentRatingsV2",+ "limit",+ "offset",+ "uri",+ "variant"+ ],+ "queryShowMetadataV2": [+ "includeContentCapabilityTrait",+ "includeEpisodeContentRatingsV2",+ "uri"+ ],+ "queryTrackArtists": [+ "J0RhdTt4GEF31Paju6QD",+ "J53K2EJtVyrqqDVTZ87Q",+ "JraMqx9ZQax6C3ZIaMn2",+ "Parent",+ "QmjlcIKAfV1i5f6Gjdas",+ "S",+ "ariaColIndex",+ "before",+ "capture",+ "children",+ "columnType",+ "durationThreshold",+ "lAoB7tmnqvsDRQg7GjYf",+ "m",+ "manual",+ "map",+ "once",+ "oyiGllT0XXVKM06Gqp2H",+ "p",+ "sf",+ "size",+ "synthetic",+ "uAitQqKNjqPhhjRFnFSN",+ "v",+ "value",+ "withPurge"+ ],+ "queryTrackCreditsGroupedModal": [],+ "queryWhatsNewFeed": [+ "F",+ "K",+ "P",+ "_n",+ "async",+ "authorize",+ "cacheStatus",+ "cancellable",+ "children",+ "className",+ "configurable",+ "count",+ "customData",+ "data",+ "decode",+ "devicePixelRatio",+ "direction",+ "duration",+ "easing",+ "enabledCollectionIdsSet",+ "encode",+ "enumerable",+ "etag",+ "fill",+ "forget",+ "headers",+ "homeAd",+ "isRefreshing",+ "isRewriteImageSrcForPlatformEnabled",+ "isSaveDataEnabled",+ "isSessionOwner",+ "iterations",+ "keyAttrs",+ "keyMap",+ "ln",+ "maxStringLength",+ "mechanism",+ "metadata",+ "method",+ "onClick",+ "owner",+ "parseResponseHeaders",+ "parseUnknown",+ "passive",+ "payload",+ "range",+ "ref",+ "responseType",+ "saveSource",+ "seekTo",+ "sessionId",+ "setHomeAd",+ "size",+ "sourceContext",+ "synthetic",+ "users",+ "value",+ "viewKey",+ "writable"+ ],+ "recentSearches": [+ "adsEnabled",+ "attributes",+ "children",+ "className",+ "firstIndex",+ "heights",+ "hideLegalLinks",+ "hideWebPlayerLink",+ "index",+ "initialIntersectionEnd",+ "initialIntersectionStart",+ "isDesktop",+ "isDeveloperMode",+ "itemsInNode",+ "layoutDelegate",+ "listRef",+ "menu",+ "name",+ "normalizedRequest",+ "offer",+ "onBrowserNotSupported",+ "onClose",+ "parentSampleRate",+ "parentSampled",+ "ref",+ "root",+ "rootMargin",+ "scrollTarget",+ "shouldMountLeaderboard",+ "step",+ "title",+ "titleVariant",+ "type",+ "uri",+ "variableColumnIndex"+ ],+ "recents": [+ "limit",+ "offset",+ "uris"+ ],+ "removeFromLibrary": [+ "libraryItemUris"+ ],+ "removeFromPlaylist": [+ "playlistUri",+ "uids"+ ],+ "removeRecentSearches": [+ "animated",+ "attachStacktrace",+ "blockDismissClickPropagation",+ "childRef",+ "children",+ "className",+ "client",+ "contentLabel",+ "desiredLabel",+ "desiredSize",+ "error",+ "eventType",+ "hasNewEpisodeIndicator",+ "iconSize",+ "isEpisode",+ "isHero",+ "isOpen",+ "isPresent",+ "isVideo",+ "loading",+ "menuRef",+ "meta",+ "onClick",+ "onHide",+ "onHideHandler",+ "onMouseEnter",+ "onMouseLeave",+ "onRequestClose",+ "onRetry",+ "portalContainer",+ "preventScrollingWhileOpen",+ "queryKey",+ "search",+ "shouldCloseOnEsc",+ "shouldCloseOnOverlayClick",+ "signal",+ "sizeRef",+ "stackParser",+ "tippyInstance",+ "title",+ "to",+ "trailing",+ "trigger",+ "type",+ "uri",+ "uris"+ ],+ "removeVenueFromLibrary": [+ "venueUri"+ ],+ "requestPromoCode": [+ "accessCode"+ ],+ "saveLocation": [+ "geonameId"+ ],+ "saveRecentSearches": [+ "LeadingIcon",+ "S1e1CMZw660SyWLRfsJe",+ "beforeSpanEnd",+ "childList",+ "childSpanTimeout",+ "children",+ "ddkUlF8iWjJMAL8LpWKy",+ "disableAutoFinish",+ "estimatedHeight",+ "fanOut",+ "finalTimeout",+ "firstIndex",+ "heights",+ "idleTimeout",+ "index",+ "initialIntersectionEnd",+ "initialIntersectionStart",+ "itemsInNode",+ "listRef",+ "loading",+ "name",+ "nonInteractive",+ "nrInitialInView",+ "nrRowsOverscan",+ "onRequestSpanEnd",+ "once",+ "propagateTraceparent",+ "renderItem",+ "renderPlaceholder",+ "renderTrailing",+ "scrollNodeRef",+ "scrollTarget",+ "subtree",+ "sxH_zmHASJlZuyeyFumQ",+ "textVariant",+ "trimIdleSpanEndTimestamp",+ "uri",+ "uris"+ ],+ "searchAlbums": [],+ "searchArtists": [],+ "searchAudiobooks": [],+ "searchAuthors": [],+ "searchConcertLocations": [],+ "searchDesktop": [],+ "searchEpisodes": [],+ "searchFullEpisodes": [],+ "searchGenres": [],+ "searchModalEntityPage": [],+ "searchModalResults": [],+ "searchPlaylists": [],+ "searchPodcasts": [],+ "searchSuggestions": [],+ "searchTopResultsList": [],+ "searchTopResultsOnly": [],+ "searchTracks": [],+ "searchUsers": [],+ "seoRecommendedTrackPlaylistDesktop": [+ "LeadingIcon",+ "S1e1CMZw660SyWLRfsJe",+ "beforeSpanEnd",+ "childList",+ "childSpanTimeout",+ "children",+ "ddkUlF8iWjJMAL8LpWKy",+ "disableAutoFinish",+ "estimatedHeight",+ "fanOut",+ "finalTimeout",+ "firstIndex",+ "heights",+ "idleTimeout",+ "index",+ "initialIntersectionEnd",+ "initialIntersectionStart",+ "itemsInNode",+ "listRef",+ "loading",+ "name",+ "nonInteractive",+ "nrInitialInView",+ "nrRowsOverscan",+ "onRequestSpanEnd",+ "once",+ "propagateTraceparent",+ "renderItem",+ "renderPlaceholder",+ "renderTrailing",+ "scrollNodeRef",+ "scrollTarget",+ "subtree",+ "sxH_zmHASJlZuyeyFumQ",+ "textVariant",+ "trimIdleSpanEndTimestamp",+ "uri",+ "uris"+ ],+ "showItemsPlayedState": [],+ "similarAlbumsBasedOnThisTrack": [+ "G2",+ "animated",+ "ariaLabel",+ "attributes",+ "borderRadius",+ "children",+ "className",+ "colorSet",+ "contentLabel",+ "correlationId",+ "countryHub",+ "defaultProps",+ "event",+ "excludePlanLinks",+ "global",+ "gn",+ "impressionRef",+ "isOpen",+ "language",+ "locationKey",+ "lyricsHub",+ "market",+ "name",+ "onOpen",+ "onRequestClose",+ "op",+ "openContextMenu",+ "openUrlLocale",+ "pathname",+ "role",+ "routeName",+ "shouldCloseOnEsc",+ "shouldCloseOnOverlayClick",+ "size",+ "span",+ "status",+ "sv",+ "updateProps",+ "uri"+ ],+ "similarAudiobooks": [],+ "smartShuffle": [+ "uris"+ ],+ "thisisPlaylistExtension": [],+ "trackPreview": [+ "ariaColIndex",+ "children",+ "className",+ "columnType",+ "size"+ ],+ "undoConcertCampaignNotInterested": [],+ "unfollowUsers": [+ "usernames"+ ],+ "unpinLibraryItem": [+ "pinnableItemUri"+ ],+ "userAccountId": [],+ "userLocation": [],+ "userTopContent": [],+ "venue": [],+ "watchFeedEntity": [],+ "watchFeedView": [],+ "whatsNewFeedNewItems": [+ "J0RhdTt4GEF31Paju6QD",+ "J53K2EJtVyrqqDVTZ87Q",+ "JraMqx9ZQax6C3ZIaMn2",+ "Parent",+ "QmjlcIKAfV1i5f6Gjdas",+ "S",+ "ariaColIndex",+ "before",+ "capture",+ "children",+ "columnType",+ "durationThreshold",+ "lAoB7tmnqvsDRQg7GjYf",+ "m",+ "manual",+ "map",+ "once",+ "oyiGllT0XXVKM06Gqp2H",+ "p",+ "sf",+ "size",+ "synthetic",+ "uAitQqKNjqPhhjRFnFSN",+ "v",+ "value",+ "withPurge"+ ]+}\ No newline at end of filediff --git a/docs/api/gql-variables.json b/docs/api/gql-variables.jsonnew file mode 100644index 00000000..9d6dee7d--- /dev/null+++ b/docs/api/gql-variables.json@@ -0,0 +1,948 @@+{+ "accountAttributes": {+ "variables": [],+ "example": {}+ },+ "addToLibrary": {+ "variables": [+ "interactionId",+ "libraryItemUris"+ ],+ "example": {+ "libraryItemUris": [+ "spotify:artist:1McMsnEElThX1knmY4oliG"+ ],+ "interactionId": "{uuid}"+ }+ },+ "addToPlaylist": {+ "variables": [+ "interactionId",+ "newPosition",+ "playlistItemUris",+ "playlistUri"+ ],+ "example": {+ "playlistItemUris": [+ "spotify:track:70cHKK8bHAfJrOGVnfRG9J"+ ],+ "playlistUri": "spotify:playlist:52t4IPlr6627H1STRh2FGW",+ "newPosition": {+ "moveType": "BOTTOM_OF_PLAYLIST",+ "fromUid": null+ },+ "interactionId": "{uuid}"+ }+ },+ "applyCurations": {+ "variables": [+ "input"+ ],+ "example": {+ "input": {+ "curations": [+ {+ "contextUri": "spotify:playlist:37i9dQZF1F5p3rmiWPIYgZ",+ "curationType": "UNCURATE"+ }+ ],+ "itemUris": [+ "spotify:track:4EoJ151oQ5jY48z4RhSE96"+ ]+ }+ }+ },+ "areEntitiesInLibrary": {+ "variables": [+ "uris"+ ],+ "example": {+ "uris": [+ "spotify:episode:7kDlpm1xDML49QuzV4Hbs2",+ "spotify:episode:3KNbJvoYkXN9hgfeUXYigS",+ "spotify:episode:5Ayc3yoBQ9OaGD3sSLVvMi",+ "spotify:episode:53iR7S2IWbKAOXEVVEnagR",+ "spotify:episode:3zYi5sHNNcdkDyPaIiRcI4",+ "spotify:episode:2HLbu2WV35q1RbvBnNiMhb",+ "spotify:episode:1R1SJeNffUTr9iILWo3dxy",+ "spotify:episode:1amTi28juSptAkSJsASBBH",+ "spotify:episode:2Fcp88MiSafUs7Yl1Y4vdE",+ "spotify:episode:4YT81bGQeeqYz4hJeUygTb",+ "spotify:episode:3fpHVxurRyluUe6MfKPtuJ",+ "spotify:episode:6PwAQQh30IXdo5WaclPunu",+ "spotify:episode:0CWZGCQb4YVzmiNVE8Pifk",+ "spotify:episode:6YxqbXZXUbwEyYnFtJ15kS",+ "spotify:episode:5X3Vy1L4OThzBHOZRdNO09",+ "spotify:episode:6JYEre5sEc74iYYe0ZTVh6",+ "spotify:episode:41Li1M34WY9cVxtJx6jLax",+ "spotify:episode:0tnkdp6hDPCPQqqY0wdkdy",+ "spotify:episode:2yOfsFdSqAWanRXJmaIBSs",+ "spotify:episode:6ZpTA2OLRsgBV3G1uN4pYC",+ "spotify:episode:5oyGgLLKJIn6VnDS1VLE7D",+ "spotify:episode:0vKWNw6P3xwHZ38WX6Yfax",+ "spotify:episode:1kuZLSHJX1z6Skt1TMvylC",+ "spotify:episode:6SC8ZvVLN3CeTwuVVuknSr",+ "spotify:episode:754xT5eYoIcrkAK7xCMTZt",+ "spotify:episode:7nk9DgyoB6zcPCdYohJ1F3",+ "spotify:episode:0LHIqeO20ni8JNtxH43MgM",+ "spotify:episode:1fPQFzXXsWqH22ewAmTZJF",+ "spotify:episode:2SAplEelVg0yH1ktmjjc1V",+ "spotify:episode:1CqBVw0GntNd4FLMCLEjWl"+ ]+ }+ },+ "browseAll": {+ "variables": [+ "browseEndUserIntegration",+ "pagePagination",+ "sectionPagination"+ ],+ "example": {+ "pagePagination": {+ "offset": 0,+ "limit": 10+ },+ "sectionPagination": {+ "offset": 0,+ "limit": 99+ },+ "browseEndUserIntegration": "INTEGRATION_WEB_PLAYER"+ }+ },+ "browsePage": {+ "variables": [+ "browseEndUserIntegration",+ "includeEpisodeContentRatingsV2",+ "pagePagination",+ "sectionPagination",+ "uri"+ ],+ "example": {+ "pagePagination": {+ "offset": 0,+ "limit": 10+ },+ "sectionPagination": {+ "offset": 0,+ "limit": 10+ },+ "uri": "spotify:page:0JQ5DAqbMKFSi39LMRT0Cy",+ "browseEndUserIntegration": "INTEGRATION_WEB_PLAYER",+ "includeEpisodeContentRatingsV2": true+ }+ },+ "canvas": {+ "variables": [+ "trackUri"+ ],+ "example": {+ "trackUri": "spotify:track:55vPnuXfuzXNW75JpuSczF"+ }+ },+ "centralisedStatePlayerOptions": {+ "variables": [+ "deviceInfo",+ "uri"+ ],+ "example": {+ "uri": "spotify:list:popular-release-segments-main-roles:artist_1McMsnEElThX1knmY4oliG",+ "deviceInfo": {+ "deviceId": "c7e057a5c00d8662d2f203890086709b4bdc1745",+ "deviceType": "computer",+ "clientId": "d8a5ed958d274c2e8ee717e6a4b0971d",+ "clientVersion": "1.3.6.1858.gc66299947cb4",+ "productId": "1"+ }+ }+ },+ "decorateContextTracks": {+ "variables": [+ "uris"+ ],+ "example": {+ "uris": [+ "spotify:track:55vPnuXfuzXNW75JpuSczF",+ "spotify:track:0T1CzbjyOEU60cL5G244di",+ "spotify:track:6AoOzPhqx5LbtYfKBlBrEG",+ "spotify:track:0tlpV1zgFg5iFrj1cIwQhn",+ "spotify:track:4frYOVaMfQ7iyvKLehnARi",+ "spotify:track:7heoPFrtuH6JU6AcfzjWHp",+ "spotify:track:5TVOGVhEQNEdnkVYCtE5p5",+ "spotify:track:6FAoIVpBja2wbmPEP6gKat",+ "spotify:track:30RmEyZdIYdYpSTkMtgtKt",+ "spotify:track:2toEys3zZ8rRB242Na7FZh",+ "spotify:track:3cWjdZ42pKynP9yOt6xlnA",+ "spotify:track:3CBjC9bcb5MzAnP4Hu9SVL",+ "spotify:track:0frABA1e4eX0HKmEFxtkEC",+ "spotify:track:6QEvbmv2euCQxX54gjlarO",+ "spotify:track:0FbNxtUbetsjF7s42pkOIS",+ "spotify:track:7xWvRVssTTECvWCDNgCzSH",+ "spotify:track:5rKSFzy6TQtPX71xTw6k9P",+ "spotify:track:656vbT8JKkVx7g1yG12L89",+ "spotify:track:2TL8q8EO60b9lWeozfqYnG",+ "spotify:track:0p1jyG640jfYCes1EagSsU",+ "spotify:track:5nODbxjT7KZt9cUX0xJwQs",+ "spotify:track:7p6NSzWnUxZCkae3UIj0aY",+ "spotify:track:3nq3hIQOwKHRgd44Y06Ijq",+ "spotify:track:5xYNLzZzgN3r6YPcQgNcJD",+ "spotify:track:0doFYnqgcStWu1Emh8DTVo",+ "spotify:track:3nR6ytbSKOF4NxsgqrYG9u",+ "spotify:track:4cSHMHSTRhetAtT1iDP2zO",+ "spotify:track:6YG2IJB93if1Cv8QxNHesA",+ "spotify:track:7gmwFiZtsPyBT8wI2u6mGN",+ "spotify:track:3fXieGSDq0uwQP7vM7zoZH",+ "spotify:track:3ReDT1HLea9eTWEPtwE7fP",+ "spotify:track:6nkFbmDY84a9rejFSbIMdj",+ "spotify:track:4jgj7dTIByN8OXmX4s9QHI",+ "spotify:track:1IrZSqnG09Mtfe2L399cNj",+ "spotify:track:7CUAGxYmpmSJv9pbLgqVjy",+ "spotify:track:4sLFiAxqRm0DYjUfdWznXI",+ "spotify:track:48aYpdLDRq1aJKHRhineq6",+ "spotify:track:5pZJSiwMzuiwP4AIlNbRDZ",+ "spotify:track:6qvyN6NTUpdfOJRYjtSSd7",+ "spotify:track:3Lgri1rcCPb99ezlE0SWTB",+ "spotify:track:2oe4ERf40Mx8PWH9gtEfP0",+ "spotify:track:1aLHvqPB5CxGYzhJB7Hzo1",+ "spotify:track:0EudwuzwEbV7YA1LLwwIbv",+ "spotify:track:4cLspfLk7lebgQMDoZgSKD",+ "spotify:track:3gAEAmxdP1GIjgQ3Zud2mE",+ "spotify:track:22NVP1etEr1pJEBQMk7E0C",+ "spotify:track:7MqfFNdKFJMgLrmDXE7rAK",+ "spotify:track:50MqZttaClW6PjgsugWGlg",+ "spotify:track:7J9bfRJYMHLAWpAvwSxCxG",+ "spotify:track:1pqKCnjkTBcAX6NyzSDahf"+ ]+ }+ },+ "decorateQueuedByUsers": {+ "variables": [+ "userUris"+ ],+ "example": {+ "userUris": [+ "spotify:user:{user}"+ ]+ }+ },+ "editablePlaylists": {+ "variables": [+ "limit",+ "offset",+ "textFilter",+ "uris"+ ],+ "example": {+ "offset": 0,+ "limit": 50,+ "textFilter": "",+ "uris": [+ "spotify:track:4EoJ151oQ5jY48z4RhSE96"+ ]+ }+ },+ "feedBaselineLookup": {+ "variables": [+ "uris"+ ],+ "example": {+ "uris": [+ "spotify:playlist:37i9dQZF1E4qQ00I1Jm1ay",+ "spotify:playlist:37i9dQZF1DX9PXZbuB8BjJ",+ "spotify:playlist:37i9dQZF1EVCqfmnWEJPpr",+ "spotify:playlist:37i9dQZF1EVCu9jtlIEnHS",+ "spotify:playlist:37i9dQZF1EVvSIodzFd4uc",+ "spotify:playlist:37i9dQZF1DX7QOv5kjbU68",+ "spotify:playlist:37i9dQZF1EQn2GRFTFMl2A",+ "spotify:playlist:37i9dQZF1DWVuV87wUBNwc",+ "spotify:episode:7JZaK08295jcCEOILldiQS",+ "spotify:playlist:37i9dQZF1DX4kZR8vL5oVX",+ "spotify:playlist:37i9dQZF1EQpVaHRDcozEz",+ "spotify:playlist:37i9dQZF1DXdl6IPOySdX4",+ "spotify:playlist:37i9dQZF1DX69KJk2S04Hp",+ "spotify:playlist:37i9dQZF1DWXPFuOz52Hlf",+ "spotify:playlist:37i9dQZF1DXcSPhLAnCjoM",+ "spotify:playlist:37i9dQZF1DX5Ejj0EkURtP",+ "spotify:episode:6Bb5NoU1eC1OoHyh07qzms",+ "spotify:episode:5EkhsZITSLURnLCPci72MA",+ "spotify:episode:6LzXq0L7CM90uEMeWmcBxO"+ ]+ }+ },+ "fetchEntitiesForRecentlyPlayed": {+ "variables": [+ "uris"+ ],+ "example": {+ "uris": [+ "spotify:playlist:37i9dQZF1EIZKQBmjpvc47"+ ]+ }+ },+ "fetchExtractedColors": {+ "variables": [+ "imageUris"+ ],+ "example": {+ "imageUris": [+ "https://pickasso.spotifycdn.com/image/ab67c0de0000deef/dt/v1/img/artistmix/7rz6ZZErn5YFDteXKhyf3g/fr",+ "https://pickasso.spotifycdn.com/image/ab67c0de0000deef/dt/v1/img/radio/artist/7rz6ZZErn5YFDteXKhyf3g/fr"+ ]+ }+ },+ "fetchPlaylist": {+ "variables": [+ "enableWatchFeedEntrypoint",+ "includeEpisodeContentRatingsV2",+ "limit",+ "offset",+ "uri"+ ],+ "example": {+ "uri": "spotify:playlist:37i9dQZF1EIZKQBmjpvc47",+ "offset": 0,+ "limit": 25,+ "enableWatchFeedEntrypoint": true,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "fetchPlaylistContents": {+ "variables": [+ "includeEpisodeContentRatingsV2",+ "limit",+ "offset",+ "uri"+ ],+ "example": {+ "uri": "spotify:playlist:37i9dQZF1EIZKQBmjpvc47",+ "offset": 25,+ "limit": 50,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "fetchPlaylistMetadata": {+ "variables": [+ "enableWatchFeedEntrypoint",+ "limit",+ "offset",+ "uri"+ ],+ "example": {+ "uri": "spotify:playlist:37i9dQZF1EYkqdzj48dyYq",+ "offset": 0,+ "limit": 100,+ "enableWatchFeedEntrypoint": true+ }+ },+ "getAlbum": {+ "variables": [+ "limit",+ "locale",+ "offset",+ "uri"+ ],+ "example": {+ "uri": "spotify:album:6zme2NwcaBxbn3mWOcMY8y",+ "locale": "intl-fr",+ "offset": 0,+ "limit": 50+ }+ },+ "getCommentsForEntity": {+ "variables": [+ "token",+ "uri"+ ],+ "example": {+ "uri": "spotify:episode:3bJKyYG8VZdVW8nH5petM3",+ "token": null+ }+ },+ "getDynamicColorsByUris": {+ "variables": [+ "imageUris"+ ],+ "example": {+ "imageUris": [+ "https://i.scdn.co/image/ab67616d0000b273db29800222c202ae748cba1b"+ ]+ }+ },+ "getEpisodeOrChapter": {+ "variables": [+ "includeEpisodeContentRatingsV2",+ "uri"+ ],+ "example": {+ "uri": "spotify:episode:3bJKyYG8VZdVW8nH5petM3",+ "includeEpisodeContentRatingsV2": true+ }+ },+ "getTrack": {+ "variables": [+ "includeVideoAssociationItems",+ "uri"+ ],+ "example": {+ "uri": "spotify:track:30RmEyZdIYdYpSTkMtgtKt",+ "includeVideoAssociationItems": true+ }+ },+ "home": {+ "variables": [+ "facet",+ "homeEndUserIntegration",+ "includeEpisodeContentRatingsV2",+ "includeHomeChapterVideoCards",+ "sectionItemsLimit",+ "sp_t",+ "timeZone"+ ],+ "example": {+ "includeHomeChapterVideoCards": false,+ "homeEndUserIntegration": "INTEGRATION_WEB_PLAYER",+ "timeZone": "Europe/Zurich",+ "sp_t": "{sp_t}",+ "facet": "",+ "sectionItemsLimit": 10,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "internalLinkRecommenderEpisode": {+ "variables": [+ "includeEpisodeContentRatingsV2",+ "uri"+ ],+ "example": {+ "uri": "spotify:episode:3bJKyYG8VZdVW8nH5petM3",+ "includeEpisodeContentRatingsV2": true+ }+ },+ "internalLinkRecommenderShow": {+ "variables": [+ "uri"+ ],+ "example": {+ "uri": "spotify:show:3vS7gWYpz4ry0yRnQ345hU"+ }+ },+ "internalLinkRecommenderTrack": {+ "variables": [+ "limit",+ "uri"+ ],+ "example": {+ "uri": "spotify:track:30RmEyZdIYdYpSTkMtgtKt",+ "limit": 5+ }+ },+ "isCurated": {+ "variables": [+ "uris"+ ],+ "example": {+ "uris": [+ "spotify:episode:7kDlpm1xDML49QuzV4Hbs2",+ "spotify:episode:3KNbJvoYkXN9hgfeUXYigS",+ "spotify:episode:5Ayc3yoBQ9OaGD3sSLVvMi",+ "spotify:episode:53iR7S2IWbKAOXEVVEnagR",+ "spotify:episode:3zYi5sHNNcdkDyPaIiRcI4",+ "spotify:episode:2HLbu2WV35q1RbvBnNiMhb",+ "spotify:episode:1R1SJeNffUTr9iILWo3dxy",+ "spotify:episode:1amTi28juSptAkSJsASBBH",+ "spotify:episode:2Fcp88MiSafUs7Yl1Y4vdE",+ "spotify:episode:4YT81bGQeeqYz4hJeUygTb",+ "spotify:episode:3fpHVxurRyluUe6MfKPtuJ",+ "spotify:episode:6PwAQQh30IXdo5WaclPunu",+ "spotify:episode:0CWZGCQb4YVzmiNVE8Pifk",+ "spotify:episode:6YxqbXZXUbwEyYnFtJ15kS",+ "spotify:episode:5X3Vy1L4OThzBHOZRdNO09",+ "spotify:episode:6JYEre5sEc74iYYe0ZTVh6",+ "spotify:episode:41Li1M34WY9cVxtJx6jLax",+ "spotify:episode:0tnkdp6hDPCPQqqY0wdkdy",+ "spotify:episode:2yOfsFdSqAWanRXJmaIBSs",+ "spotify:episode:6ZpTA2OLRsgBV3G1uN4pYC",+ "spotify:episode:5oyGgLLKJIn6VnDS1VLE7D",+ "spotify:episode:0vKWNw6P3xwHZ38WX6Yfax",+ "spotify:episode:1kuZLSHJX1z6Skt1TMvylC",+ "spotify:episode:6SC8ZvVLN3CeTwuVVuknSr",+ "spotify:episode:754xT5eYoIcrkAK7xCMTZt",+ "spotify:episode:7nk9DgyoB6zcPCdYohJ1F3",+ "spotify:episode:0LHIqeO20ni8JNtxH43MgM",+ "spotify:episode:1fPQFzXXsWqH22ewAmTZJF",+ "spotify:episode:2SAplEelVg0yH1ktmjjc1V",+ "spotify:episode:1CqBVw0GntNd4FLMCLEjWl"+ ]+ }+ },+ "libraryV3": {+ "variables": [+ "expandedFolders",+ "features",+ "flatten",+ "folderUri",+ "includeFoldersWhenFlattening",+ "limit",+ "offset",+ "order",+ "textFilter"+ ],+ "example": {+ "order": null,+ "textFilter": "",+ "features": [+ "LIKED_SONGS",+ "YOUR_EPISODES_V2",+ "PRERELEASES",+ "PRERELEASES_V2",+ "CLIPS",+ "EVENTS"+ ],+ "limit": 50,+ "offset": 0,+ "flatten": false,+ "expandedFolders": [],+ "folderUri": null,+ "includeFoldersWhenFlattening": true+ }+ },+ "lookupChildEntities": {+ "variables": [+ "uris"+ ],+ "example": {+ "uris": [+ "spotify:track:70cHKK8bHAfJrOGVnfRG9J",+ "spotify:playlist:37i9dQZF1F5p3rmiWPIYgZ"+ ]+ }+ },+ "npvV2TrackSupplementalSections": {+ "variables": [+ "enableRelatedVideos",+ "trackUri"+ ],+ "example": {+ "trackUri": "spotify:track:55vPnuXfuzXNW75JpuSczF",+ "enableRelatedVideos": true+ }+ },+ "playlistPermissions": {+ "variables": [+ "uri"+ ],+ "example": {+ "uri": "spotify:playlist:37i9dQZF1EIZKQBmjpvc47"+ }+ },+ "profileAttributes": {+ "variables": [],+ "example": {}+ },+ "queryAlbumMerch": {+ "variables": [+ "uri"+ ],+ "example": {+ "uri": "spotify:album:6zme2NwcaBxbn3mWOcMY8y"+ }+ },+ "queryAlbumTracks": {+ "variables": [+ "limit",+ "offset",+ "uri"+ ],+ "example": {+ "uri": "spotify:album:2g6XbbyPIPRMa2P1ildhza",+ "offset": 0,+ "limit": 300+ }+ },+ "queryArtistDiscographyAll": {+ "variables": [+ "limit",+ "offset",+ "order",+ "uri"+ ],+ "example": {+ "uri": "spotify:artist:1McMsnEElThX1knmY4oliG",+ "offset": 0,+ "limit": 20,+ "order": "DATE_DESC"+ }+ },+ "queryArtistDiscographyOverview": {+ "variables": [+ "uri"+ ],+ "example": {+ "uri": "spotify:artist:1McMsnEElThX1knmY4oliG"+ }+ },+ "queryArtistOverview": {+ "variables": [+ "locale",+ "preReleaseV2",+ "uri"+ ],+ "example": {+ "uri": "spotify:artist:1McMsnEElThX1knmY4oliG",+ "locale": "intl-fr",+ "preReleaseV2": true+ }+ },+ "queryArtistRelated": {+ "variables": [+ "uri"+ ],+ "example": {+ "uri": "spotify:artist:1McMsnEElThX1knmY4oliG"+ }+ },+ "queryNpvArtist": {+ "variables": [+ "artistUri",+ "contributorsLimit",+ "contributorsOffset",+ "enableRelatedAudioTracks",+ "enableRelatedVideos",+ "trackUri"+ ],+ "example": {+ "artistUri": "spotify:artist:0RRp1XbMoTmW8zSWC1synA",+ "trackUri": "spotify:track:0T1CzbjyOEU60cL5G244di",+ "contributorsLimit": 10,+ "contributorsOffset": 0,+ "enableRelatedVideos": true,+ "enableRelatedAudioTracks": true+ }+ },+ "queryPodcastEpisodes": {+ "variables": [+ "includeEpisodeContentRatingsV2",+ "limit",+ "offset",+ "uri"+ ],+ "example": {+ "uri": "spotify:show:3vS7gWYpz4ry0yRnQ345hU",+ "offset": 0,+ "limit": 50,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "queryShowMetadataV2": {+ "variables": [+ "includeContentCapabilityTrait",+ "includeEpisodeContentRatingsV2",+ "uri"+ ],+ "example": {+ "uri": "spotify:show:3vS7gWYpz4ry0yRnQ345hU",+ "includeContentCapabilityTrait": true,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "queryTrackArtists": {+ "variables": [+ "trackUri"+ ],+ "example": {+ "trackUri": "spotify:track:7heoPFrtuH6JU6AcfzjWHp"+ }+ },+ "recentSearches": {+ "variables": [+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "limit"+ ],+ "example": {+ "limit": 50,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "removeFromLibrary": {+ "variables": [+ "libraryItemUris"+ ],+ "example": {+ "libraryItemUris": [+ "spotify:artist:1McMsnEElThX1knmY4oliG"+ ]+ }+ },+ "searchAlbums": {+ "variables": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset",+ "searchTerm"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "orelsan",+ "offset": 0,+ "limit": 30,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "searchArtists": {+ "variables": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset",+ "searchTerm"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "orelsan",+ "offset": 0,+ "limit": 30,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "searchFullEpisodes": {+ "variables": [+ "includeEpisodeContentRatingsV2",+ "limit",+ "offset",+ "searchTerm"+ ],+ "example": {+ "searchTerm": "france inter",+ "offset": 0,+ "limit": 30,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "searchGenres": {+ "variables": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset",+ "searchTerm"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "rap",+ "offset": 0,+ "limit": 30,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "searchPlaylists": {+ "variables": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset",+ "searchTerm"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "orelsan",+ "offset": 0,+ "limit": 30,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "searchPodcasts": {+ "variables": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset",+ "searchTerm"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "france inter",+ "offset": 0,+ "limit": 30,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "searchSuggestions": {+ "variables": [+ "includeAlbumPreReleases",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "limit",+ "numberOfTopResults",+ "offset",+ "query"+ ],+ "example": {+ "query": "orelsan",+ "limit": 30,+ "numberOfTopResults": 30,+ "offset": 0,+ "includeAuthors": true,+ "includeAlbumPreReleases": false,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "searchTopResultsList": {+ "variables": [+ "includeAlbumPreReleases",+ "includeArtistHasConcertsField",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "isPrefix",+ "limit",+ "numberOfTopResults",+ "offset",+ "query",+ "sectionFilters"+ ],+ "example": {+ "query": "france inter",+ "limit": 50,+ "offset": 0,+ "numberOfTopResults": 50,+ "includeArtistHasConcertsField": false,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includePreReleases": true,+ "includeAlbumPreReleases": false,+ "includeEpisodeContentRatingsV2": true,+ "isPrefix": null,+ "sectionFilters": [+ "GENERIC",+ "VIDEO_CONTENT"+ ]+ }+ },+ "searchTracks": {+ "variables": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset",+ "searchTerm"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "orelsan",+ "offset": 0,+ "limit": 20,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "searchUsers": {+ "variables": [+ "includeAlbumPreReleases",+ "includeAudiobooks",+ "includeAuthors",+ "includeEpisodeContentRatingsV2",+ "includePreReleases",+ "limit",+ "numberOfTopResults",+ "offset",+ "searchTerm"+ ],+ "example": {+ "includePreReleases": false,+ "includeAlbumPreReleases": false,+ "numberOfTopResults": 20,+ "searchTerm": "kotazo",+ "offset": 0,+ "limit": 30,+ "includeAudiobooks": true,+ "includeAuthors": true,+ "includeEpisodeContentRatingsV2": true+ }+ },+ "similarAlbumsBasedOnThisTrack": {+ "variables": [+ "albumsOnly",+ "limit",+ "uri"+ ],+ "example": {+ "uri": "spotify:track:30RmEyZdIYdYpSTkMtgtKt",+ "limit": 50,+ "albumsOnly": true+ }+ },+ "userTopContent": {+ "variables": [+ "includeTopArtists",+ "includeTopTracks",+ "topArtistsInput",+ "topTracksInput"+ ],+ "example": {+ "includeTopArtists": true,+ "topArtistsInput": {+ "offset": 0,+ "limit": 10,+ "sortBy": "AFFINITY",+ "timeRange": "SHORT_TERM"+ },+ "includeTopTracks": true,+ "topTracksInput": {+ "offset": 0,+ "limit": 4,+ "sortBy": "AFFINITY",+ "timeRange": "SHORT_TERM"+ }+ }+ }+}\ No newline at end of filediff --git a/docs/brand/myspoti-logo-1024.png b/docs/brand/myspoti-logo-1024.pngnew file mode 100644index 00000000..29d90c9cBinary files /dev/null and b/docs/brand/myspoti-logo-1024.png differdiff --git a/docs/brand/myspoti-logo-512.png b/docs/brand/myspoti-logo-512.pngnew file mode 100644index 00000000..f1dd157bBinary files /dev/null and b/docs/brand/myspoti-logo-512.png differdiff --git a/docs/brand/myspoti-logo.svg b/docs/brand/myspoti-logo.svgnew file mode 100644index 00000000..a0742746--- /dev/null+++ b/docs/brand/myspoti-logo.svg@@ -0,0 +1,9 @@+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 108 108" width="1024" height="1024">+ <rect width="108" height="108" rx="24" fill="#121212"/>+ <g stroke="#1ED760" stroke-width="7.5" stroke-linecap="round">+ <line x1="38" y1="47" x2="38" y2="61"/>+ <line x1="48.7" y1="37" x2="48.7" y2="71"/>+ <line x1="59.3" y1="42" x2="59.3" y2="66"/>+ <line x1="70" y1="49" x2="70" y2="59"/>+ </g>+</svg>diff --git a/docs/screenshots/album.jpg b/docs/screenshots/album.jpgnew file mode 100644index 00000000..4727bb35Binary files /dev/null and b/docs/screenshots/album.jpg differdiff --git a/docs/screenshots/artist.jpg b/docs/screenshots/artist.jpgnew file mode 100644index 00000000..bbcb0ef3Binary files /dev/null and b/docs/screenshots/artist.jpg differdiff --git a/docs/screenshots/banner.jpg b/docs/screenshots/banner.jpgnew file mode 100644index 00000000..44d0ab82Binary files /dev/null and b/docs/screenshots/banner.jpg differdiff --git a/docs/screenshots/home.jpg b/docs/screenshots/home.jpgnew file mode 100644index 00000000..3421ce0cBinary files /dev/null and b/docs/screenshots/home.jpg differdiff --git a/docs/screenshots/player.jpg b/docs/screenshots/player.jpgnew file mode 100644index 00000000..825eaa55Binary files /dev/null and b/docs/screenshots/player.jpg differdiff --git a/tools/apkstrings.py b/tools/apkstrings.pynew file mode 100755index 00000000..57f993fa--- /dev/null+++ b/tools/apkstrings.py@@ -0,0 +1,102 @@+#!/usr/bin/env python3+"""Official Spotify UI strings, per locale, from an `aapt2 dump resources` of the APK.++usage:+ apkstrings.py DUMP find "English text" -> resource names whose default value matches+ apkstrings.py DUMP export KEYS.txt RES_DIR -> RES_DIR/values[-xx]/spotify_strings.xml+ (+ spotify_plurals.xml for "plurals/" keys)+KEYS.txt: one official resource name per line (# comments allowed); plurals as "plurals/name".+"""+import re, sys, os+from xml.sax.saxutils import escape++def parse(path):+ strings, name = {}, None+ res_re = re.compile(r'^\s+resource 0x[0-9a-f]+ string/(\S+)')+ val_re = re.compile(r'^\s+\(([^)]*)\) "(.*)"\s*$')+ other_re = re.compile(r'^\s+resource 0x[0-9a-f]+ ')+ with open(path, encoding='utf-8', errors='replace') as f:+ for line in f:+ m = res_re.match(line)+ if m: name = m.group(1); strings.setdefault(name, {}); continue+ if other_re.match(line): name = None; continue+ if name:+ v = val_re.match(line)+ if v: strings[name].setdefault(v.group(1), v.group(2))+ return strings++def parse_plurals(path):+ """plurals/name -> {config: {quantity: text}}"""+ out, name, cfg = {}, None, None+ res_re = re.compile(r'^\s+resource 0x[0-9a-f]+ plurals/(\S+)')+ cfg_re = re.compile(r'^\s+\(([^)]*)\) \(plurals\)')+ item_re = re.compile(r'^\s+(zero|one|two|few|many|other)="(.*)"\s*$')+ other_re = re.compile(r'^\s+resource 0x[0-9a-f]+ ')+ with open(path, encoding='utf-8', errors='replace') as f:+ for line in f:+ m = res_re.match(line)+ if m: name = m.group(1); out.setdefault(name, {}); cfg = None; continue+ if other_re.match(line): name = None; continue+ if not name: continue+ c = cfg_re.match(line)+ if c: cfg = c.group(1); out[name].setdefault(cfg, {}); continue+ i = item_re.match(line)+ if i and cfg is not None: out[name][cfg].setdefault(i.group(1), i.group(2))+ return out++def android_qualifier(cfg):+ # aapt2 configs: "" default, "fr", "pt-rBR", "b+sr+Latn", "zh-rTW"...+ if cfg == '': return 'values'+ if not re.fullmatch(r'[a-z]{2,3}(-r[A-Z]{2})?|b\+[A-Za-z0-9+]+', cfg): return None+ return 'values-' + cfg++def xml_value(v):+ v = v.replace('\\"', '"')+ v = escape(v).replace("'", "\\'").replace('"', '\\"')+ return v++if __name__ == '__main__':+ dump, cmd = sys.argv[1], sys.argv[2]+ s = parse(dump)+ if cmd == 'find':+ q = sys.argv[3].lower()+ for k, loc in s.items():+ d = loc.get('', '')+ if q == d.lower() or (len(sys.argv) > 4 and q in d.lower()):+ print(k, '=', d, '|fr:', loc.get('fr', ''))+ elif cmd == 'export':+ allkeys = [l.split('#')[0].strip() for l in open(sys.argv[3]) if l.split('#')[0].strip()]+ keys = [k for k in allkeys if not k.startswith('plurals/')]+ pkeys = [k[len('plurals/'):] for k in allkeys if k.startswith('plurals/')]+ if pkeys:+ pl = parse_plurals(dump); pout = {}+ for k in pkeys:+ if k not in pl: print('missing plurals', k, file=sys.stderr); continue+ for cfg, items in pl[k].items():+ q = android_qualifier(cfg)+ if q: pout.setdefault(q, {})[k] = items+ for q, kv in pout.items():+ d = os.path.join(sys.argv[4], q); os.makedirs(d, exist_ok=True)+ with open(os.path.join(d, 'spotify_plurals.xml'), 'w', encoding='utf-8') as f:+ f.write('<?xml version="1.0" encoding="utf-8"?>\n<!-- Generated by tools/apkstrings.py from the official app (labels only). -->\n<resources>\n')+ for k in pkeys:+ if k not in kv: continue+ f.write(f' <plurals name="{k}">\n')+ for qty in ('zero', 'one', 'two', 'few', 'many', 'other'):+ if qty in kv[k]: f.write(f' <item quantity="{qty}">{xml_value(kv[k][qty])}</item>\n')+ f.write(' </plurals>\n')+ f.write('</resources>\n')+ out = {}+ for k in keys:+ if k not in s: print('missing', k, file=sys.stderr); continue+ for cfg, v in s[k].items():+ q = android_qualifier(cfg)+ if q: out.setdefault(q, {})[k] = v+ for q, kv in out.items():+ d = os.path.join(sys.argv[4], q); os.makedirs(d, exist_ok=True)+ with open(os.path.join(d, 'spotify_strings.xml'), 'w', encoding='utf-8') as f:+ f.write('<?xml version="1.0" encoding="utf-8"?>\n<!-- Generated by tools/apkstrings.py from the official app (labels only). -->\n<resources>\n')+ for k in keys:+ if k in kv: f.write(f' <string name="{k}" formatted="false">{xml_value(kv[k])}</string>\n')+ f.write('</resources>\n')+ print(len(out), 'locales')diff --git a/tools/arsc.py b/tools/arsc.pynew file mode 100644index 00000000..51ec26ae--- /dev/null+++ b/tools/arsc.py@@ -0,0 +1,180 @@+"""Minimal resources.arsc + binary XML dumper (no deps).+usage: arsc.py table <resources.arsc> [type-filter] -> TSV: type name config value+ arsc.py xml <resources.arsc> <file.xml> -> pretty XML with resolved @refs+"""+import struct, sys++def u16(b, o): return struct.unpack_from('<H', b, o)[0]+def u32(b, o): return struct.unpack_from('<I', b, o)[0]++def parse_strpool(b, o):+ hsz, sz = u16(b, o + 2), u32(b, o + 4)+ cnt, scnt, flags, sstart = u32(b, o + 8), u32(b, o + 12), u32(b, o + 16), u32(b, o + 20)+ utf8 = flags & 0x100+ offs = [u32(b, o + hsz + 4 * i) for i in range(cnt)]+ base = o + sstart+ out = []+ for so in offs:+ p = base + so+ if utf8:+ n = b[p]; p += 1+ if n & 0x80: p += 1+ n = b[p]; p += 1+ if n & 0x80: n = ((n & 0x7f) << 8) | b[p]; p += 1+ out.append(b[p:p + n].decode('utf8', 'replace'))+ else:+ n = u16(b, p); p += 2+ if n & 0x8000: n = ((n & 0x7fff) << 16) | u16(b, p); p += 2+ out.append(b[p:p + 2 * n].decode('utf16', 'replace'))+ return out++DIM_UNITS = ['px', 'dp', 'sp', 'pt', 'in', 'mm']+RADIX = [1 / (1 << 8), 1 / (1 << 15), 1 / (1 << 23), 1 / (1 << 31)]++def fmt_val(t, d, gstr, names):+ if t == 0x03: return gstr[d] if d < len(gstr) else '?str'+ if t == 0x01: return '@' + names.get(d, hex(d))+ if t == 0x02: return '?' + names.get(d, hex(d))+ if t == 0x05:+ m = d & 0xffffff00+ if m & 0x80000000: m -= 1 << 32+ v = m * RADIX[(d >> 4) & 3]+ return f'{round(v, 3)}{DIM_UNITS[d & 0xf] if (d & 0xf) < 6 else "?"}'+ if t == 0x06:+ m = d & 0xffffff00+ if m & 0x80000000: m -= 1 << 32+ v = m * RADIX[(d >> 4) & 3]+ return f'{round(v * 100, 3)}%' + ('p' if d & 0xf else '')+ if t == 0x04: return str(struct.unpack('<f', struct.pack('<I', d))[0])+ if t == 0x10: return str(d if d < 0x80000000 else d - (1 << 32))+ if t == 0x11: return hex(d)+ if t == 0x12: return 'true' if d else 'false'+ if 0x1c <= t <= 0x1f: return '#%08x' % d+ if t == 0x00: return '@null'+ return f'(t{t:x}){d:#x}'++def cfg_str(b, o):+ sz = u32(b, o)+ c = b[o:o + sz]+ parts = []+ lang = c[8:10]+ if lang[0]: parts.append(lang.decode('latin1', 'replace'))+ if sz >= 20:+ density = u16(c, 14)+ if density: parts.append(f'{density}dpi')+ if sz >= 28:+ sw = u16(c, 24) if sz > 25 else 0+ if sz >= 32:+ smallest = u16(c, 28)+ if smallest: parts.append(f'sw{smallest}dp')+ sdw, sdh = u16(c, 30), u16(c, 32) if sz > 33 else 0+ if sdw: parts.append(f'w{sdw}dp')+ if sdh: parts.append(f'h{sdh}dp')+ if sz >= 28:+ ui = c[27] if sz > 27 else 0+ if ui & 0x30 == 0x20: parts.append('night')+ if sz >= 12:+ orient = c[12]+ if orient == 2: parts.append('land')+ sdk = u16(c, 22) if sz > 23 else 0+ if sdk: parts.append(f'v{sdk}')+ return '-'.join(parts) or 'default'++def parse_table(path):+ b = open(path, 'rb').read()+ hsz = u16(b, 2)+ o = hsz+ gstr = None+ entries = [] # (resid, type, name, cfg, value)+ names = {}+ while o < len(b):+ ct, ch, cs = u16(b, o), u16(b, o + 2), u32(b, o + 4)+ if ct == 0x0001 and gstr is None:+ gstr = parse_strpool(b, o)+ elif ct == 0x0200:+ pid = u32(b, o + 8)+ typestr_off, keystr_off = u32(b, o + 268), u32(b, o + 276)+ tstr = parse_strpool(b, o + typestr_off)+ kstr = parse_strpool(b, o + keystr_off)+ p = o + ch+ while p < o + cs:+ t2, h2, s2 = u16(b, p), u16(b, p + 2), u32(b, p + 4)+ if t2 == 0x0201:+ tid, flags = b[p + 8], b[p + 9]+ ecount, estart = u32(b, p + 12), u32(b, p + 16)+ cfg = cfg_str(b, p + 20)+ sparse = flags & 1+ off16 = flags & 2+ for i in range(ecount):+ if sparse:+ idx, eo = u16(b, p + h2 + 4 * i), u16(b, p + h2 + 4 * i + 2) * 4+ elif off16:+ eo = u16(b, p + h2 + 2 * i)+ if eo == 0xffff: continue+ eo *= 4; idx = i+ else:+ eo = u32(b, p + h2 + 4 * i)+ if eo == 0xffffffff: continue+ idx = i+ e = p + estart + eo+ esz, eflags, key = u16(b, e), u16(b, e + 2), u32(b, e + 4)+ resid = (pid << 24) | (tid << 16) | idx+ tname = tstr[tid - 1]+ kname = kstr[key] if key < len(kstr) else '?'+ names[resid] = f'{tname}/{kname}'+ if eflags & 1:+ parent, cnt = u32(b, e + 8), u32(b, e + 12)+ items = []+ for j in range(cnt):+ q = e + 16 + 12 * j+ items.append((u32(b, q), b[q + 7], u32(b, q + 8)))+ entries.append((resid, tname, kname, cfg, ('bag', parent, items)))+ else:+ entries.append((resid, tname, kname, cfg, (b[e + esz + 3], u32(b, e + esz + 4))))+ p += s2+ o += cs+ return gstr, entries, names++def show(v, gstr, names):+ if v[0] == 'bag':+ _, parent, items = v+ s = ('parent=@' + names.get(parent, hex(parent)) + ' ') if parent else ''+ return s + '{' + '; '.join(f'{names.get(k, hex(k))}={fmt_val(t, d, gstr, names)}' for k, t, d in items) + '}'+ return fmt_val(v[0], v[1], gstr, names)++def parse_axml(path, gstr_t, names):+ b = open(path, 'rb').read()+ o = u16(b, 2)+ strs, resmap, depth, out = [], [], 0, []+ while o < len(b):+ ct, ch, cs = u16(b, o), u16(b, o + 2), u32(b, o + 4)+ if ct == 0x0001: strs = parse_strpool(b, o)+ elif ct == 0x0180: resmap = [u32(b, o + 8 + 4 * i) for i in range((cs - 8) // 4)]+ elif ct == 0x0102:+ name = strs[u32(b, o + 20)]+ astart, asz, acnt = u16(b, o + 24), u16(b, o + 26), u16(b, o + 28)+ attrs = []+ for i in range(acnt):+ a = o + 16 + astart + i * asz+ ni, raw, t, d = u32(b, a + 4), u32(b, a + 8), b[a + 15], u32(b, a + 16)+ an = strs[ni] if strs[ni] else names.get(resmap[ni], '?') if ni < len(resmap) else '?'+ if not an and ni < len(resmap): an = names.get(resmap[ni], hex(resmap[ni]))+ val = strs[raw] if raw != 0xffffffff else fmt_val(t, d, strs if t == 3 else gstr_t, names)+ attrs.append(f'{an}="{val}"')+ out.append(' ' * depth + f'<{name} ' + ' '.join(attrs) + '>')+ depth += 1+ elif ct == 0x0103:+ depth -= 1+ o += cs+ return '\n'.join(out)++if __name__ == '__main__':+ mode, arsc = sys.argv[1], sys.argv[2]+ gstr, entries, names = parse_table(arsc)+ if mode == 'table':+ flt = sys.argv[3] if len(sys.argv) > 3 else None+ for resid, t, k, cfg, v in entries:+ if flt and t != flt: continue+ print(f'{t}\t{k}\t{cfg}\t{show(v, gstr, names)}')+ else:+ print(parse_axml(sys.argv[3], gstr, names))diff --git a/tools/capture.sh b/tools/capture.shnew file mode 100755index 00000000..5fe61ed6--- /dev/null+++ b/tools/capture.sh@@ -0,0 +1,27 @@+#!/usr/bin/env bash+# Records what happens in app.myspoti while the user drives the phone.+# usage: tools/capture.sh <name> (stop with: touch tools/captures/<name>.stop)+set -u+ADB=${ADB:-$HOME/android-sdk/platform-tools/adb}+SERIAL=${SERIAL:-adb-R3CX80NDH7F-gtly5q._adb-tls-connect._tcp}+NAME=${1:-session}+OUT="$(dirname "$0")/captures/$NAME"+mkdir -p "$OUT"; rm -f "$OUT.stop"+a() { "$ADB" -s "$SERIAL" "$@"; }+UIDN=$(a shell pm list packages -U app.myspoti | grep -oE 'uid:[0-9]+' | cut -d: -f2)+a logcat -c+a shell dumpsys gfxinfo app.myspoti reset >/dev/null+a logcat -v time --uid="$UIDN" > "$OUT/logcat.txt" &+LP=$!+# Sample the system media session + audio state every second.+while [ ! -e "$OUT.stop" ]; do+ ts=$(date +%H:%M:%S.%N | cut -c1-12)+ st=$(a shell dumpsys media_session | sed -n '/package=app.myspoti$/,/queueTitle/p' | grep -oE 'state=[A-Z]+|description=[^,]*' | tr '\n' ' ')+ au=$(a shell dumpsys audio | grep -E "u/pid:$UIDN/.*state:" | grep -oE 'state:[a-z]+' | head -1)+ echo "$ts $st $au" >> "$OUT/session.txt"+ sleep 1+done+kill $LP 2>/dev/null+a shell dumpsys gfxinfo app.myspoti > "$OUT/gfxinfo.txt"+a shell dumpsys activity activities | grep -E 'topResumedActivity' > "$OUT/activity.txt"+echo "capture saved in $OUT"diff --git a/tools/cdp.py b/tools/cdp.pynew file mode 100644index 00000000..644b6faa--- /dev/null+++ b/tools/cdp.py@@ -0,0 +1,161 @@+#!/usr/bin/env python3+"""Evaluate JavaScript in the engine's WebView over the Chrome DevTools protocol (debug builds).++usage: tools/cdp.py [--serial SERIAL] 'JS expression'+Forwards localabstract:webview_devtools_remote_<engine pid> to tcp:9223, then runs+Runtime.evaluate (awaitPromise, returnByValue) on the open.spotify.com page.+No third-party dependencies: minimal WebSocket client below.+"""+import argparse, base64, json, os, socket, struct, subprocess, sys, urllib.request++ADB = os.environ.get("ADB", os.path.expanduser("~/android-sdk/platform-tools/adb"))+PORT = 9223+++def adb(serial, *args):+ cmd = [ADB] + (["-s", serial] if serial else []) + list(args)+ return subprocess.run(cmd, capture_output=True, text=True, check=True).stdout.strip()+++def ws_connect(url):+ host_port, path = url[len("ws://"):].split("/", 1)+ host, port = host_port.split(":")+ s = socket.create_connection((host, int(port)), timeout=150)+ key = base64.b64encode(os.urandom(16)).decode()+ s.sendall((f"GET /{path} HTTP/1.1\r\nHost: {host_port}\r\nUpgrade: websocket\r\nConnection: Upgrade\r\n"+ f"Sec-WebSocket-Key: {key}\r\nSec-WebSocket-Version: 13\r\n\r\n").encode())+ resp = b""+ while b"\r\n\r\n" not in resp:+ resp += s.recv(1)+ if b" 101 " not in resp.split(b"\r\n")[0]:+ raise SystemExit("websocket handshake failed: " + resp.decode(errors="replace"))+ return s+++def ws_send(s, text):+ data = text.encode()+ header = bytes([0x81])+ mask = os.urandom(4)+ n = len(data)+ if n < 126:+ header += bytes([0x80 | n])+ elif n < 65536:+ header += bytes([0x80 | 126]) + struct.pack(">H", n)+ else:+ header += bytes([0x80 | 127]) + struct.pack(">Q", n)+ s.sendall(header + mask + bytes(b ^ mask[i % 4] for i, b in enumerate(data)))+++def ws_recv(s):+ def read(n):+ buf = b""+ while len(buf) < n:+ chunk = s.recv(n - len(buf))+ if not chunk:+ raise EOFError+ buf += chunk+ return buf+ payload = b""+ while True:+ b1, b2 = read(2)+ n = b2 & 0x7F+ if n == 126:+ n = struct.unpack(">H", read(2))[0]+ elif n == 127:+ n = struct.unpack(">Q", read(8))[0]+ payload += read(n)+ if b1 & 0x80:+ return payload.decode(errors="replace")+++def main():+ ap = argparse.ArgumentParser()+ ap.add_argument("--serial")+ ap.add_argument("--trace", type=float, default=0, help="seconds of Network tracing after evaluating expr")+ ap.add_argument("--bodies", default="", help="regex: print request/response bodies for matching URLs (trace mode)")+ ap.add_argument("--click", default="", help="CSS selector: dispatch a trusted mouse click on its center")+ ap.add_argument("expr", nargs="?", default="0")+ a = ap.parse_args()+ ps = adb(a.serial, "shell", "ps", "-A", "-o", "PID,NAME")+ unix = adb(a.serial, "shell", "cat", "/proc/net/unix")+ pid = next((l.split()[0] for l in ps.splitlines()[1:] if l.split()[-1] in ("app.myspoti", "app.myspoti:engine")+ and f"webview_devtools_remote_{l.split()[0]}" in unix), "")+ if not pid:+ raise SystemExit("engine process not running")+ adb(a.serial, "forward", f"tcp:{PORT}", f"localabstract:webview_devtools_remote_{pid.split()[0]}")+ pages = json.load(urllib.request.urlopen(f"http://127.0.0.1:{PORT}/json"))+ # The engine page is the one attached to the 1280x800 virtual display, not a login WebView.+ cands = [p for p in pages if p.get("type") == "page" and "open.spotify.com" in p.get("url", "")]+ page = next((p for p in cands if '"height":800' in p.get("description", "")), cands[0] if cands else None)+ if not page:+ raise SystemExit("no open.spotify.com page: " + json.dumps([p.get("url") for p in pages]))+ s = ws_connect(page["webSocketDebuggerUrl"])+ if a.click:+ sel = json.dumps(a.click)+ ws_send(s, json.dumps({"id": 2, "method": "Runtime.evaluate", "params": {"returnByValue": True,+ "expression": f"(()=>{{const e=document.querySelector({sel}); if(!e) return null; e.scrollIntoView({{block:'center'}}); const r=e.getBoundingClientRect(); return [r.x+r.width/2, r.y+r.height/2]}})()"}}))+ while True:+ msg = json.loads(ws_recv(s))+ if msg.get("id") == 2:+ xy = msg.get("result", {}).get("result", {}).get("value")+ break+ if not xy:+ raise SystemExit("selector not found: " + a.click)+ for i, t in enumerate(("mousePressed", "mouseReleased")):+ ws_send(s, json.dumps({"id": 3 + i, "method": "Input.dispatchMouseEvent", "params": {+ "type": t, "x": xy[0], "y": xy[1], "button": "left", "clickCount": 1}}))+ print("clicked", a.click, "at", xy)+ if a.trace:+ ws_send(s, json.dumps({"id": 99, "method": "Network.enable", "params": {}}))+ ws_send(s, json.dumps({"id": 1, "method": "Runtime.evaluate", "params": {+ "expression": a.expr, "awaitPromise": not a.trace, "returnByValue": True}}))+ if a.trace:+ import time+ end = time.time() + a.trace+ s.settimeout(1)+ reqs = {}+ import re as _re+ body_re = _re.compile(a.bodies) if a.bodies else None+ pending_bodies = {}+ next_id = 1000+ while time.time() < end:+ try:+ msg = json.loads(ws_recv(s))+ except (socket.timeout, TimeoutError):+ continue+ m, p = msg.get("method"), msg.get("params", {})+ if m == "Network.requestWillBeSent":+ r = p["request"]+ reqs[p["requestId"]] = r["method"] + " " + r["url"].split("?")[0][:200]+ body = r.get("postData")+ if body and body_re and body_re.search(r["url"]):+ print(" >>", reqs[p["requestId"]], body[:2000])+ elif m == "Network.responseReceived":+ print("HTTP", p["response"]["status"], reqs.get(p["requestId"], p["response"]["url"][:110]))+ elif m == "Network.loadingFinished" and body_re and body_re.search(reqs.get(p["requestId"], "")):+ next_id += 1+ pending_bodies[next_id] = reqs.get(p["requestId"])+ ws_send(s, json.dumps({"id": next_id, "method": "Network.getResponseBody", "params": {"requestId": p["requestId"]}}))+ elif msg.get("id") in pending_bodies:+ print(" <<", pending_bodies.pop(msg["id"]), (msg.get("result", {}).get("body") or "")[:2000])+ elif m == "Network.loadingFailed":+ print("FAIL", p.get("errorText"), reqs.get(p["requestId"], ""))+ elif m in ("Network.webSocketFrameReceived", "Network.webSocketFrameSent"):+ d = p["response"]["payloadData"]+ print("WS" + ("<" if m.endswith("Received") else ">"), d[:260].replace("\n", " "))+ elif msg.get("id") == 1:+ print("EVAL:", json.dumps(msg.get("result", {}).get("result", {}).get("value"))[:300])+ return+ while True:+ msg = json.loads(ws_recv(s))+ if msg.get("id") == 1:+ r = msg.get("result", {})+ if "exceptionDetails" in r:+ print("EXCEPTION:", json.dumps(r["exceptionDetails"], indent=1)[:2000])+ else:+ print(json.dumps(r.get("result", {}).get("value"), indent=1, ensure_ascii=False))+ break+++if __name__ == "__main__":+ main()diff --git a/tools/discord_release.py b/tools/discord_release.pynew file mode 100755index 00000000..471e1c85--- /dev/null+++ b/tools/discord_release.py@@ -0,0 +1,93 @@+#!/usr/bin/env python3+"""Announce a GitHub release of Myspoti on Discord (webhook), as one tidy embed.++usage: tools/discord_release.py TAG [--dry-run]+env: DISCORD_WEBHOOK_URL (required unless --dry-run), GITHUB_TOKEN (optional, API rate limit),+ GITHUB_REPOSITORY (default kota-zo/myspoti)++The embed carries the release's notes (its CHANGELOG section, without GitHub's generated+part), a link to the release page and a direct link to the APK. No third-party packages.+"""+import json, os, re, sys, urllib.request++REPO = os.environ.get("GITHUB_REPOSITORY", "kota-zo/myspoti")+GREEN = 0x1ED760+LOGO = f"https://raw.githubusercontent.com/{REPO}/main/docs/brand/myspoti-logo-512.png"+MAX_DESCRIPTION = 3900 # Discord allows 4096 in an embed description+++def github(path):+ req = urllib.request.Request(f"https://api.github.com/repos/{REPO}/{path}",+ headers={"Accept": "application/vnd.github+json", "User-Agent": "myspoti-release-bot"})+ token = os.environ.get("GITHUB_TOKEN")+ if token:+ req.add_header("Authorization", f"Bearer {token}")+ with urllib.request.urlopen(req, timeout=20) as r:+ return json.load(r)+++def clean_notes(body):+ """The CHANGELOG section only: GitHub's generated "What's Changed" / "Full Changelog" go."""+ body = (body or "").replace("\r\n", "\n")+ body = re.split(r"\n(?:## What's Changed|\*\*Full Changelog\*\*|## New Contributors)", body)[0]+ return body.strip()+++def shorten(text, url):+ """Cut on a line boundary when too long, with a link to the full notes."""+ if len(text) <= MAX_DESCRIPTION:+ return text+ cut = text[:MAX_DESCRIPTION].rsplit("\n", 1)[0]+ return f"{cut}\n\n[Read the full notes]({url})"+++def payload(release):+ tag = release["tag_name"]+ version = tag.removeprefix("v")+ url = release["html_url"]+ notes = clean_notes(release.get("body")) or "See the release page for details."+ apk = next((a for a in release.get("assets", []) if a["name"].endswith(".apk")), None)+ fields = []+ if apk:+ size = apk["size"] / 1_048_576+ fields.append({"name": "Download", "value": f"[{apk['name']}]({apk['browser_download_url']}) ({size:.1f} MB)", "inline": True})+ fields.append({"name": "Release", "value": f"[{tag} on GitHub]({url})", "inline": True})+ return {+ "username": "Myspoti",+ "avatar_url": LOGO,+ "content": f"**Myspoti {version}** is out.",+ "allowed_mentions": {"parse": []},+ "embeds": [{+ "title": f"Myspoti {version}",+ "url": url,+ "description": shorten(notes, url),+ "color": GREEN,+ "thumbnail": {"url": LOGO},+ "fields": fields,+ "footer": {"text": REPO},+ "timestamp": release.get("published_at") or release.get("created_at"),+ }],+ }+++def main():+ args = [a for a in sys.argv[1:] if not a.startswith("--")]+ dry = "--dry-run" in sys.argv+ tag = args[0] if args else None+ release = github(f"releases/tags/{tag}") if tag else github("releases/latest")+ data = payload(release)+ if dry:+ print(json.dumps(data, indent=2, ensure_ascii=False))+ return+ hook = os.environ.get("DISCORD_WEBHOOK_URL", "").strip()+ if not hook:+ print("DISCORD_WEBHOOK_URL is not set: nothing posted.")+ return+ req = urllib.request.Request(hook, data=json.dumps(data).encode(), method="POST",+ headers={"Content-Type": "application/json", "User-Agent": "myspoti-release-bot"})+ with urllib.request.urlopen(req, timeout=20) as r:+ print(f"Posted {release['tag_name']} to Discord ({r.status}).")+++if __name__ == "__main__":+ main()diff --git a/tools/routecap.sh b/tools/routecap.shnew file mode 100755index 00000000..2c35aff0--- /dev/null+++ b/tools/routecap.sh@@ -0,0 +1,15 @@+#!/bin/bash+# System-wide media routing capture: logcat (routing tags) + dumpsys media_router every 2 s.+# usage: SERIAL=... tools/routecap.sh <name>; stop with: touch tools/captures/<name>.stop+ADB=${ADB:-$HOME/android-sdk/platform-tools/adb}+SERIAL=${SERIAL:?set SERIAL to the adb serial, e.g. host:port}+D=$(dirname "$0")/captures/$1; mkdir -p "$D"; rm -f "$D.stop"+"$ADB" -s "$SERIAL" logcat -c+"$ADB" -s "$SERIAL" logcat -v time | grep --line-buffered -E "MR2|Route2|RemoteDevice|MediaDevice|InfoMediaManager|LocalMediaManager|MediaOutput|spotify|Spotify|myspoti|MediaRouter|RouteListing|oneconnect.*Media" > "$D/routing.log" &+LP=$!+i=0+while [ ! -f "$D.stop" ]; do+ "$ADB" -s "$SERIAL" shell dumpsys media_router > "$D/mr_$(printf %03d $i).txt" 2>/dev/null+ i=$((i+1)); sleep 2+done+kill $LPdiff --git a/tools/spotify_strings.txt b/tools/spotify_strings.txtnew file mode 100644index 00000000..c382f365--- /dev/null+++ b/tools/spotify_strings.txt@@ -0,0 +1,178 @@+# Official labels used by the native UI (tools/apkstrings.py export ...)+# Track menu+aligned_curation_context_menu_item_add_to_liked_songs+collection_liked_songs_title+context_menu_add_to_playlist+context_menu_play_next+context_menu_add_to_queue+context_menu_go_to_queue+context_menu_browse_album+context_menu_browse_artist+context_menu_share+context_menu_sleep_timer+context_menu_sleep_timer_turn_off+context_menu_sleep_timer_end_of_track+snackbar_added_to_queue+snackbar_added_to_liked_songs+snackbar_removed_from_liked_songs+content_description_context_menu+close_button_content_description+# Saved in sheet+add_to_playlist_saved_in_section_header+add_to_playlist_new_playlist_button_text+add_to_playlist_button_cancel+create_playlist_create_button+# Lyrics+lyrics_card_title+lyrics_card_title_preview+lyrics_card_show_lyrics_button+lyrics_card_expand_button_content_description+lyrics_card_share_button_content_description+lyrics_credential_note+lyrics_fullscreen_chip_label_share+lyrics_fullscreen_chip_label_translate+lyrics_fullscreen_close_button_readout_value+lyrics_fullscreen_context_menu_main_page_translate_lyrics_action+lyrics_fullscreen_translate_button_enabled_readout_value+lyrics_fullscreen_no_lyrics_error_version_two+lyrics_fullscreen_unsynced+# Music video+av_switch_to_video+av_switch_to_audio+av_content_desc+# Navigation / headers+navigationbar_musicappitems_home_title+navigationbar_musicappitems_search_title+navigationbar_musicappitems_yourlibrary_title+search_header_field_hint+filter_chip_all_label+recents_content_filter_music+ad_category_title_podcasts+audiobooks_title+artist_popular_tracks+curation_button_follow_state_text+curation_button_following_state_text+search_main_entity_subtitle_artist+connect_phone_is_self+# Settings+settings_item_canvas_title+video_settings_canvas_subtitle+age_assurance_intro_cta_not_now+version_sunsetting_dialog_cta_update+# Screens (queue, player, artist, search, library, settings)+context_type_description_play_queue+context_type_description_collection_your_library+context_type_description_playlist+context_type_description_album+context_type_description_artist+context_type_description_show+context_type_description_search+default_notification_channel_name+label_bluetooth+mr_user_route_category_name+action_share_label+action_queue_label+mute_chat_duration_one_hour+curation_actions_edit_button_title+content_description_pause_button+content_description_play_button+play_mode_item_shuffle_title+np_content_desc_repeat+np_content_desc_sleep_timer+aligned_curation_first_save_default_row_remove_action_description+edit_playlist_items_move_chip+bottom_actions_close+add_to_queue_action_content_description+curation_button_saved_text+np_content_desc_prev+np_content_desc_next+accessibility_navigate_back+monthly_listeners_text+profile_bio_show_less+audiobook_series_see_more_button+popular_releases_section_title+creator_biography_section_title+fans_also_like_section_title+appears_on_section_title+composer_section_button_show_all+releases_title+artist_releases_albums+artist_releases_singles+latest_release_title+artist_subtitle+assisted_curation_search_search_history_title+chat_content_picker_clear_recent_searches+assisted_curation_search_filter_podcasts+assisted_curation_search_filter_episodes+assisted_curation_search_song+album+album_type_podcast+recently_played_user_profile+connect_device_menu_logout+library_search_text_hint+account_title+song_dna_search_chip_followed_artists+# Settings: crossfade+settings_item_crossfade_title+playback_settings_crossfade_slider_seconds+# Local Files+local_files_title+local_files_empty_section_title+local_files_empty_section_subtitle+local_files_empty_section_no_files_title+local_files_empty_section_dialog_permission_rationale_accept+local_files_empty_section_button_go_to_settings+# Downloads+context_menu_download+context_menu_undownload+collection_downloaded+download_badge_downloaded_content_description+download_badge_downloading_content_description+download_badge_error_content_description+download_notification_downloading+toast_undownload+playlist_entity_remove_download_dialog_title+playlist_entity_remove_download_dialog_description+playlist_entity_remove_download_dialog_positive_button+settings_item_remove_downloads_title+settings_storage_remove_downloads_dialog_title+# Counters and types (plurals/ = plural resources)+plurals/liked_songs_header_metadata_text+plurals/profile_list_item_saves_count+album_type_album+album_type_single+album_type_ep+album_type_compilation+assisted_curation_search_playlist+# Search filters+assisted_curation_search_filter_top+assisted_curation_search_filter_songs+assisted_curation_search_filter_artists+assisted_curation_search_filter_albums+assisted_curation_search_filter_playlists+assisted_curation_search_filter_clear_content_description+ad_category_title_music+made_for_you_hub_title+settings_item_app_language_title+# Folders and playlists+create_menu_item_folder_title+create_folder_name_suggested_folder_name+context_menu_rename_folder+your_library_messaging_folder_rename_hint+create_playlist_content_description+actions_picker_delete+plurals/add_to_playlist_folder_subtitle_playlists_count+plurals/add_to_playlist_subtitle_songs_count+# Library sort, About+filter_and_sort_sort_section_title+your_library_sort_order_alphabetical+your_library_sort_order_creator+your_library_sort_order_custom+creator_biography_section_title+settings_item_version_title+# Song radio+context_menu_go_to_song_radio+# Find in a list+find_in_context_edit_text_liked_songs_hint+find_in_context_edit_text_playlist_hint+assisted_curation_search_empty_view_no_result_title