Mattias Bodlund 1 year ago
parent
commit
daf5de0676
5 changed files with 7 additions and 8 deletions
  1. +4
    -3
      app/assets/stylesheets/application.css
  2. +1
    -0
      app/controllers/admin/admin_controller.rb
  3. +0
    -2
      app/controllers/admin/nodes_controller.rb
  4. +2
    -2
      app/controllers/site_controller.rb
  5. +0
    -1
      app/views/site/tmpl_article.html.erb

+ 4
- 3
app/assets/stylesheets/application.css View File

@ -209,6 +209,7 @@ main {
border: 2px solid var(--clr-black); border: 2px solid var(--clr-black);
font-size: var(--fs-lg); font-size: var(--fs-lg);
font-weight: 700; font-weight: 700;
font-family: var(--ff-ikea);
line-height: 1; line-height: 1;
color: var(--clr-black); color: var(--clr-black);
padding: 0.888888888888889em 1.333333333333333em; padding: 0.888888888888889em 1.333333333333333em;
@ -460,12 +461,12 @@ ul.card__stack {
.link__learn-more { .link__learn-more {
font-weight: 700; font-weight: 700;
padding: 1em 0;
margin-bottom: 1em;
margin-bottom: 20px;
border-top: 1px solid var(--clr-black); border-top: 1px solid var(--clr-black);
border-bottom: 1px solid var(--clr-black); border-bottom: 1px solid var(--clr-black);
& a { & a {
padding: 1.25em 0;
display: block; display: block;
color: var(--clr-black); color: var(--clr-black);
text-decoration: none; text-decoration: none;
@ -526,7 +527,7 @@ ul.card__stack {
.link { .link {
display: grid; display: grid;
grid-template-columns: 1fr 1fr; grid-template-columns: 1fr 1fr;
grid-template-rows: 2fr 1fr;
grid-template-rows: 1fr fit-content(84px);
gap: 32px; gap: 32px;
margin-bottom: 40px; margin-bottom: 40px;


+ 1
- 0
app/controllers/admin/admin_controller.rb View File

@ -4,6 +4,7 @@ class Admin::AdminController < ApplicationController
before_action :authenticate_user! before_action :authenticate_user!
before_action :only_admin! before_action :only_admin!
before_action :set_locale_to_default
helper_method :current_user helper_method :current_user
helper_method :user_signed_in? helper_method :user_signed_in?


+ 0
- 2
app/controllers/admin/nodes_controller.rb View File

@ -2,8 +2,6 @@ class Admin::NodesController < Admin::AdminController
before_action :set_node, only: %i[ edit update destroy children sort toggle ] before_action :set_node, only: %i[ edit update destroy children sort toggle ]
before_action :set_locale_to_default, only: %i[ create ]
helper_method :current_node_id, :open_node_ids helper_method :current_node_id, :open_node_ids
# GET /nodes # GET /nodes


+ 2
- 2
app/controllers/site_controller.rb View File

@ -19,8 +19,8 @@ class SiteController < ApplicationController
redirect_to @node.children.viewable.ordered.first.url and return if @node.index? and @node.children.viewable.any? redirect_to @node.children.viewable.ordered.first.url and return if @node.index? and @node.children.viewable.any?
# Link or render # Link or render
# @node.href.present? ? redirect_to(@node.href) :
# render(template: "site/#{@node.template}")
redirect_to(@node.href) and return if @node.href.present?
render(template: "site/#{@node.template}") render(template: "site/#{@node.template}")
end end


+ 0
- 1
app/views/site/tmpl_article.html.erb View File

@ -26,7 +26,6 @@
<%= tag.div class: "link__learn-more" do %> <%= tag.div class: "link__learn-more" do %>
<%= link_to t('learn_more'), @node.href %> <%= link_to t('learn_more'), @node.href %>
<% end %> <% end %>
<% end %> <% end %>


Loading…
Cancel
Save