Skip to content

Instantly share code, notes, and snippets.

<% links = [{:title => 'Inbox', :path => ''},
{:title => 'Exports', :path => ''},
{:title => 'Notifications', :path => ''}] %>
<%=
vertical_tabs do |ui|
links.each do |tab|
ui.tab tab[:title],
tab.delete(:path)
end
end
@tylerlee
tylerlee / item-info-panel.erb
Created January 17, 2014 17:55
example item info panel
<%= render :partial => 'shared/item_info_panel', :locals => {:item => @file} %>
<ul class="has-dropdown">
<li>
<a href="#">I am a dropdown</a>
<ul class="dropdown">
<li>I am a dropdown option</li>
<li>I am a dropdown option</li>
<li>I am a dropdown option</li>
<li>I am a dropdown option</li>
<li>I am a dropdown option</li>
.styleguide-horizontal-list{
@include horizontal-list;
}
<% buttons = [] %>
<% buttons << link_to(icon_tag('edit') + 'Edit', '#') %>
<% buttons << link_to(icon_tag('delete') + 'Delete', '#') %>
<%= action_menu(buttons) %>
<%= render :partial => 'shared/item_info_panel', :locals => {:item => @file} %>
@tylerlee
tylerlee / media-element
Created August 1, 2014 21:47
Media Element
<%= media_element profile_picture(current_user, 64) do %>
<p>Suspendisse vitae augue lectus. Sed velit nisi, molestie eu varius sit amet, condimentum tempor ligula. Duis in tellus nisl. Sed ullamcorper justo id luctus feugiat. Aenean interdum tellus id enim consequat, eget ultricies dolor dictum. Nullam feugiat lectus id molestie vestibulum. Donec pretium nisi vel vehicula tempor. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Sed porta, augue a venenatis consequat, turpis lectus vestibulum urna, ultrices tristique justo nibh ac ante. Nam malesuada adipiscing erat. Sed accumsan mollis sapien, sed rhoncus enim ultricies a. Cras dignissim tincidunt porttitor. Ut in neque elit.</p>
<% end %>
@tylerlee
tylerlee / AdminButtonGroup.html.erb
Last active August 29, 2015 14:04
Admin Button Group
<% buttons = [] %>
<% buttons << link_to(icon_tag('edit') + 'Edit', '') %>
<% buttons << link_to(icon_tag('delete') + 'Delete', '') %>
<% buttons << link_to(icon_tag('upload') + 'Import', '') %>
<%= admin_button_group(buttons) %>
<% buttons = [] %>
<% buttons << link_to(icon_tag('edit') + 'Edit', '') %>
<% buttons << link_to(icon_tag('delete') + 'Delete', '') %>
<% buttons << link_to(icon_tag('upload') + 'Import', '') %>
<%= admin_button_group(buttons) %>
@tylerlee
tylerlee / head.html
Last active August 29, 2015 14:05
default-html-head.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>OrgSync Organization Template</title>
<meta name="keywords" content="" />
<meta name="description" content="" />
<link rel="icon" href="http://www.orgsync.com/images/favicon.ico" type="image/x-icon" />
[[file:orgsync_defaults]]