From 152cb13a02dfcb2966b8a9b29382f84a99a23a69 Mon Sep 17 00:00:00 2001 From: Harry Wood Date: Mon, 24 Nov 2008 00:40:04 +0000 Subject: [PATCH] cosmetic tweaks to diary interface. icon for new entries link --- app/views/diary_entry/edit.rhtml | 14 ++++++++----- app/views/diary_entry/list.rhtml | 33 ++++++++++++++++++++----------- public/images/new.png | Bin 0 -> 991 bytes public/stylesheets/site.css | 6 ++++++ 4 files changed, 37 insertions(+), 16 deletions(-) create mode 100644 public/images/new.png diff --git a/app/views/diary_entry/edit.rhtml b/app/views/diary_entry/edit.rhtml index 87f5e9fac..a69f4fd9c 100644 --- a/app/views/diary_entry/edit.rhtml +++ b/app/views/diary_entry/edit.rhtml @@ -5,24 +5,28 @@ <% form_for :diary_entry do |f| %> - + - + - + - - + +
SubjectSubject: <%= f.text_field :title, :size => 60 %>
BodyBody: <%= f.text_area :body, :cols => 80 %>
LocationLocation: Latitude: <%= f.text_field :latitude, :size => 20, :id => "latitude" %> Longitude: <%= f.text_field :longitude, :size => 20, :id => "longitude" %> use map +

<%= submit_tag 'Save' %> + <%= submit_tag 'Save' %> + <%# TODO: button should say 'publish' or 'save changes' depending on new/edit state %> +
<% end %> diff --git a/app/views/diary_entry/list.rhtml b/app/views/diary_entry/list.rhtml index 7a2ccf74d..9852313bb 100644 --- a/app/views/diary_entry/list.rhtml +++ b/app/views/diary_entry/list.rhtml @@ -4,29 +4,40 @@ <%= image_tag url_for_file_column(@this_user, "image") %> <% end %> -
<% if @this_user %> <% if @user == @this_user %> - <%= link_to 'New diary entry', :controller => 'diary_entry', :action => 'new', :display_name => @user.display_name %> + <%= link_to image_tag("new.png", :border=>0) + 'New diary entry', {:controller => 'diary_entry', :action => 'new', :display_name => @user.display_name}, {:title => 'Compose a new entry in your user diary'} %> <% end %> <% else %> <% if @user %> - <%= link_to 'New diary entry', :controller => 'diary_entry', :action => 'new', :display_name => @user.display_name %> + <%= link_to image_tag("new.png", :border=>0) + 'New diary entry', {:controller => 'diary_entry', :action => 'new', :display_name => @user.display_name}, {:title => 'Compose a new entry in your user diary'} %> <% end %> <% end %> -

Recent diary entries:

-<%= render :partial => 'diary_entry', :collection => @entries %> +<% if @entries.empty? %> +

No diary entries

-<%= link_to "Older Entries", { :page => @entry_pages.current.next } if @entry_pages.current.next %> -<% if @entry_pages.current.next and @entry_pages.current.previous %> -| +<% else %> + +

Recent diary entries:

+
+ <%= render :partial => 'diary_entry', :collection => @entries %> + + <%= link_to "Older Entries", { :page => @entry_pages.current.next } if @entry_pages.current.next %> + <% if @entry_pages.current.next and @entry_pages.current.previous %> + | + <% end %> + <%= link_to "Newer Entries", { :page => @entry_pages.current.previous } if @entry_pages.current.previous %> + +
+ <% end %> -<%= link_to "Newer Entries", { :page => @entry_pages.current.previous } if @entry_pages.current.previous %> - -
<%= rss_link_to :action => 'rss' %> <%= auto_discovery_link_tag :atom, :action => 'rss' %> + + +
+
\ No newline at end of file diff --git a/public/images/new.png b/public/images/new.png new file mode 100644 index 0000000000000000000000000000000000000000..202e10eca8aff2839d598e91428029a7f44d6d73 GIT binary patch literal 991 zcmV<510ei~P)Px#1ZP1_K>z@;j|==^1poj5AY({UO#lFTCIA3{ga82g0001h=l}q9FaQARU;qF* zm;eA5aGbhPJOBUy32;bRa{vGfh5!Hyh5N2bPDNB8b~7$BH8Ae8p8x;@5lKWrR5(w4lv_v?Q5eTn zv$(|r31e`GqZDk=l`8KGs#K+X`w()T2d0$(=8jQ zPmSK1yhuL_)Q8hECJ`Tgv!iV<(LwaaxZS1hee}4pZ)m9a*_Y3Sy7BRX;qmeOVUa&x z9ts>fOKe{=KNF078(W^6b7Ovfo^TP9kX-j5d72>!MVQkcgJ?bjBX`>75)StS{n>>i z+MJlAmk9!a0F%&LfHEd9?Kqx+)mLi?dv2-9uX~*mB11( ziR_ml%Rk_Clwd*Xz@Oj;EH8;9VQmSEp-%|QFCot!;6j1yB9dezNF*98N0Vsl2_<}% zTr4jOtAbd!h>%c@fM@sDP#~+4M44+OUayzdLLx@t^LE3>pTI9~S0q8KErll`JB}jg z+s`CrB-s|1NRh#wND{TSfvBN0sG?=yo!)Z0ok63Ab$xVu?#lDDR|sRdML#~k|f6^PTmQ(ON=Jb zG!ZO~il`#Wsk{P`o+mD2YN`~R{@j)LlZibYyWIv+;2{W3IGr{)9acE(li;0$5cxj1 zgbw<@6E5)yMn?M3eWxjF&1P%A)z-@-Jnx7kY1T9*&_Kua5iI6W*sRld_x>$tTda|! zw6$v=Sgo_Gv(Lh2v%qRKVb)@V+04Og(!*$&hJl-g$;4rB=nb1BCoxHywzav>V9>*E zPZStvFb9)y21X+j{G@f5qT?Bo=y0Q~G?yePF;S|frRna(#P=1BL>$MMiKD04_4)+p zeBf38?`tK+d5MzbYDLA#W=+HW`o`L)sygM18dY__qNZw~T3PYBN>QO>&^sUcSvS*QR2 N002ovPDHLkV1lVBuzCOh literal 0 HcmV?d00001 diff --git a/public/stylesheets/site.css b/public/stylesheets/site.css index 2bfe21d24..764d8971b 100644 --- a/public/stylesheets/site.css +++ b/public/stylesheets/site.css @@ -277,6 +277,12 @@ hides rule from IE5-Mac \*/ font-size: 10px; } +hr { + border: none; + background-color: #ccc; + color: #ccc; + height: 1px; +} .gpxsummary { font-size: 12px; -- 2.43.2