feat: initialize project with .gitignore, LICENSE, README, and update dependencies
This commit is contained in:
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
/target
|
||||||
|
.env
|
||||||
1
Cargo.lock
generated
1
Cargo.lock
generated
@@ -276,6 +276,7 @@ version = "0.1.0"
|
|||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"async-trait",
|
"async-trait",
|
||||||
|
"domain",
|
||||||
"rand 0.10.0",
|
"rand 0.10.0",
|
||||||
"reqwest",
|
"reqwest",
|
||||||
"serde",
|
"serde",
|
||||||
|
|||||||
3
README.md
Normal file
3
README.md
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
# PocketChords
|
||||||
|
|
||||||
|
A rip-off of [TabsUltimate](https://www.tabultimateguitar.com/) with a focus on mobile users, without any ads or subscription. It is open source and free to use.
|
||||||
@@ -6,8 +6,9 @@
|
|||||||
@custom-variant dark (&:is(.dark *));
|
@custom-variant dark (&:is(.dark *));
|
||||||
|
|
||||||
@theme {
|
@theme {
|
||||||
--font-sans: "Inter", ui-sans-serif, system-ui, sans-serif,
|
--font-sans:
|
||||||
"Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
|
"Inter", ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji",
|
||||||
|
"Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
|
||||||
}
|
}
|
||||||
|
|
||||||
html,
|
html,
|
||||||
@@ -21,7 +22,7 @@ body {
|
|||||||
|
|
||||||
@theme inline {
|
@theme inline {
|
||||||
--font-heading: var(--font-sans);
|
--font-heading: var(--font-sans);
|
||||||
--font-sans: 'Inter Variable', sans-serif;
|
--font-sans: "Inter Variable", sans-serif;
|
||||||
--color-sidebar-ring: var(--sidebar-ring);
|
--color-sidebar-ring: var(--sidebar-ring);
|
||||||
--color-sidebar-border: var(--sidebar-border);
|
--color-sidebar-border: var(--sidebar-border);
|
||||||
--color-sidebar-accent-foreground: var(--sidebar-accent-foreground);
|
--color-sidebar-accent-foreground: var(--sidebar-accent-foreground);
|
||||||
|
|||||||
@@ -1,128 +0,0 @@
|
|||||||
import type { Song, SongSummary } from "./types";
|
|
||||||
import { previewChords } from "./song-utils";
|
|
||||||
|
|
||||||
const OCEAN: Song = {
|
|
||||||
meta: {
|
|
||||||
title: "A Drop In The Ocean",
|
|
||||||
artist: "Ron Pope",
|
|
||||||
capo: null,
|
|
||||||
original_key: "Em",
|
|
||||||
tuning: null,
|
|
||||||
tempo: null,
|
|
||||||
},
|
|
||||||
sections: [
|
|
||||||
{
|
|
||||||
kind: "chorus",
|
|
||||||
label: "Chorus",
|
|
||||||
lines: [
|
|
||||||
{
|
|
||||||
text: "A drop in the ocean,",
|
|
||||||
chords: [{ offset: 0, chord: "Em" }, { offset: 12, chord: "C" }],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
text: "A change in the weather,",
|
|
||||||
chords: [{ offset: 2, chord: "G" }, { offset: 16, chord: "D" }],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
text: "I was praying that you and me might end up together.",
|
|
||||||
chords: [
|
|
||||||
{ offset: 6, chord: "Em" },
|
|
||||||
{ offset: 17, chord: "C" },
|
|
||||||
{ offset: 33, chord: "G" },
|
|
||||||
{ offset: 44, chord: "D" },
|
|
||||||
],
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
kind: "verse",
|
|
||||||
label: "Verse",
|
|
||||||
lines: [
|
|
||||||
{
|
|
||||||
text: "I don't wanna waste the weekend,",
|
|
||||||
chords: [{ offset: 0, chord: "C" }, { offset: 15, chord: "G" }],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
text: "If you don't love me, pretend",
|
|
||||||
chords: [{ offset: 3, chord: "D" }, { offset: 21, chord: "Em" }],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
text: "A few more hours, then it's time to go.",
|
|
||||||
chords: [{ offset: 2, chord: "C" }, { offset: 18, chord: "G" }, { offset: 30, chord: "D" }],
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
kind: "bridge",
|
|
||||||
label: "Bridge",
|
|
||||||
lines: [
|
|
||||||
{
|
|
||||||
text: "Still I can't let you be,",
|
|
||||||
chords: [{ offset: 0, chord: "Am" }, { offset: 11, chord: "G" }, { offset: 13, chord: "D" }],
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
],
|
|
||||||
};
|
|
||||||
|
|
||||||
const NAKED: Song = {
|
|
||||||
meta: {
|
|
||||||
title: "Naked",
|
|
||||||
artist: "James Arthur",
|
|
||||||
capo: null,
|
|
||||||
original_key: "G",
|
|
||||||
tuning: null,
|
|
||||||
tempo: null,
|
|
||||||
},
|
|
||||||
sections: [
|
|
||||||
{
|
|
||||||
kind: "chorus",
|
|
||||||
label: "Chorus",
|
|
||||||
lines: [
|
|
||||||
{
|
|
||||||
text: "I'm not going to wait until you're done",
|
|
||||||
chords: [{ offset: 0, chord: "G" }, { offset: 18, chord: "Bm" }],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
text: "Pretending you don't need anyone",
|
|
||||||
chords: [{ offset: 16, chord: "Em" }, { offset: 27, chord: "C" }],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
text: "I'm standing here naked",
|
|
||||||
chords: [{ offset: 19, chord: "G" }],
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
kind: "verse",
|
|
||||||
label: "Verse",
|
|
||||||
lines: [
|
|
||||||
{
|
|
||||||
text: "I lay awake thinking of all I wasted",
|
|
||||||
chords: [{ offset: 0, chord: "G" }, { offset: 22, chord: "Bm" }],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
text: "All of the time we had I took for granted",
|
|
||||||
chords: [{ offset: 11, chord: "Em" }, { offset: 32, chord: "C" }],
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
],
|
|
||||||
};
|
|
||||||
|
|
||||||
const SONGS_MAP: Record<string, Song> = {
|
|
||||||
"song-ocean": OCEAN,
|
|
||||||
"song-naked": NAKED,
|
|
||||||
};
|
|
||||||
|
|
||||||
export const MOCK_SONGS: SongSummary[] = Object.entries(SONGS_MAP).map(
|
|
||||||
([id, song]) => ({
|
|
||||||
id,
|
|
||||||
meta: song.meta,
|
|
||||||
preview_chords: previewChords(song),
|
|
||||||
})
|
|
||||||
);
|
|
||||||
|
|
||||||
export function getMockSong(id: string): Song | null {
|
|
||||||
return SONGS_MAP[id] ?? null;
|
|
||||||
}
|
|
||||||
Reference in New Issue
Block a user