commit
c1ef8318d7
|
@ -7,6 +7,22 @@ use Icinga\Authentication\Manager as Auth;
|
|||
|
||||
if (Auth::getInstance()->isAuthenticated()): ?>
|
||||
<div id="header">
|
||||
<div class="skip-links">
|
||||
<nav>
|
||||
<h1 class="sr-only"><?= t('Accessibility Skip Links'); ?></h1>
|
||||
<ul>
|
||||
<li>
|
||||
<a tabindex="0" href="#main"><?= t('Skip to Content'); ?></a>
|
||||
</li>
|
||||
<li>
|
||||
<a tabindex="0" href="#search"><?= t('Skip to Search'); ?></a>
|
||||
</li>
|
||||
<li>
|
||||
<a tabindex="0" href="#navigation"><?= t('Skip to Navigation'); ?></a>
|
||||
</li>
|
||||
</ul>
|
||||
</nav>
|
||||
</div>
|
||||
<ul id="notifications"><?php
|
||||
|
||||
$moduleName = $this->layout()->moduleName;
|
||||
|
|
|
@ -5,9 +5,12 @@ use Icinga\Web\Widget\SearchDashboard;
|
|||
<? if (SearchDashboard::search('dummy')->getPane('search')->hasDashlets()): ?>
|
||||
<form action="<?= $this->href('search') ?>" method="get" role="search">
|
||||
<input
|
||||
type="text" name="q" class="search" placeholder="<?= $this->translate('Search...') ?>"
|
||||
type="text" name="q" id="search" class="search" placeholder="<?= $this->translate('Search...') ?>"
|
||||
autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"
|
||||
/>
|
||||
</form>
|
||||
<? endif; ?>
|
||||
<?= $menuRenderer; ?>
|
||||
<nav>
|
||||
<h1 id="navigation" class="sr-only"><?= t('Navigation'); ?></h1>
|
||||
<?= $menuRenderer; ?>
|
||||
</nav>
|
|
@ -0,0 +1,179 @@
|
|||
<!doctype html>
|
||||
<html class="no-js" lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<title>Accessibility: Skip Links</title>
|
||||
<meta name="description" content="Accessible skip links">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<style type="text/css">
|
||||
.sr-only {
|
||||
border: 0;
|
||||
clip: rect(0 0 0 0);
|
||||
height: 1px;
|
||||
margin: -1px;
|
||||
overflow: hidden;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
width: 1px;
|
||||
}
|
||||
.clearfix {
|
||||
*zoom: 1;
|
||||
}
|
||||
.clearfix:before,
|
||||
.clearfix:after {
|
||||
display: table;
|
||||
content: "";
|
||||
line-height: 0;
|
||||
}
|
||||
.clearfix:after {
|
||||
clear: both;
|
||||
}
|
||||
body {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.head {
|
||||
background-color: #049baf;
|
||||
padding: 5px;
|
||||
}
|
||||
.nav {
|
||||
width: 200px;
|
||||
float: left;
|
||||
margin: 0 20px 20px 0;
|
||||
padding: 0 20px 20px 0;
|
||||
}
|
||||
.container {
|
||||
margin: 10px 0 0 0;
|
||||
}
|
||||
.content {
|
||||
overflow: auto;
|
||||
}
|
||||
.skip-links {
|
||||
position: absolute;
|
||||
opacity: 1;
|
||||
}
|
||||
.skip-links-inline {
|
||||
margin-top: -3.5em;
|
||||
}
|
||||
.skip-links ul {
|
||||
list-style-type: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.skip-links ul li {
|
||||
display: inline;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.skip-links ul li a {
|
||||
position: absolute;
|
||||
display: block;
|
||||
left: -999em;
|
||||
width: 200px;
|
||||
padding: 0.6em;
|
||||
background-color: white;
|
||||
}
|
||||
.skip-links ul li a:focus {
|
||||
left: 0;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="head">
|
||||
<div class="skip-links">
|
||||
<nav>
|
||||
<h1 class="sr-only">Skip Links</h1>
|
||||
<ul>
|
||||
<li><a tabindex="0" href="#content">Skip to Content</a></li>
|
||||
<li><a tabindex="0" href="#searchField">Skip to Search</a></li>
|
||||
<li><a tabindex="0" href="#navigation">Skip to Navigation</a></li>
|
||||
</ul>
|
||||
</nav>
|
||||
</div>
|
||||
<div id="logo">
|
||||
<a href="skip-content.html">
|
||||
<img width="92" height="32" title="" alt="" src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAFwAAAAgCAYAAACfDx/iAAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAABcSAAAXEgFnn9JSAAAAB3RJTUUH3gkEDx0B5aU5bgAACCxJREFUaN7tmn2slmUdx7+/5+UcPFhAeQR0SSnOEodFWSPZdGxGZsWhiZFZq+myl5WZDWchIW4VODa3cDPNNWfFS9aquWmWyaJss1qDcE1txstKFPCEHA7ynPM8n/7gdx1/XN73cx7o0B9xru3e/dzX+/W9vtfv7Xqk40zAdOAhYAjYClzk+RpPY5iAKlAHnuS1ado4Qu1T5TjaVCVNlnRRyGv5e+E4pGMPOJKGJA1k35L0z3FIx16kmL9XZOJk07gMHz0l8GRmEVSZ2WvyA6BmZgD3SPqXpG1m9iBQM7PhcVjbM1aAAV3AJ4CzIpPbtFsInBO+a+MMHz3VnK4AWyW9RVIX0COpATRz5rvcr0s6VdJOoCqpaWbDRSclKFrzehSdnJNGabromCjpXElNz59tZs2c6WYmM2tJ6pU0aGZDZjayKUUget40STNi3kl7EtLCgZuBg8A6YFkmJq4A7gDuAj4GLE2b4SKpnXL9NHAAeAW4H6j5qRiX5cGx6QZuB3qBfwRLpAU0gQawIGunCD7Q5e9mZs3Mcn1x0gNdcSAqDtwZDlDD3feWP8P+BniXb1AVqGT9ngXM9XrD/gDMcU/15FSaQf62gIabfAI+GxSrZZ5mSg+bWW8A+UJJl3udbZK2SLpJ0hqv8pjnlZqhUcb/PypWK2B8zS2RJyS9s03bpgN7naTTJPVIetzMNsW4i5k1gV5Jp5nZ33IbHzAzo+z0FWyERUsnbky7TYonqmSzO5rHaP3HuRQZErWSTahJOrPjXTNbFQaueB+tZOlI2ivpYKrOkdXFDXmzpI9IOsdDBX+X9EMz2wPUzWwokcHNz14vGwE/OWNer0/SeyRNkPSSpMfM7Amg4ic53/Q0jzdKWixpppN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wDVJK0tUGqStNLvKaPHGNk3aGZzkrg5BrHCaCGG4AFW0mL/S7F1POnZ5EFmc5wkqd893qud2UkkbfL1NdzASBu11sMkVpN0acmA57rmHQgXEzGmQbBSjuUWxzpheHK39epfMP6XEVQzs/XADpf3v3E9MiEwviVpZSBQTdKbMkmB13sHcKGZbalIeqFk3AEfhDJQXMFSdtvThuFRCU52Nli24Cbwc9/Yy04Utg6MObl69OoFuST90cw2B+AkqeHs/lJ2YodcYadn2NvUvf/r03FZHRo0kw0q6admdiBn9xgt8t+Sdvr3TEkLHOBuVy74rdKHvf7qgtDwWKRBFx3mFkWfy+9uSV0O7LUOWpcTK/kGSx2riqRvSrrYpcUl/sxPIHu6EpiS7MnvZZ7khrG42Ciyw0P5feFSIwGcypZn87nZ8yeV2OHbgx0+MwaNgscY7fDvh7ars7FWhrY3ZDdWd4ZwQCuUWZEL717o1lBvcZzQNOB9wOn+Xc+jYccJeIylrA/lU4C9WRyjKOC0E3id95UAH8gA3xWCXeeVAP6V0Pf9WUBsVwfz2OOOUhV4IJTf4XOrlIQ4bg2k2pLszYqZ7TazR83sRf8eOkbZXJZeDL/3BhndL+ndOvL3uC4/ns0g1uru+MwzswNm1jKz/V4+MRtjl8tfuU6qHr1mqsEtl6TngjV0UNJcLy+bxz5J7zWzF1yR10Nf69ySa+UXG97/7UE/nXJC70oDy/qAG0vuUc1ZsD+ImJeBFQWBIgGTgW8DZ2dx8m8A8/KAWjaPJcDnC/IrIQj2kouApgekbovzCKJtOXB5UVy8YJ1vA+4Epv4HBqUeGKwVd68AAAAASUVORK5CYII=" />
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="container clearfix">
|
||||
<div class="nav">
|
||||
<h1 class="sr-only">Navigation</h1>
|
||||
|
||||
<div id="search">
|
||||
<h2 class="sr-only">Search</h2>
|
||||
<form>
|
||||
<fieldset>
|
||||
<label for="searchField">Search</label>
|
||||
<input type="text" name="searchField" id="searchField" />
|
||||
</fieldset>
|
||||
</form>
|
||||
</div>
|
||||
<nav>
|
||||
<h2 id="navigation" tabindex="0" class="sr-only">Site Links</h2>
|
||||
<ul>
|
||||
<li><a href="#">Link1</a></li>
|
||||
<li><a href="#">Link2</a></li>
|
||||
<li><a href="#">Link3</a></li>
|
||||
</ul>
|
||||
</nav>
|
||||
</div>
|
||||
<div class="content">
|
||||
<h1 tabindex="0" id="content">Content</h1>
|
||||
<div class="skip-links skip-links-inline">
|
||||
<nav>
|
||||
<ul>
|
||||
<li><a tabindex="0" href="#content2">Skip content</a></li>
|
||||
</ul>
|
||||
</nav>
|
||||
</div>
|
||||
<p>
|
||||
Organised prehistoric cultures began developing on Bulgarian lands
|
||||
during the Neolithic period. Its ancient history saw the presence
|
||||
of the Thracians and later the Greeks and Romans. The emergence of
|
||||
a unified Bulgarian state dates back to the establishment of the
|
||||
<a href="#">First Bulgarian Empire</a>
|
||||
in 681 CE, which dominated most of the
|
||||
Balkans and functioned as a cultural hub for Slavs during the
|
||||
Middle Ages.
|
||||
</p>
|
||||
<p>
|
||||
With the downfall of the Second Bulgarian Empire in 1396, its
|
||||
<a href="#">territories came under Ottoman</a>
|
||||
rule for nearly five centuries.
|
||||
The Russo-Turkish War (1877–78) led to the formation of the Third
|
||||
Bulgarian State. The following years saw several conflicts with its
|
||||
neighbours, which prompted Bulgaria to align with Germany in both
|
||||
world wars.
|
||||
</p>
|
||||
<p>
|
||||
In 1946 it became a single-party socialist state as part of the
|
||||
Soviet-led Eastern Bloc. In December 1989 the ruling Communist
|
||||
Party allowed multi-party elections, which subsequently led to
|
||||
Bulgaria's transition into a democracy and a market-based economy.
|
||||
</p>
|
||||
|
||||
<h1 tabindex="0" id="content2">Content2</h1>
|
||||
<p>
|
||||
The development of Final Fantasy VIII began in 1997, during the
|
||||
English localization process of Final Fantasy VII. It was produced
|
||||
<a href="#">by Shinji Hashimoto</a>,
|
||||
and directed by Yoshinori Kitase. The music
|
||||
was scored by regular series composer Nobuo Uematsu, and in a
|
||||
series first a vocal piece was written as the game's theme, "Eyes
|
||||
on Me", performed by Faye Wong.
|
||||
</p>
|
||||
<p>
|
||||
The game was positively received by
|
||||
critics,
|
||||
<a href="#">who praised the originality </a>
|
||||
and scope of the game. It was
|
||||
voted the 22nd-best game of all time in 2006 by readers of the
|
||||
Japanese magazine Famitsu. The game was a commercial success;
|
||||
thirteen weeks after its release,
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
|
@ -61,7 +61,7 @@ class MenuRenderer extends RecursiveIteratorIterator
|
|||
*/
|
||||
public function beginIteration()
|
||||
{
|
||||
$this->tags[] = '<ul role="navigation">';
|
||||
$this->tags[] = '<ul>';
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -1,5 +1,31 @@
|
|||
/*! Icinga Web 2 | (c) 2013-2015 Icinga Development Team | GPLv2+ */
|
||||
|
||||
/* Color definitions */
|
||||
@colorGray: #f9f9f9;
|
||||
@colorLinkDefault: #049baf;
|
||||
@colorTextDefault: #666;
|
||||
@colorTextDarkDefault: #555;
|
||||
@colorPetrol: #049baf;
|
||||
@colorOk: #44bb77;
|
||||
@colorWarning: #ffaa44;
|
||||
@colorWarningHandled: #ffcc66;
|
||||
@colorCritical: #ff5566;
|
||||
@colorCriticalHandled: #ff99aa;
|
||||
/*
|
||||
@colorUnknown: #dd66ff;
|
||||
@colorUnknownHandled: #ee99ff;
|
||||
@colorUnreachable: #dd66ff;
|
||||
@colorUnreachableHandled: #ee99ff;
|
||||
*/
|
||||
@colorUnknown: #aa44ff;
|
||||
@colorUnknownHandled: #cc77ff;
|
||||
@colorUnreachable: #aa44ff;
|
||||
@colorUnreachableHandled: #cc77ff;
|
||||
@colorPending: #77aaff;
|
||||
@colorInvalid: #999;
|
||||
|
||||
|
||||
|
||||
/*** Base rules ***/
|
||||
* {
|
||||
font-size: 100%;
|
||||
|
|
|
@ -39,26 +39,3 @@
|
|||
}
|
||||
}
|
||||
|
||||
@colorLinkDefault: #049baf;
|
||||
@colorTextDefault: #666;
|
||||
@colorTextDarkDefault: #555;
|
||||
@colorPetrol: #049baf;
|
||||
@colorOk: #44bb77;
|
||||
@colorWarning: #ffaa44;
|
||||
@colorWarningHandled: #ffcc66;
|
||||
@colorCritical: #ff5566;
|
||||
@colorCriticalHandled: #ff99aa;
|
||||
/*
|
||||
@colorUnknown: #dd66ff;
|
||||
@colorUnknownHandled: #ee99ff;
|
||||
@colorUnreachable: #dd66ff;
|
||||
@colorUnreachableHandled: #ee99ff;
|
||||
*/
|
||||
@colorUnknown: #aa44ff;
|
||||
@colorUnknownHandled: #cc77ff;
|
||||
@colorUnreachable: #aa44ff;
|
||||
@colorUnreachableHandled: #cc77ff;
|
||||
|
||||
@colorPending: #77aaff;
|
||||
@colorInvalid: #999;
|
||||
|
||||
|
|
|
@ -355,3 +355,18 @@ html {
|
|||
vertical-align: top;
|
||||
width: 2em;
|
||||
}
|
||||
|
||||
/*
|
||||
* Class to hide content from users but available for screen reader
|
||||
* @todo(mh): Replace .audible class
|
||||
*/
|
||||
.sr-only {
|
||||
border: 0;
|
||||
clip: rect(0 0 0 0);
|
||||
height: 1px;
|
||||
margin: -1px;
|
||||
overflow: hidden;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
width: 1px;
|
||||
}
|
||||
|
|
|
@ -27,55 +27,55 @@
|
|||
margin-left: 0.0em;
|
||||
}
|
||||
|
||||
#menu > ul > li > ul {
|
||||
#menu > nav > ul > li > ul {
|
||||
display: none;
|
||||
padding-left: 6px;
|
||||
}
|
||||
|
||||
.no-js #menu > ul > li > ul {
|
||||
.no-js #menu > nav > ul > li > ul {
|
||||
display: block;
|
||||
}
|
||||
|
||||
#menu > ul > li.active > ul {
|
||||
#menu > nav > ul > li.active > ul {
|
||||
display: block;
|
||||
}
|
||||
|
||||
#menu > ul > li.active {
|
||||
#menu > nav > ul > li.active {
|
||||
background-color: white;
|
||||
padding-left: 0.0em;
|
||||
margin-left: 0;
|
||||
margin-right: 0;
|
||||
}
|
||||
|
||||
#menu > ul > li > a {
|
||||
#menu > nav > ul > li > a {
|
||||
font-size: 0.9em;
|
||||
text-shadow: none;
|
||||
}
|
||||
|
||||
#menu > ul > li.active > a {
|
||||
#menu > nav > ul > li.active > a {
|
||||
color: @colorTextDefault;
|
||||
text-shadow: none;
|
||||
}
|
||||
|
||||
#menu > ul > li.active li.active a {
|
||||
#menu > nav > ul > li.active li.active a {
|
||||
color: @colorPetrol;
|
||||
}
|
||||
|
||||
#menu > ul > li.active li a:hover {
|
||||
#menu > nav > ul > li.active li a:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
#menu > ul > li {
|
||||
#menu > nav > ul > li {
|
||||
border-bottom: 1px solid #d9d9d9;
|
||||
}
|
||||
|
||||
#menu > ul > li li {
|
||||
#menu > nav > ul > li li {
|
||||
font-size: 0.8em;
|
||||
padding-left: 1.6em;
|
||||
}
|
||||
|
||||
/* Collapsed menu item color */
|
||||
#menu > ul > li > a {
|
||||
#menu > nav > ul > li > a {
|
||||
color: @colorTextDefault;
|
||||
}
|
||||
|
||||
|
@ -110,11 +110,11 @@
|
|||
padding-bottom: 1em;
|
||||
}
|
||||
|
||||
#menu > ul > li {
|
||||
#menu > nav > ul > li {
|
||||
margin-left: 5px;
|
||||
}
|
||||
|
||||
#menu > ul > li.active {
|
||||
#menu > nav > ul > li.active {
|
||||
-moz-box-shadow: none;
|
||||
-webkit-box-shadow: none;
|
||||
box-shadow: none;
|
||||
|
@ -262,8 +262,41 @@ a:focus {
|
|||
/* Displaying the outline in the navigation is not possible because of the messed up link borders,
|
||||
color those links instead. */
|
||||
#menu a:focus,
|
||||
#menu > ul > li > a:focus,
|
||||
#menu > nav > ul > li > a:focus,
|
||||
#menu .active ul li a:focus {
|
||||
color: #21b5ad;
|
||||
outline: none;
|
||||
}
|
||||
|
||||
/* Accessibility Skip Links */
|
||||
.skip-links {
|
||||
position: absolute;
|
||||
opacity: 1;
|
||||
ul {
|
||||
list-style-type: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
li {
|
||||
display: inline;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
a {
|
||||
position: absolute;
|
||||
display: block;
|
||||
left: -999em;
|
||||
width: 10.4em;
|
||||
top: 0.4em;
|
||||
padding: 0.8em;
|
||||
background-color: white;
|
||||
z-index: 4;
|
||||
border: 1px @colorGray solid;
|
||||
&:focus {
|
||||
left: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.skip-links-inline {
|
||||
margin-top: -3.5em;
|
||||
}
|
||||
|
|
|
@ -334,6 +334,17 @@
|
|||
return false;
|
||||
},
|
||||
|
||||
handleAnchor: function(query) {
|
||||
var element = $(query);
|
||||
if (element.length > 0) {
|
||||
// If we want to focus an element which has no tabindex
|
||||
// add one that we can focus is
|
||||
if (element.prop('tabindex') < 0) {
|
||||
element.prop('tabindex', 0);
|
||||
}
|
||||
element.focus();
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Someone clicked a link or tr[href]
|
||||
|
@ -383,7 +394,6 @@
|
|||
return;
|
||||
}
|
||||
|
||||
|
||||
// ignore multiselect table row clicks
|
||||
if ($a.is('tr') && $a.closest('table.multiselect').length > 0) {
|
||||
return;
|
||||
|
@ -393,6 +403,12 @@
|
|||
event.stopPropagation();
|
||||
event.preventDefault();
|
||||
|
||||
// This is an anchor only
|
||||
if (href.substr(0, 1) === '#' && href.substr(1, 1) !== '!') {
|
||||
self.handleAnchor(href);
|
||||
return;
|
||||
}
|
||||
|
||||
// If link has hash tag...
|
||||
if (href.match(/#/)) {
|
||||
if (href === '#') {
|
||||
|
|
Loading…
Reference in New Issue