On this page
Full footer with feedback link, resource dropdown, copyright, policy links, and social icons.
layout.build_footer do |footer|
footer.build_left do |left|
left.build_text_link("Feedback", "#")
left.build_dropdown(direction: "up") do |dropdown|
dropdown.build_button("Resources")
dropdown.build_menu do |menu|
menu.build_item("Documentation", "#")
menu.build_item("API Reference", "#")
menu.build_item("Status Page", "#")
end
end
end
footer.build_right do |right|
right.build_text_link("Privacy", "#")
right.build_text_link("Terms", "#")
right.build_icon_link("info", "#")
right.build_icon_link("settings", "#")
right.build_copyright(start_year: 2024, company_name: "Acme Corp")
end
end
<footer class="footer">
<div class="footer-left">
<a class="footer-btn" href="#">Feedback</a>
<div class="dropdown dropdown-up" data-controller="dropdown">
<button data-action="click->dropdown#toggle" class="btn">
Resources
<svg class="dropdown-arrow" xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewbox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="m18 15-6-6-6 6"></path></svg>
</button>
<div class="dropdown-menu" data-dropdown-target="menu" data-action="click->dropdown#close">
<a class="dropdown-menu-item" href="#">Documentation</a>
<a class="dropdown-menu-item" href="#">API Reference</a>
<a class="dropdown-menu-item" href="#">Status Page</a>
</div>
</div>
</div>
<div class="footer-right">
<a class="footer-btn" href="#">Privacy</a>
<a class="footer-btn" href="#">Terms</a>
<a class="footer-btn" href="#">
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewbox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"></circle><path d="M12 16v-4"></path><path d="M12 8h.01"></path></svg>
</a>
<a class="footer-btn" href="#">
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewbox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915"></path><circle cx="12" cy="12" r="3"></circle></svg>
</a>
<span>© 2024-2026, Acme Corp</span>
</div>
</footer>
The footer is divided into left and right sections. Use build_left and build_right to position items.
layout.build_footer do |footer|
footer.build_left do |left|
left.build_text_link("Left content", "#")
end
footer.build_right do |right|
right.build_text_link("Right content", "#")
end
end
<footer class="footer">
<div class="footer-left">
<a class="footer-btn" href="#">Left content</a>
</div>
<div class="footer-right">
<a class="footer-btn" href="#">Right content</a>
</div>
</footer>
Display copyright information with automatic year range formatting.
ui.build(RapidUI::Layout::Footer::Base) do |footer|
footer.build_left do |right|
right.build_copyright(start_year: 2024, company_name: "Acme Corp")
end
end
<footer class="footer">
<div class="footer-left">
<span>© 2024-2026, Acme Corp</span>
</div>
</footer>
Add text-based links for policies, legal pages, or other footer navigation.
layout.build_footer do |footer|
footer.build_left do |right|
right.build_text_link("Privacy", "#")
right.build_text_link("Terms", "#")
right.build_text_link("Contact", "#")
end
end
<footer class="footer">
<div class="footer-left">
<a class="footer-btn" href="#">Privacy</a>
<a class="footer-btn" href="#">Terms</a>
<a class="footer-btn" href="#">Contact</a>
</div>
</footer>
Add icon-only links for compact actions or external resources.
layout.build_footer do |footer|
footer.build_left do |right|
right.build_icon_link("info", "#")
right.build_icon_link("settings", "#")
right.build_icon_link("user", "#")
end
end
<footer class="footer">
<div class="footer-left">
<a class="footer-btn" href="#">
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewbox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"></circle><path d="M12 16v-4"></path><path d="M12 8h.01"></path></svg>
</a>
<a class="footer-btn" href="#">
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewbox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915"></path><circle cx="12" cy="12" r="3"></circle></svg>
</a>
<a class="footer-btn" href="#">
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewbox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2"></path><circle cx="12" cy="7" r="4"></circle></svg>
</a>
</div>
</footer>
Add dropdown menus that open upward for additional links. Set direction: "up" since the footer is at the bottom of the page.
layout.build_footer do |footer|
footer.build_left do |left|
left.build_dropdown(direction: "up") do |dropdown|
dropdown.build_button("Legal")
dropdown.build_menu do |menu|
menu.build_item("Privacy Policy", "#")
menu.build_item("Terms of Service", "#")
menu.build_item("Cookie Settings", "#")
end
end
end
end
<footer class="footer">
<div class="footer-left">
<div class="dropdown dropdown-up" data-controller="dropdown">
<button data-action="click->dropdown#toggle" class="btn">
Legal
<svg class="dropdown-arrow" xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewbox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="m18 15-6-6-6 6"></path></svg>
</button>
<div class="dropdown-menu" data-dropdown-target="menu" data-action="click->dropdown#close">
<a class="dropdown-menu-item" href="#">Privacy Policy</a>
<a class="dropdown-menu-item" href="#">Terms of Service</a>
<a class="dropdown-menu-item" href="#">Cookie Settings</a>
</div>
</div>
</div>
</footer>