From f02f545e0eb4cc8fca282465ccdf54f29d0a1acc Mon Sep 17 00:00:00 2001 From: Andres Galante Date: Thu, 24 Aug 2017 22:11:36 -0300 Subject: [PATCH] changes the order of the close btn on alerts to improve accecibility --- docs/4.0/components/alerts.md | 2 +- scss/_alert.scss | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/docs/4.0/components/alerts.md b/docs/4.0/components/alerts.md index 90c146362e..b8bb0c2168 100644 --- a/docs/4.0/components/alerts.md +++ b/docs/4.0/components/alerts.md @@ -59,10 +59,10 @@ You can see this in action with a live demo: {% example html %} {% endexample %} diff --git a/scss/_alert.scss b/scss/_alert.scss index 3dfd13f56a..66fba24ead 100644 --- a/scss/_alert.scss +++ b/scss/_alert.scss @@ -3,6 +3,7 @@ // .alert { + position: relative; padding: $alert-padding-y $alert-padding-x; margin-bottom: $alert-margin-bottom; border: $alert-border-width solid transparent; @@ -28,9 +29,9 @@ .alert-dismissible { // Adjust close link position .close { - position: relative; - top: -$alert-padding-y; - right: -$alert-padding-x; + position: absolute; + top: 0; + right: 0; padding: $alert-padding-y $alert-padding-x; color: inherit; }