Fix alert/message bar display.

This commit is contained in:
Nate 2018-12-12 14:52:56 -07:00
parent 550e7f2598
commit 3df76a13c9
2 changed files with 24 additions and 74 deletions

View File

@ -1335,66 +1335,9 @@ $default_login = ($_REQUEST['login'] == 'default') ? true : false;
padding: 4px 7px; padding: 4px 7px;
} }
/* RESPONSE MESSAGES *******************************************************/ /* RESPONSE MESSAGE STACK *******************************************************/
#message_container { #message_container {
z-index: 99998;
position: absolute;
top: -80px;
left: 0;
right: 0;
filter: alpha(opacity=0);
opacity: 0;
-moz-opacity:0;
-khtml-opacity: 0;
padding: 15px 0;
}
#message_text {
z-index: 99999;
position: absolute;
top: -80px;
left: 0;
right: 0;
filter: alpha(opacity=0);
opacity: 0;
-moz-opacity:0;
-khtml-opacity: 0;
margin: 0 auto;
vertical-align: middle;
padding: 15px 0;
text-align: center;
font-family: arial, san-serif;
font-size: 10pt;
}
.message_container_mood_default {
background: <?php echo $_SESSION['theme']['message_default_background_color']['text']; ?>;
}
.message_container_mood_negative {
background: <?php echo $_SESSION['theme']['message_negative_background_color']['text']; ?>;
}
.message_container_mood_alert {
background: <?php echo $_SESSION['theme']['message_alert_background_color']['text']; ?>;
}
.message_text_mood_default {
color: <?php echo $_SESSION['theme']['message_default_color']['text']; ?>;
}
.message_text_mood_negative {
color: <?php echo $_SESSION['theme']['message_negative_color']['text']; ?>;
}
.message_text_mood_alert {
color: <?php echo $_SESSION['theme']['message_alert_color']['text']; ?>;
}
/* MESSAGES STACK *******************************************************/
#messages_container {
z-index: 99998; z-index: 99998;
position: absolute; position: absolute;
top: 0; top: 0;
@ -1406,33 +1349,37 @@ $default_login = ($_REQUEST['login'] == 'default') ? true : false;
.message_text { .message_text {
z-index: 99999; z-index: 99999;
margin: 0 auto; margin: 0 auto;
padding: 0.5em 0; padding: 10px;
text-align: center; text-align: center;
font-family: arial, san-serif; font-family: arial, san-serif;
font-size: 10pt; font-size: 10pt;
display: block; display: block;
border-bottom: solid 1px;
color: <?php echo $_SESSION['theme']['message_default_color']['text']; ?>; color: <?php echo $_SESSION['theme']['message_default_color']['text']; ?>;
background: <?php echo $_SESSION['theme']['message_default_background_color']['text']; ?>; background: <?php echo $_SESSION['theme']['message_default_background_color']['text']; ?>;
border-bottom-color: <?php echo $_SESSION['theme']['message_default_color']['text']; ?>; box-shadow: inset 0px 7px 8px -10px <?php echo $_SESSION['theme']['message_default_color']['text']; ?>;
border-bottom: solid 1px <?php echo $_SESSION['theme']['message_default_color']['text']; ?>;
opacity: 0;
}
.message_mood_positive {
color: <?php echo $_SESSION['theme']['message_positive_color']['text']; ?>;
background: <?php echo $_SESSION['theme']['message_positive_background_color']['text']; ?>;
box-shadow: inset 0px 7px 8px -10px <?php echo $_SESSION['theme']['message_positive_color']['text']; ?>;
border-bottom: solid 1px <?php echo $_SESSION['theme']['message_positive_color']['text']; ?>;
} }
.message_mood_positive {
color: <?php echo $_SESSION['theme']['message_positive_color']['text']; ?>;
background: <?php echo $_SESSION['theme']['message_positive_background_color']['text']; ?>;
border-bottom-color: <?php echo $_SESSION['theme']['message_positive_color']['text']; ?>;
}
.message_mood_negative { .message_mood_negative {
color: <?php echo $_SESSION['theme']['message_negative_color']['text']; ?>; color: <?php echo $_SESSION['theme']['message_negative_color']['text']; ?>;
background: <?php echo $_SESSION['theme']['message_negative_background_color']['text']; ?>; background: <?php echo $_SESSION['theme']['message_negative_background_color']['text']; ?>;
border-bottom-color: <?php echo $_SESSION['theme']['message_negative_color']['text']; ?>; box-shadow: inset 0px 7px 8px -10px <?php echo $_SESSION['theme']['message_negative_color']['text']; ?>;
border-bottom: solid 1px <?php echo $_SESSION['theme']['message_negative_color']['text']; ?>;
} }
.message_mood_alert { .message_mood_alert {
color: <?php echo $_SESSION['theme']['message_alert_color']['text']; ?>; color: <?php echo $_SESSION['theme']['message_alert_color']['text']; ?>;
background: <?php echo $_SESSION['theme']['message_alert_background_color']['text']; ?>; background: <?php echo $_SESSION['theme']['message_alert_background_color']['text']; ?>;
border-bottom-color: <?php echo $_SESSION['theme']['message_alert_color']['text']; ?>; box-shadow: inset 0px 7px 8px -10px <?php echo $_SESSION['theme']['message_alert_color']['text']; ?>;
border-bottom: solid 1px <?php echo $_SESSION['theme']['message_alert_color']['text']; ?>;
} }
/* OPERATOR PANEL ****************************************************************/ /* OPERATOR PANEL ****************************************************************/

View File

@ -75,19 +75,22 @@
message_text.click(function() { message_text.click(function() {
var object = $(this); var object = $(this);
object.clearQueue().finish(); object.clearQueue().finish();
object.animate({height: '0', 'font-size': '0', 'border-bottom-width': '0'}, 1000).animate({opacity: 0}); $("#message_container").css({'display':'none'});
} ); } );
$("#message_container").append(message_text); $("#message_container").append(message_text);
message_text.animate({opacity: 1}, 'fast').delay(delay).animate({height: '0', 'font-size': '0', 'border-bottom-width': '0'}, 1000).animate({opacity: 0}); message_text.animate({opacity: 1}, 250, function(){
$("#message_container").delay(delay).animate({opacity: 0, height: '0'}, 1000);
});
} }
} }
$(document).ready(function() { $(document).ready(function() {
<?php echo message::html(true, " ");?> <?php echo message::html(true, " "); ?>
//hide message bar on hover //hide message bar on hover
$("#message_text").mouseover(function() { $(this).hide(); $("#message_container").hide(); }); $(".message_text").mouseover(function() { $("#message_container").css({display:'none'}); });
<?php <?php
if (permission_exists("domain_select") && count($_SESSION['domains']) > 1) { if (permission_exists("domain_select") && count($_SESSION['domains']) > 1) {
@ -232,7 +235,7 @@
$("[id*=recording_button]").not("[id*=recording_button_"+recording_id+"]").html("<?php echo $v_link_label_play; ?>"); $("[id*=recording_button]").not("[id*=recording_button_"+recording_id+"]").html("<?php echo $v_link_label_play; ?>");
$("[id*=recording_progress_bar]").not("[id*=recording_progress_bar_"+recording_id+"]").css('display', 'none'); $("[id*=recording_progress_bar]").not("[id*=recording_progress_bar_"+recording_id+"]").css('display', 'none');
$('audio').each(function(){ $('audio').each(function(){
if ($(this).get(0) != recording_audio) { if ($(this).get(0) != recording_audio) {
$(this).get(0).pause(); // Stop playing $(this).get(0).pause(); // Stop playing