GitHub Sale: sign up for any paid plan this week and pay nothing until January 1, 2009!  [ hide ]

public
Description: A simple chord viewing interface layered upon pngs of mandolin chords I found somewhere a while ago.
Clone URL: git://github.com/kjell/chords.git
Add a page for single chords, style tweaks.
kjell (author)
Sat Aug 09 19:02:50 -0700 2008
commit  a82c22c06aebf7df67ff6ad496f957653be533d0
tree    a26257ac3098f114bc7da0f6cea6da27a856b416
parent  9b7663ee01d496bb08815add3d5c5206838be583
...
31
32
33
 
 
 
 
 
34
35
...
31
32
33
34
35
36
37
38
39
40
0
@@ -31,4 +31,9 @@ end
0
 get('/find') do
0
   @chords = group(find(/#{params[:q]}/))
0
   haml :chords
0
+end
0
+
0
+get('/c/:name') do
0
+ @chord = find(params[:name]).first
0
+ haml :chord
0
 end
0
\ No newline at end of file
...
6
7
8
9
 
10
11
12
13
...
6
7
8
 
9
10
11
12
13
0
@@ -6,7 +6,7 @@
0
   %p= "sorry, no chords for ''#{params[:q]}'" if @chords.empty? && params[:q]
0
   - @chords.each do |family, chords|
0
     - chords.each do |chord|
0
- %li= %[<a href="#{chord.path}">#{chord.chord}</a>]
0
+ %li= %[<a href="/c/#{chord.chord}">#{chord.chord}</a>]
0
     %hr
0
     
0
   %a{:href => '/'} back
0
\ No newline at end of file
...
2
3
4
5
 
 
 
 
6
7
...
2
3
4
 
5
6
7
8
9
10
0
@@ -2,6 +2,9 @@
0
   %head
0
     %title= @title || 'Chords!'
0
     %link{:rel => 'stylesheet', :href => "/ornamentation.css", :type => 'text/css'}
0
-
0
+ %meta{:name => 'viewport', :content => 'width=320px'}
0
+ - %w[jquery search].each do |js|
0
+ %script{:src => "/#{js}.js", :type => 'text/javascript'}
0
+
0
   %body
0
     = yield

Comments

    No one has commented yet.