Skip to content

Commit

Permalink
WIP: Remove turbo_frames now morphing handles it automatically
Browse files Browse the repository at this point in the history
  • Loading branch information
forsbergplustwo committed Dec 1, 2023
1 parent b4e6d16 commit 75daebf
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 9 deletions.
2 changes: 1 addition & 1 deletion app/views/metrics/_filter.html.erb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<%= form_tag(
url_for(action: action_name, charge_type: filter.charge_type),
method: :get,
data: {controller: "filters", turbo_frame: :metrics, turbo_action: :advance},
data: {controller: "filters"},
) do %>

<%= hidden_field_tag :chart, filter.chart %>
Expand Down
4 changes: 1 addition & 3 deletions app/views/metrics/_forecasts_form.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,7 @@
data: {
controller: "submittable",
submittable_target: "form",
action: "change->submittable#submit",
turbo_frame: :metrics,
turbo_action: :advance
action: "change->submittable#submit"
}
) do |form| %>

Expand Down
4 changes: 0 additions & 4 deletions app/views/metrics/_tile.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,6 @@
content: polaris_icon(name: "ViewMinor", color: :subdued),
title: "View chart",
url: url_for(action: action_name, **filter.to_param.merge(chart: tile.handle)),
data: {
turbo_frame: "metrics",
turbo_action: "advance",
},
}]
) do %>
<%= polaris_stack(alignment: :center) do |stack| %>
Expand Down
2 changes: 1 addition & 1 deletion app/views/metrics/show.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

<%= render "shared/page_actions", page: page %>

<%= turbo_frame_tag :metrics, data: { controller: "loading" } do %>
<%= tag.div data: { controller: "loading" } do %>

<%= polaris_vertical_stack(gap: "6") do %>

Expand Down

0 comments on commit 75daebf

Please sign in to comment.