Sha256: 417e426d1105afbde84f5906a63ee63aa16b52c136a761a25c3021a492f025b5

Contents?: true

Size: 1009 Bytes

Versions: 2

Compression:

Stored size: 1009 Bytes

Contents

<%
  items = [{:value => "Ruby on Rails", name: "Ruby on Rails"}, {:value => "Next.js", name: "Next.js"}, {:value => "Remix.run", name: "Remix.run"}]
%>

<%= render_component_header title: "Filter",
      description: "Displays a list that is filterable via the included input." %>

<% content_for :preview, flush: true do %>
  <div class="w-full flex justify-center">
  <%= render_filter items, class: "p-1" do %>
    <%= filter_icon do %>
      <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="mr-2 h-4 w-4 shrink-0 opacity-50 ml-2"><circle cx="11" cy="11" r="8"></circle><line x1="21" x2="16.65" y1="21" y2="16.65"></line></svg>
    <% end %>
  <% end %>
<% end %>

<%= render_preview %>

<% content_for :examples, flush: true do %>
  <div class="w-full flex justify-center">
  <%= render_filter items, class: "p-1" do %>
  <% end %>
<% end %>

<%= render_example %>

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
shadcn-ui-0.0.3 app/views/examples/components/filter.html.erb
shadcn-ui-0.0.2 app/views/examples/components/filter.html.erb