tududi/app/views/notes/_notes_table.erb
2023-11-17 22:19:01 +02:00

31 lines
No EOL
892 B
Text
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<div class="bg-light shadow-sm">
<table class="table">
<thead>
<tr>
<th scope="col">Content</th>
<th scope="col">Tags</th>
</tr>
</thead>
<tbody>
<% notes.each do |note| %>
<tr>
<td class="w-50">
<div class="note-item" data-note-id="<%= note.id %>">
<a href="#" class="link-secondary  fs-5 text-decoration-none">
<%= note.title %>
</a>
</div>
<div id="edit_note_form_<%= note.id %>" class="d-none">
<%= partial :'notes/_form', locals: { note: note } %>
</div>
</td>
<td>
<% note.tags.each do |tag| %>
<span class="badge bg-primary-subtle text-primary"><%= tag.name %></span>
<% end %>
</td>
</tr>
<% end %>
</tbody>
</table>
</div>