From fd855a1e93be4d39220cebdaf8a4612ffef2293a Mon Sep 17 00:00:00 2001 From: f Date: Tue, 8 Nov 2022 20:19:53 -0300 Subject: [PATCH] fix: ajustes para el contenido #8395 --- app/assets/stylesheets/application.scss | 29 +++++++++++++++++++++++++ app/views/posts/show.haml | 2 +- 2 files changed, 30 insertions(+), 1 deletion(-) diff --git a/app/assets/stylesheets/application.scss b/app/assets/stylesheets/application.scss index 649c272d..818ebbd5 100644 --- a/app/assets/stylesheets/application.scss +++ b/app/assets/stylesheets/application.scss @@ -515,3 +515,32 @@ $bezier: cubic-bezier(0.75, 0, 0.25, 1); } } } + +.content { + p { min-height: $font-size-base * $line-height-base; } + h1 { min-height: $h1-font-size * $headings-line-height; } + h2 { min-height: $h2-font-size * $headings-line-height; } + h3 { min-height: $h3-font-size * $headings-line-height; } + h4 { min-height: $h4-font-size * $headings-line-height; } + h5 { min-height: $h5-font-size * $headings-line-height; } + h6 { min-height: $h6-font-size * $headings-line-height; } + + iframe { border: 0; } + + audio { width: 100%; } + + img, + video, + iframe { + @extend .img-fluid; + height: auto; + } + + & > * { + margin-bottom: 1rem; + + &:last-child { + margin-bottom: 0; + } + } +} diff --git a/app/views/posts/show.haml b/app/views/posts/show.haml index e46114af..da3dd16a 100644 --- a/app/views/posts/show.haml +++ b/app/views/posts/show.haml @@ -37,5 +37,5 @@ - next if metadata.front_matter? - cache [metadata, I18n.locale] do - %section.editor{ id: attr, dir: dir } + %section.content.pb-3{ id: attr, dir: dir } = @post.public_send(attr).value.html_safe