Components/Music/Mini Player
Mini Player

Mini Player

NFrom Nibware

A Liquid Glass mini-player bar over album art.

Music · 27 lines · SwiftUI · iOS 17+

The actual source

MiniPlayer.swift
import SwiftUI

extension View {
    /// iOS 26 Liquid Glass with an ultraThinMaterial fallback for earlier versions.
    @ViewBuilder func liquidGlass<S: Shape>(_ shape: S) -> some View {
        if #available(iOS 26.0, *) { self.glassEffect(.regular, in: shape) }
        else { self.background(.ultraThinMaterial, in: shape) }
    }
}

/// ✨ A Liquid Glass mini-player bar over album art.
struct MusicMiniPlayer: View {

Images this component uses

The code references this image by name. Download and drag into your Xcode Asset Catalog, keeping the same name, and the component renders exactly like the preview. Or swap in your own.

What it needs

Self-contained SwiftUI - system materials, SF Symbols, no external dependencies. Everything it needs - tokens, sub-views, models - is carried in the copy-paste source above.