From a5a5a276ab60d000fe259858585dc5b71eb372d2 Mon Sep 17 00:00:00 2001 From: Timotej Lazar Date: Thu, 31 Mar 2016 16:56:19 +0200 Subject: Replace window.alert with custom message box --- css/codeq.css | 22 ++++++++++++++++++++++ index.html | 6 ++++++ js/codeq/core.js | 10 ++++++++++ js/codeq/prolog.js | 6 +++--- js/codeq/python.js | 6 +++--- 5 files changed, 44 insertions(+), 6 deletions(-) diff --git a/css/codeq.css b/css/codeq.css index 28870c9..56a086b 100644 --- a/css/codeq.css +++ b/css/codeq.css @@ -106,6 +106,28 @@ button.navbar-toggle > span.glyphicon { margin: 0; } +/* system message */ +div#message { + position: fixed; + bottom: 0; + left: 0; + right: 0; + padding: 0.25em 0.5em; + z-index: 999; +} +div#message.error { + background-color: #ffbfbf; + border-top: 1px solid #ff4040; +} +div#message > span.close { + font-weight: normal; + opacity: 0.5; + text-shadow: none; +} +div#message > span.close:hover { + opacity: 0.75; +} + /* misc */ form { margin-bottom: 0; diff --git a/index.html b/index.html index 8e4eec1..d3bd219 100644 --- a/index.html +++ b/index.html @@ -53,6 +53,12 @@ + + +