Giter VIP home page Giter VIP logo

react-tunes's Introduction

A music-player web application created in React.js


About the Project ๐Ÿ”Ž

A web application for uploading and listening to music. Similar in concept to the vanilla JavaScript music player I made a while ago, but with additional features. Unlike the previous version that only permitted the uploading of pre-made audio directories from the user's file system, with no way of modifying them once uploaded, this app allows users to create and edit their own playlists.

In order for the app to function properly and to have a good user experience, it is highly recommended that your audio files contain metadata/id3 tag information. You can edit the metadata of your song files by right-clicking them in your file explorer and navigating to Properties > Details (or Edit > Get Info for Mac users), then edit each tag with the correct information. Or you can visit tagmp3.net.

If, however, you have Spotify Premium, Deezer Premium, Pandora Premium, or any other premium subscription from a music streaming service, then you can easily download your playlists from there and upload them with the metadata already included. That way, you don't have to go through the trouble of editing each song's tag information.

Languages used:

  1. JavaScript (JSX)
  2. CSS

Project development: 1/5/2022 - 3/29/2022

Requirements ๐Ÿ“‹

This application requires the following id3 tag information:

  1. Song title
  2. Song artist

Acceptable audio file types:

  • .mp3
  • .wav
  • .ogg
  • .flac

Features ๐Ÿ“ฆ๏ธ

  • Side menu
    • Toggling between light and dark theme
    • Ability to create, delete, rename, and rearrange playlists
    • Playlist search bar and dropdown
  • Playlist viewer
    • Playlist info display
    • Song uploads from filesystem (when uploading audio, try not to upload too many files at once.)
    • Song rearrangement and deletion
    • Custom cover art
  • Music controlling
    • Playing/pausing songs
    • Unlimited skipping, replaying, and playing previous songs
    • Shuffle mode
    • Album and song looping
    • Song length bar and time display
    • Volume adjustment
  • Storage saving

Screenshot ๐Ÿ“ท

readme_preview

License ๐Ÿ“œ

MIT

react-tunes's People

Contributors

kennethonuorah avatar

Stargazers

Sutanto Gasali avatar  avatar

Watchers

 avatar

react-tunes's Issues

Playlist viewer (header)

Objectives:

  • Opening playlists in the viewer (displaying its details from the server onto the header) and switching between them
  • Uploading cover art (.png or .jpg) and converting/saving its base64 on the server
  • Uploading songs (.mp3, .ogg, .wav, .flac) and converting/saving its base64 on the server

Music controller features

Objectives

Part 1

  • Set up general functionality for shuffle and repeat buttons
  • Create two useState hooks: songQueueOrdered and songQueueShuffled, both of which are string arrays of songs with each element in the format: "<song artist> - <song title>" Improved this with useReducer in pull request #24
  • Work on the "Begin playlist" button in the header which starts playing the playlist's songs, playing them in an order depending on if shuffle mode is enabled or disabled
  • Work on playing, pausing, and skipping the current song. Also, volume control and looping

Part 2

  • Update the queue as the user uploads, removes, or rearranges a song. This can be accomplished by passing down the artistsText state from App.jsx as a prop into MusicController.jsx. Every time the user uploads, removes, or rearranges a song, the artistsText changes, and so, by putting props.artistsText into a useEffect dependency array, we can update the queues accordingly. However, for playlists that have only one artist, a different approach will be needed (still planning about this)
  • Each song in the viewer has a play button, meaning that the app should allow the user to play a song of their choosing anytime they want. There is a function in MusicController.jsx called playNextSongByChoice that I created to get started on this.
  • If the user removes a song that is currently playing, the music controller should skip it and play the next song in the queue. This can be checked for in the useEffect queue updater function called by the first task of Part 2.
  • The music controller should stop playing music altogether and reset its reducers back to their initial states if the playlist currently playing has been deleted. Instead of making multiple dispatches to reset the reducer states, each reducer should have one more action.type called "reinitialize_state" that resets the reducers back to their initial state.

Part 3

  • The ordered song queue should update every time the songs in the viewer body have been rearranged.

Other features

Loading screen feature

There are times where loading content from the server can be messy and/or take a while for the user to see. A loading screen would mitigate this issue. Use cases:

  • Uploading multiple audio files

Glowing outline for current song

  • In the playlist viewer body, A song's outline should have a glowing outline animation depending on whether or not it is the current song in the music controller. The color of the outline should be a bright, neon blue

Minimize side menu

  • Users should be allowed to minimize the side menu. The reason this feature could be needed is because as the browser window width decreases, it becomes more difficult to read the playlist's name and other content in the viewer. The app logo should be replaced with a side menu minimize-toggle button.

Home screen

  • When the app is first opened or a currently viewed playlist list is deleted, A majority of the screen is either white or dark grey depending on the color theme. Placing a big app logo that was removed from the above task into the blank space would be needed.

JSON-Server Problems

Move all Data Fetching from JSON-Server to new database (undecided)

  • JSON-Server is only suitable for storing string data. For storing anything larger than that (images, audio, videos, etc.). Will need to find a new database and revisit tasks 2 and 3 of issue #9.

  • Have yet to decide which database to use. Potential ones to look into:

    1. LocalForage.js library
    2. Dexie.js/IndexedDB

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.