Skip to content

Plainchord is a text pattern that represents chord symbols used in songs.

Notifications You must be signed in to change notification settings

ecclecias/plainchord

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PlainChord

This is an initiative to create a Universal Standard for Chord data.

How does it work?

A plain text file following the established Text Standard is transformed into an Object that can be viewed through the Component.

PlainChord (Text Standard)

The Chords have title, author, capo fields, in addition to sections.

Following the Standard:

Title
Author
#1

@Into
$C $G/B $Am

@Music
$C Doxa tō Theō $G/B Lorren $Am Christos

Thus forming a "complete" Chord for the interpreter.

Chord Object (JSON)

PlainChord is transpiled to an Object:

{
    "title": "Title",
    "artist": "Author",
    "capo": 1,
    "sections": [
        {
            "lyrics": [
                {
                    "title": "Into",
                    "chords": [
                        [
                            {
                                "chord": "C",
                                "lyrics": ""
                            },
                            {
                                "chord": "G/B",
                                "lyrics": ""
                            },
                            {
                                "chord": "Am",
                                "lyrics": ""
                            }
                        ]
                    ],
                    "repeat": 0
                }
            ]
        },
        {
            "lyrics": [
                {
                    "title": "Music",
                    "chords": [
                        [
                            {
                                "chord": "C",
                                "lyrics": " Doxa tō Theō"
                            },
                            {
                                "chord": "G/B",
                                "lyrics": " Lorren"
                            },
                            {
                                "chord": "Am",
                                "lyrics": " Christos"
                            }
                        ]
                    ],
                    "repeat": 0
                }
            ]
        }
    ]
}

To be displayed by a React Component.

Example via cID.

Possible Improvements

  • Improve Parse and Stringify logic (?)
  • Improve logic that gets the Tonic
  • Implement Tablatures
  • Documentation about .Chord and .PlainChord and how to use them
  • Create Unit Tests
  • Implement Typescript
  • Support for "Embed"
  • Auto Scroll

About

Plainchord is a text pattern that represents chord symbols used in songs.

Topics

Resources

Stars

Watchers

Forks