Repository navigation
Backgrounds behind the popup: one pane of translucent glass, or the artwork blurred into a slowly drifting backdrop, behind both the bar and the expanded card. The sample app now ships as a signed APK on every release.
Install
Add maven("https://jitpack.io") to your repositories, then:
implementation("com.github.fethica:compose-popupbar:0.2.0")The sample app from the recording is attached below as an APK (Android 7.0+).
Changes
- Added
PopupBackgroundand the host'sbackgroundparameter.Translucent(tint)is one pane of glass behind bar and card, the screen showing through a blur under a light tint with a lit edge on the bar (real blur on API 31+, a tinted scrim below).Artwork(scrim, blurRadius, animated)blurs thepopupImageinto one slowly drifting backdrop behind bar and card, the way Apple Music's player does; it needs apopupImageand API 31, and falls back to the plain card otherwise. Both take their tone from the theme throughcontainerColor, a tint or a scrim colours them, and on tinted glass and on the artworkPopupBarDefaults.colors()and the popup content'sLocalContentColorturn black or white with the tone of what they sit on; untinted glass keeps the theme's own colours. - Sample: launcher icon, portrait lock on phones, a themed root surface that follows the phone's appearance, background choices (plain, tinted and cover-tinted glass, artwork), a different cover for every track so the artwork background can be judged on light and dark covers, a browse grid of colourful category cards for the glass to show through, an Up next queue in the scrolling player, and the popup inset applied as content padding so the bar floats over the lists as the documentation asks.
backgroundcomes afterhapticsEnabledinPopupHost, so a 0.1.0 call that passes its arguments positionally and the screen content as a trailing lambda still compiles; a call that passes the content lambda inside the parentheses positionally now needsbackgroundor a namedcontent. Binary compatibility between 0.x releases is not a goal: rebuild against each release rather than swapping the artifact under compiled code.publishToMavenLocalnow publishes ascom.github.fethica:compose-popupbar, the coordinate JitPack serves, so local and published installs share one coordinate.- Every version tag builds the sample as a signed, minified release APK and publishes the GitHub release with it, this section as the notes. The sample's version follows
VERSION_NAMEingradle.propertiesinstead of its own numbers.
Configuration, the state API, insets and the sample recipes are in the documentation.
