diff --git a/app/controllers/federal_tax_brackets_controller.rb b/app/controllers/federal_tax_brackets_controller.rb index 013b796..88426d5 100644 --- a/app/controllers/federal_tax_brackets_controller.rb +++ b/app/controllers/federal_tax_brackets_controller.rb @@ -4,10 +4,6 @@ class FederalTaxBracketsController < ApplicationController # GET /federal_tax_brackets or /federal_tax_brackets.json def index @federal_tax_brackets = FederalTaxBracket.order_by_range - respond_to do |format| - format.turbo_stream - format.html - end end # GET /federal_tax_brackets/1 or /federal_tax_brackets/1.json diff --git a/app/views/components/_toolbar.html.erb b/app/views/components/_toolbar.html.erb index 0b2be74..6e445a2 100644 --- a/app/views/components/_toolbar.html.erb +++ b/app/views/components/_toolbar.html.erb @@ -4,7 +4,7 @@ <%= link_to "Budget Calculator", root_path, data: { turbo_stream: true }, class: active_tab == :budget_calculator ? "active-toolbar-tab" : "inactive-toolbar-tab" %>
  • - <%= link_to "Federal Tax Brackets", federal_tax_brackets_path, data: { turbo_stream: true }, class: active_tab == :federal_tax_brackets ? "active-toolbar-tab" : "inactive-toolbar-tab" %> + <%= link_to "Federal Tax Brackets", federal_tax_brackets_path, data: { turbo: false }, class: active_tab == :federal_tax_brackets ? "active-toolbar-tab" : "inactive-toolbar-tab" %>
  • <%= link_to "Incomes", incomes_path, data: { turbo: false }, class: active_tab == :incomes ? "active-toolbar-tab" : "inactive-toolbar-tab" %> diff --git a/app/views/federal_tax_brackets/_index.html.erb b/app/views/federal_tax_brackets/_index.html.erb index b133a60..0bb86ef 100644 --- a/app/views/federal_tax_brackets/_index.html.erb +++ b/app/views/federal_tax_brackets/_index.html.erb @@ -1,30 +1,28 @@ -<%= turbo_frame_tag "primary_frame" do %> - <%= turbo_frame_tag :federal_tax_brackets do %> -
    -
    -
    -
    -

    Federal Tax Brackets

    - <%= link_to 'New federal tax bracket', new_federal_tax_bracket_path, class: "rounded-lg p-2 bg-primary-purple inline-block font-medium text-white" %> -
    +<%= turbo_frame_tag :federal_tax_brackets do %> +
    +
    +
    +
    +

    Federal Tax Brackets

    + <%= link_to 'New federal tax bracket', new_federal_tax_bracket_path, class: "rounded-lg p-2 bg-primary-purple inline-block font-medium text-white" %>
    +
    -
    -
    -
    - <% tax_headings = ["Filing Status", "Tier", "From", "To", "Rate", "Cumulative"] %> - <% tax_headings.each do |tax_heading| %> -
    - <%= tax_heading %> -
    - <% end %> -
    -
    - - <%= render @federal_tax_brackets %> +
    +
    +
    + <% tax_headings = ["Filing Status", "Tier", "From", "To", "Rate", "Cumulative"] %> + <% tax_headings.each do |tax_heading| %> +
    + <%= tax_heading %> +
    + <% end %> +
    + + <%= render @federal_tax_brackets %>
    - <% end %> +
    <% end %> diff --git a/app/views/federal_tax_brackets/index.turbo_stream.erb b/app/views/federal_tax_brackets/index.turbo_stream.erb deleted file mode 100644 index 821b797..0000000 --- a/app/views/federal_tax_brackets/index.turbo_stream.erb +++ /dev/null @@ -1,2 +0,0 @@ -<%= turbo_stream.replace "primary_frame", partial: "federal_tax_brackets/index" %> -<%= turbo_stream.replace "dashboard_toolbar", partial: "components/toolbar", locals: { active_tab: :federal_tax_brackets } %> \ No newline at end of file