A music player component for Flutter (i.e. Spotify, Apple Music, etc.) [AGPL/example/no longer maintaining]

Related tags

Templates dart flutter
Overview

This is an example

I currently have no plans of putting this on Pub. Originally, I did, but I lost interest. However, I think this is a good example, so I'm keeping it up.

That being said, the license is AGPL. Please know what that means, and don't be a pirate. I will find you.

music_player

Fullscreen screenshot

A music player component for Flutter (i.e. Spotify, Apple Music, etc.).

This is ready-to-go for embedding in a music-playing application. It supports seeking, as well as having callbacks for skipping, shuffling, and looping.

Installation

This package is not yet on Pub (I haven't figured out how to test it), so in the meantime:

dependencies:
  flutter: sdk
  music_player:
    git: https://github.com/thosakwe/flutter_music_player.git

Usage

class MyWidget extends StatelessWidget {
    @override
    build(BuildContext context) {
        return new MusicPlayer(
            onError: (e) {
                Scaffold.of(context).showSnackBar(
                    new SnackBar(
                        content: new Text(e),
                    ),
                );
            },
            onSkipPrevious: () {},
            onSkipNext: () {},
            onCompleted: () {},
            onLoopChanged: (loop) {
                setState(() => this.loopKind = loop);
            },
            onShuffleChanged: (loop) {
                setState(() => this.shuffle = loop);
            },
            key: musicPlayerKey,
            textColor: Colors.white,
            loop: loopKind,
            shuffle: shuffle,
            url: mp3Url,
            title: const Text(
                'BBC',
                textAlign: TextAlign.center,
                textScaleFactor: 1.5,
                style: const TextStyle(
                    fontWeight: FontWeight.bold,
                    color: Colors.white,
                ),
            ),
            subtitle: const Text(
                'JAY Z - Holy Grail',
                textAlign: TextAlign.center,
                style: const TextStyle(
                    color: Colors.white,
                ),
            ),
        );
    }
}
You might also like...

Authentication API client with Flutter (Login, Register, Google Login, Facebook Login, Apple Login)

Authentication API client with Flutter (Login, Register, Google Login, Facebook Login, Apple Login)

Flutter Auth App (Login, Register, Google Login, Facebook Login, Apple Login) To use this client, get the server up and running. Try it out now! App S

Jan 4, 2023

A lightweight flutter plugin to check if your app is up-to-date on Google Play Store or Apple App Store

App Version Checker this package is used to check if your app has a new version on playstore or apple app store. or you can even check what is the lat

Dec 14, 2022

Maps for Flutter developers. Supports Apple, Bing, and Google APIs.

Overview Cross-platform geographic maps for Flutter applications. Pull requests are welcome! The packages are licensed under the Apache License 2.0. P

Oct 13, 2022

A Flutter library for work with Apple Wallet passes.

A Flutter library for work with Apple Wallet passes.

pass-flutter A Flutter library for work with Apple Wallet passes. How use it Getting pass from URL to internal memory import 'package:pass_flutter/pas

Dec 30, 2022

Flutter widget library containing buttons for authenticating with popular social networks: Apple, Google, Facebook, Twitter and Microsoft.

Flutter widget library containing buttons for authenticating with popular social networks: Apple, Google, Facebook, Twitter and Microsoft.

Flutter Auth Buttons This library is now in maintenance mode I'm no longer actively using Flutter and don't have the time to keep this library maintai

Nov 3, 2022

Plist parser - A Plist parser for Flutter supports XML and binary Apple Property list (plist) formats

Plist Parser for Flutter 📋 A Flutter Plugin for Plist parser supporting XML and

Nov 17, 2022

Flutter library for Moyasar. Supports Apple Pay, STC Pay and Credit Card.

Flutter library for Moyasar. Supports Apple Pay, STC Pay and Credit Card.

Oct 22, 2022

[Flutter package] An easy and quick way to check if the local app is updated with the same version in their respective stores (Play Store / Apple Store ).

Retrieve version and url for local app update against store app Android and iOS Features Using as reference packages like in_app_update , version_chec

Nov 9, 2022

Flutter component concept created with Flutter using Dart programming language, inspired by Gooey Rab Bar.

Flutter component concept created with Flutter using Dart programming language, inspired by Gooey Rab Bar.

Gooey Tab Bar Flutter Flutter component concept created with Flutter using Dart programming language, inspired by Gooey Tab Bar. About This component

Dec 14, 2022
Comments
  • disable features

    disable features

    It would be nice if we could disable features.

    For example, I would like to hide the track bar. Some more customization would be ideal too, i.e reduce icon sizes.

    Thanks!

    opened by abacaj 2
  • pls  update

    pls update

    The current Dart SDK version is 2.1.0-dev.9.4.flutter-f9ebf21297.

    Because hitm depends on music_player from git which requires SDK version <2.0.0, version solving failed.

    this is my meet problem . pls update it . thx

    opened by YoungCC2 1
  • background image

    background image

    Hey!

    Cool plugin, trying to make use of it and trying to figure out how to change the background image as shown in your screenshot :)

    Any help would be appreciated

    opened by abacaj 1
Owner
Tobe Osakwe
At a loss as to what to put as a bio...
Tobe Osakwe
A tool for maintaining Dart comments.

A tool for maintaining Dart comments (daco). This package is in an early stage of development. Please file an issue if you find a bug or start a discu

Gabriel Terwesten 3 Nov 15, 2022
Flutter-Musive-app - Full-stack music player app written in flutter and dart using node.js music API

Musive Full-stack music player app is written in flutter and dart using node.js

Ansh rathod 69 Dec 28, 2022
A music player app that allows you to search for music by artist made using Flutter

Music Player A music player app that allows you to search for music by artist. Music source from iTunes affiliate API. Made using Flutter with simple

muhibush 5 Feb 5, 2022
First Open Source Flutter based material design music player with audio plugin to play online music

Flutter Music App First Open Source Flutter based dribbblel Design Music Player. logo free design http://www.freeuid.com/category/free material icons

佩奇的弟弟乔治 380 Jan 4, 2023
Flutter application that integrates with Spotify API

Storify Add captions to songs in your Spotify playlists Download Screenshots Features Sign in using Spotify Load playlists from Spotify Add captions t

Gyeongmin Lee 33 Nov 15, 2022
A flutter project on spotify Desktop App

flutter_spotify_ui Flutter Spotify Clone, On the Web Resposive! Side Menu and Mo

NerdX 6 Nov 8, 2022
Spartial - A flutter app that automatically skips the lesser parts of Spotify songs

Spartial (Spartial.app) Mobile app that lets you automatically skip parts of Spo

Ruud Brouwers 3 Mar 16, 2022
Spotify UI clone made with FLutter.

Spotify Ui clone My Goal The objective of this project is to look at how we can customise Flutter Widgets to achieve beautiful user interface designs

Light 11 Oct 23, 2022
Tic Tac Toe game with single-player and multi-player options. Implemented minimax algorithm.

flutter_tic_tac_toe A new Flutter project. Getting Started This project is a starting point for a Flutter application. A few resources to get you star

null 0 Jan 1, 2022
🚗 Apple CarPlay for Flutter Apps. Aims to make it safe to use apps made with Flutter in the car by integrating with CarPlay.

CarPlay with Flutter ?? Flutter Apps now on Apple CarPlay! flutter_carplay aims to make it safe to use iPhone apps made with Flutter in the car by int

OÄŸuzhan Atalay 156 Dec 26, 2022