0
0
mirror of https://github.com/wagtail/wagtail.git synced 2024-11-29 17:36:49 +01:00
wagtail/client/scss/components/_messages.scss

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

94 lines
1.7 KiB
SCSS
Raw Normal View History

// Messages are specific to Django's 'Messaging' system which adds messages into the session,
2015-11-03 13:15:33 +01:00
// for display on the next page visited. These appear as an animated banner at the top of the page.
// For inline help text, see typography.scss
.messages {
position: relative;
background-color: $color-grey-1;
.buttons {
margin-inline-start: 1em;
}
> ul {
@include unlistimmediate();
position: relative;
top: -100px;
opacity: 0;
}
2015-11-03 13:15:33 +01:00
> ul > li {
// @include nice-padding;
padding: 1.6em 3em 1.6em 1.6em;
2015-11-03 13:15:33 +01:00
color: $color-white;
border-bottom: 1px solid transparent;
}
2014-05-08 17:05:12 +02:00
> ul > li:before {
@include font-smoothing;
margin-inline-end: 0.5em;
font-size: 1.5em;
vertical-align: middle;
2014-05-08 17:05:12 +02:00
}
2020-06-29 17:17:04 +02:00
&-icon {
vertical-align: text-top;
margin-inline-end: 0.5em;
2020-06-29 17:17:04 +02:00
width: 1.5em;
height: 1.5em;
}
.button.button-secondary {
border-color: currentColor;
color: inherit;
&:hover {
background-color: transparent;
color: $color-white;
}
}
.error {
background-color: theme('colors.critical.200');
.button:hover {
color: $color-grey-1;
}
}
2015-11-03 13:15:33 +01:00
.warning {
color: $color-grey-1;
background-color: theme('colors.warning.100');
}
2015-11-03 13:15:33 +01:00
.success {
background-color: theme('colors.positive.100');
.button:hover {
background-color: $color-teal-dark;
}
}
.errorlist {
margin: 0.5em 0 0 1em;
}
}
.messages.new > ul {
transition: none;
top: -100px;
}
.ready .messages > ul,
.messages.appear > ul {
transition: top 0.5s ease, opacity 0.5s ease, max-height 1.2s ease;
opacity: 1;
top: 0;
}
2014-02-06 17:41:52 +01:00
@include media-breakpoint-up(sm) {
.messages > ul > li {
padding-inline-start: 1.6em;
padding-inline-end: 3em;
2014-02-06 17:41:52 +01:00
}
2015-11-03 13:15:33 +01:00
}