aboutsummaryrefslogtreecommitdiff
path: root/basicConfig/webcontent
diff options
context:
space:
mode:
authorThomas Lenz <thomas.lenz@egiz.gv.at>2018-10-30 12:43:48 +0100
committerThomas Lenz <thomas.lenz@egiz.gv.at>2018-10-30 12:43:48 +0100
commitee157cd4417064e88414edd3c53912395164c74b (patch)
treee97261e6436a18f1bd0c96ac5275cf8ec315f49c /basicConfig/webcontent
parent051ba1644821e825a5b22055d0f32231f4ba6fa1 (diff)
downloadNational_eIDAS_Gateway-ee157cd4417064e88414edd3c53912395164c74b.tar.gz
National_eIDAS_Gateway-ee157cd4417064e88414edd3c53912395164c74b.tar.bz2
National_eIDAS_Gateway-ee157cd4417064e88414edd3c53912395164c74b.zip
add default configuration files1.0.0
Diffstat (limited to 'basicConfig/webcontent')
-rw-r--r--basicConfig/webcontent/css/css_country.css137
-rw-r--r--basicConfig/webcontent/js/js_country.js42
2 files changed, 179 insertions, 0 deletions
diff --git a/basicConfig/webcontent/css/css_country.css b/basicConfig/webcontent/css/css_country.css
new file mode 100644
index 00000000..4091955f
--- /dev/null
+++ b/basicConfig/webcontent/css/css_country.css
@@ -0,0 +1,137 @@
+@charset "utf-8";
+ body {
+ background-image: none;
+ margin: 0px;
+ font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
+ }
+ #page {
+ padding-top: 2%;
+ padding-left: 10%;
+ }
+
+ #country {
+ display: flex;
+ flex-direction: row;
+ flex-wrap: wrap;
+ align-items: center;
+ }
+
+ .block {
+ display: flex;
+ flex-direction: row;
+ flex-wrap: wrap;
+ cursor: pointer;
+ text-decoration: none;
+ padding-right:2%;
+ width: 250px;
+ }
+
+ .countryimage {
+ width:50px;
+ height:50px;
+ padding-right: 2%;
+ padding-bottom: 4%;
+ }
+
+ input[type=button], input[type=submit], input[type=reset] {
+ display:flex;
+ background-color:transparent;
+ border:none;
+ color: black;
+ text-decoration: none;
+ cursor: pointer;
+ }
+ #testEnvironment {
+ border: none;
+ color: black;
+ padding: 10px 20px;
+ text-decoration: none;
+ margin: 4px 2px;
+ height: 3%;
+ display: inline-block;
+ vertical-align: middle;
+ width: 40%;
+ }
+ #button{
+ background-color: transparent;
+ border:none;
+ }
+ div.header {
+ background-color: #e9ecef;
+ padding-top: 28px;
+ padding-left: 137px;
+ padding-right: 137px;
+ padding-bottom: 12px;
+ }
+ div.titlebar {
+ padding: 0px;
+ }
+ div.titlebar div {
+ }
+ .hidden {
+ display: none;
+ }
+ ul.nav_oben {
+ padding: 0px;
+ margin: 0px;
+ text-align: right;
+ text-transform: uppercase;
+ }
+ li {
+ display: inline-block;
+ }
+ div.header a {
+ text-decoration: none;
+ color: black;
+ }
+ a {
+ text-decoration: none;
+ color: #a22c1c;
+ }
+ .content {
+ padding-left: 137px;
+ padding-right: 137px;
+ }
+ div.subtitle h1 {
+ padding: 0px;
+ margin: 0px;
+ font-size: 130%;
+ align: right;
+ }
+ div.subtitle h2 {
+ padding: 0px;
+ margin: 0px;
+ font-size: 115%;
+ }
+ footer {
+ position: fixed;
+ left: 0;
+ padding-left: 137px;
+ padding-right: 137px;
+ padding-top: 1em;
+ bottom: 0;
+ width: 100%;
+ height: 2em;
+ background-color: rgb(162,44,28);
+ color: white;
+ }
+ .float {
+ float: left;
+ }
+ .floatright {
+ float: right;
+ }
+ .copyright {
+ width: 66%;
+ font-size: 80%;
+ }
+ #countries,#country {
+ padding-bottom: 40px;
+ }
+ input[type=submit] {
+ width: inherit;
+ /* text-align: left; */
+ }
+ form {
+ justify-content: center;
+ } \ No newline at end of file
diff --git a/basicConfig/webcontent/js/js_country.js b/basicConfig/webcontent/js/js_country.js
new file mode 100644
index 00000000..5dcea90e
--- /dev/null
+++ b/basicConfig/webcontent/js/js_country.js
@@ -0,0 +1,42 @@
+function clickCountryFlag(element) {
+ if (!element) return false;
+
+ var form = element.target.closest("form");
+
+ if (!form) return false;
+
+ form.submit();
+ return false;
+}
+
+
+/* Set JS events by EventListener to prevent problems with CSP*/
+document.addEventListener("DOMContentLoaded", function(event) {
+
+ /* Element.closest polyfill - https://developer.mozilla.org/en-US/docs/Web/API/Element/closest License: public domain*/
+ if (!Element.prototype.matches)
+ Element.prototype.matches = Element.prototype.msMatchesSelector ||
+ Element.prototype.webkitMatchesSelector;
+
+ if (!Element.prototype.closest)
+ Element.prototype.closest = function(s) {
+ var el = this;
+ if (!document.documentElement.contains(el)) return null;
+ do {
+ if (el.matches(s)) return el;
+ el = el.parentElement || el.parentNode;
+ } while (el !== null && el.nodeType === 1);
+ return null;
+ };
+
+ /* set Click events by EventListener to prevent JavaScript in HTML which can be a problem with CSP*/
+ var allFlags = document.getElementsByClassName("countryimage");
+ for (i=0;i<allFlags.length;i++) {
+ if(allFlags[i].getAttribute("disabled") == null) {
+ allFlags[i].closest("a").addEventListener('click', clickCountryFlag, false);
+ }
+ }
+});
+
+
+