Skip to content

Commit

Permalink
Adds search icon; fixes file list icon height; fixes header html; fix…
Browse files Browse the repository at this point in the history
…es attachments regex

Signed-off-by: Akash Manohar J <akash@akash.im>
  • Loading branch information
HashNuke committed Apr 2, 2012
1 parent 60150e2 commit 76bfa9e
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 4 deletions.
Binary file added app/assets/images/search_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Expand Up @@ -42,7 +42,7 @@ class Kandan.Plugins.Attachments

@fileIcon: (fileName)->
fileExtension = fileName.split(".").pop()
return "/assets/img_icon.png" if fileExtension.match(/(png|jpeg|gif)/i)
return "/assets/img_icon.png" if fileExtension.match(/(png|jpeg|jpg|gif)/i)
return "/assets/video_icon.png" if fileExtension.match(/(mp3|wav)/i)
return "/assets/audio_icon.png" if fileExtension.match(/(mov|mpg|mpeg|mp4)/i)
return "/assets/file_icon.png"
Expand Down
16 changes: 14 additions & 2 deletions app/assets/stylesheets/_sidebar.sass
Expand Up @@ -56,12 +56,24 @@


.search
width: 200px
min-width: 100px
float: right
text-align: right
input
+border-radius(20px)
background: $search-bg url(image_path('search_icon.png')) no-repeat
background-position: 95% center
width: 100%
background: $search-bg
color: $search-color
border: 2px solid darken($search-bg, 10%)
padding-right: 15%

.header .user
float: right
color: #CCC
padding-left: 10px
padding-right: 10px
img
vertical-align: middle
width: 20px
height: 20px
1 change: 1 addition & 0 deletions app/assets/stylesheets/plugins/_attachments.sass
Expand Up @@ -12,6 +12,7 @@
color: #585D5F
img
width: 14px
height: 12px
margin-right: 10px
a
text-decoration: none
Expand Down
2 changes: 1 addition & 1 deletion app/views/main/index.html.erb
Expand Up @@ -10,12 +10,12 @@
<div class="header">
<%= image_tag "logo.png", :class=>"logo" %>

<div class="user"></div>
<div class="search">
<form method="get" action="/search" target="_blank">
<input type="text" class="query" name="query"/>
</form>
</div>
<div class="user"></div>
</div>

<div id="app_body">
Expand Down

0 comments on commit 76bfa9e

Please sign in to comment.