Make The Stream expandable
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
class Collections::Columns::StreamsController < ApplicationController
|
||||
include CollectionScoped
|
||||
include CollectionScoped, FilterScoped
|
||||
|
||||
def show
|
||||
set_page_and_extract_portion_from @collection.cards.awaiting_triage.reverse_chronologically.with_golden_first
|
||||
|
||||
@@ -1,11 +1,32 @@
|
||||
<%= turbo_frame_tag :stream_column do %>
|
||||
<% if @page.used? %>
|
||||
<%= with_manual_pagination :stream_column, @page do %>
|
||||
<%= render "collections/columns/list", cards: @page.records, draggable: true %>
|
||||
<% @page_title = "Column: The Stream" %>
|
||||
|
||||
<% content_for :header do %>
|
||||
<%= render "filters/menu", user_filtering: @user_filtering %>
|
||||
|
||||
<div class="header__actions header__actions--start">
|
||||
<%= link_to @collection, class: "btn borderless txt-medium", data: { controller: "hotkey", action: "keydown.esc@document->hotkey#click" } do %>
|
||||
<span class="overflow-ellipsis">
|
||||
←
|
||||
<strong><%= @collection.name %></strong>
|
||||
</span>
|
||||
<% end %>
|
||||
<% else %>
|
||||
<div class="card blank-slate blank-slate--card">
|
||||
<p class="txt-align-center txt-normal">Drag cards here</p>
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
<h1 class="header__title divider divider--fade full-width">
|
||||
<span class="overflow-ellipsis"><%= @page_title %></span>
|
||||
</h1>
|
||||
<% end %>
|
||||
|
||||
<section class="cards cards--grid">
|
||||
<%= turbo_frame_tag :stream_column do %>
|
||||
<% if @page.used? %>
|
||||
<%= with_manual_pagination :stream_column, @page do %>
|
||||
<%= render "collections/columns/list", cards: @page.records, draggable: true %>
|
||||
<% end %>
|
||||
<% else %>
|
||||
<div class="card blank-slate blank-slate--card">
|
||||
<p class="txt-align-center txt-normal">Drag cards here</p>
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</section>
|
||||
@@ -5,6 +5,10 @@
|
||||
data-drag-and-drop-url="<%= columns_card_drops_stream_path("__id__") %>">
|
||||
<div class="cards__decoration"></div>
|
||||
|
||||
<header class="cards__expander">
|
||||
<h2 class="cards__expander-title">The Stream</h2>
|
||||
<%= render "collections/show/menu/expand", column_path: collection_columns_stream_path(collection) %>
|
||||
</header>
|
||||
<%= render "columns/show/add_card_button", collection: collection %>
|
||||
|
||||
<% if page.used? %>
|
||||
|
||||
Reference in New Issue
Block a user