doctype html
html
head
meta charset="UTF-8"
meta http-equiv="X-UA-Compatible" content="IE=edge"
meta name="viewport" content="width=device-width,initial-scale=1"
- cache :title_icon
title = t('app_name')
- begin
= render partial: 'layouts/favicon'
- rescue ActionView::MissingTemplate => e
- pg_err e
- if @turbo_no_cache
meta name="turbo-cache-control" content="no-cache"
/ El morph no estaría siendo de utilidad
/ meta name="turbo-refresh-method" content="morph"
/ En general es deseable el comportamiento scroll "reset", por ejemplo en los forms,
/ ya que los errores se muestran arriba y el botón de submit está abajo
/ meta name="turbo-refresh-scroll" content="preserve"
meta name="turbo-prefetch" content="false"
meta name="view-transition" content="same-origin"
meta name="cable-history-timestamp" content="#{Time.now.to_i}"
= csrf_meta_tags
= csp_meta_tag
= action_cable_with_jwt_meta_tag
= stylesheet_link_tag 'application', 'data-turbo-track': 'reload'
= javascript_include_tag 'application', 'data-turbo-track': 'reload', type: 'module'
meta(name="actioncable-protocol"
content="#{Rails.env.test? ? 'actioncable-v1-json' : 'actioncable-v1-ext-json'}")
- if @rollbar_token.present?
meta name="rollbar-token" content="#{@rollbar_token}"
meta name="rollbar-env" content="#{Rails.env}"
link rel="preconnect" href="https://fonts.googleapis.com"
link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="crossorigin"
link href=PgEngine::GOOGLE_FONTS_URL rel="stylesheet"
css:
body {
font-family: "Ubuntu", sans-serif;
font-weight: 400;
font-style: normal;
}
body
- sidebar_present = @navbar.present? && @sidebar != false
- if sidebar_present
= render partial: 'pg_layout/sidebar_mobile'
div class="#{ 'with-sidebar' if sidebar_present }"
- if sidebar_present
= render partial: 'pg_layout/sidebar'
div
= render partial: 'pg_layout/navbar' if @navbar.present?
div
- if user_signed_in? && breadcrumbs.any?
.d-flex.align-items-center.justify-content-between.px-3.py-1.d-print-none[
style="min-height: 2.5em;"]
nav aria-label="breadcrumb"
= render_breadcrumbs
/ = render_breadcrumbs builder: ::Bootstrap4BreadcrumbsBuilder
.btn-toolbar.gap-1
= yield(:actions)
hr.my-0
- content = content_for?(:content) ? yield(:content) : yield
- unless content.include? 'flash-container'
= render FlashContainerComponent.new
/ TODO: si hay varios flashes toast, se superponen. habría que
hacer un container con position absolute para los toasts
= content
div style="width:100%; height: 10em"
= render_turbo_stream_title