Merge branch 'spis-master' into 'master'

spis-master: SPR-908, SPR-814, SPR-882, SPR-926, SPR-930

See merge request !38
This commit is contained in:
Jana Deutschländer 2017-04-20 12:54:36 +02:00
commit 2eaf821dd2
15 changed files with 279 additions and 77 deletions

View file

@ -25,8 +25,19 @@
border-bottom: 1px solid @ini_border_light;
}
.msg-area + * {
clear: both;
padding-top: 1em; // as h1
}
#plugin__highlightparent {
clear: none;
display: block;
+ * {
clear: both;
padding-top: 1em; // as h1
}
}
}
}

View file

@ -78,7 +78,8 @@
&.showSidebar {
#dokuwiki__footer {
.col-xs-12 {
margin-left: @toggle-showsidebar_width;
width: 100%;
padding-left: @toggle-showsidebar_width;
}
}
}

View file

@ -51,11 +51,11 @@
@formfield_min-height: 2rem; // min-height for input, textarea, select, keygen
//@metanav-ini_background: rgba(0, 0, 0, .1);
@code-background: #F6F6F6; /* code, pre, samp, kbd */
/* icons */
@noopentasks-background: #ECECEC; /* metabox tabs + num in icons + tabinclude + code, pre, samp, kbd */
@noopentasks-background: #ECECEC; /* metabox tabs + num in icons + tabinclude */
@noopentasks-border: #BBB; /* metabox tabs + num in icons + code, pre, samp, kbd */
@noopentasks-color: #666; /* metabox tabs + num in icons + code, pre, samp, kbd */
@wikiicons-border: #CCC; /* usertools, breadcrumbs icons, pagetools box-hover */

View file

@ -155,6 +155,7 @@ h2 {
padding-top: (@font-size-head2 / 2);
.secedit + &,
div[class^="level"] + &,
.section_highlight &:first-child {
padding-top: 0;
}
@ -170,6 +171,7 @@ h3 {
padding-top: (@font-size-head3 / 2);
.secedit + &,
div[class^="level"] + &,
.section_highlight &:first-child {
padding-top: 0;
}
@ -185,6 +187,7 @@ h4 {
padding-top: (@font-size-head4 / 2);
.secedit + &,
div[class^="level"] + &,
.section_highlight &:first-child {
padding-top: 0;
}
@ -200,6 +203,7 @@ h5 {
padding-top: (@font-size-head5 / 2);
.secedit + &,
div[class^="level"] + &,
.section_highlight &:first-child {
padding-top: 0;
}
@ -216,6 +220,7 @@ h6 {
padding-top: (@font-size-head6 / 2);
.secedit + &,
div[class^="level"] + &,
.section_highlight &:first-child {
padding-top: 0;
}
@ -227,7 +232,7 @@ h6 {
p {
font-size: @font-size-default;
line-height: 135%;
line-height: @line-height-big;
a,
span,
@ -286,6 +291,55 @@ small,
.code {
margin-top: @grid;
// SPR-926: darker colors for accessibility
.es6 {
color: #00832B;
}
.kw5 {
color: #005D00;
}
.kw6 {
color: #DC0075;
}
.nu0 {
color: #A74DA7;
}
.re3 {
color: #DE1B1B;
}
.re4 {
color: #007F6F;
}
.br0, .sy0 {
color: #248124;
}
.co1, .coMULTI, .sc-1 {
color: #707070;
}
.co2, .sy1 {
color: #108400;
}
.co3, .sy4 {
color: #008070;
}
.kw1, .kw8 {
color: #747400;
}
.re1, .st0, .st_h {
color: #DD0000;
}
}
@ -319,6 +373,11 @@ dl {
line-height: 140%;
}
dt,
dd {
line-height: inherit;
}
dt {
font-weight: bold;
margin: 0;
@ -494,21 +553,41 @@ kbd {
font-size: @font-size-default;
direction: ltr;
text-align: left;
background-color: @noopentasks-background;
background-color: @code-background;
color: @noopentasks-color;
box-shadow: inset 0 0 .3em @noopentasks-border;
border-radius: @fix_border-radius;
padding-left: @small-spacing;
padding-right: @small-spacing;
* {
font-family: inherit;
font-size: inherit;
}
span {
color: inherit;
}
a {
&:link,
&:visited {
color: inherit;
text-decoration: underline;
}
&:hover,
&:focus,
&:active {
text-decoration: none;
}
}
}
pre {
overflow: auto;
word-wrap: normal;
background-color: @noopentasks-background;
border: 1px solid @noopentasks-border;
border-radius: @fix_border-radius;
box-shadow: inset 0 0 .5em @noopentasks-border;
font-size: @font-size-default;
line-height: 140%;
padding: .7em 1em;

View file

@ -282,6 +282,12 @@
-webkit-flex: @elem;
}
.flex-wrap() {
flex-wrap: wrap;
-webkit-flex-wrap: wrap;
-ms-flex-wrap: wrap;
}
/* + + + + + + + + + + + + + + + + + + + + + + + + + + */
/* positioning */

View file

@ -9,6 +9,7 @@
#dokuwiki__content {
div.section_highlight {
clear: right;
padding-top: 0 !important; // heredity
}
.secedit button {
@ -34,7 +35,6 @@
}
}
}
}

View file

@ -4,17 +4,34 @@
*
* @author Jana Deutschlaender <deutschlaender@cosmocode.de>
*/
#dokuwiki__detail {
// linked image
.img-link{
/* + + + + + linked image + + + + + */
.img-link {
text-align: center;
a {
display: inline-block;
margin: 0 auto 1.4em;
position: relative;
left: 0;
display: inline-block;
max-width: 100%;
color: @ini_button_color;
margin: 0 auto 1.4em;
&::before {
position: absolute;
top: 0;
left: 0;
z-index: 2;
display: block;
width: 100%;
box-sizing: border-box;
background: @ini_button_background;
line-height: @line-height-default;
padding: @margin-small;
}
img {
margin: 0;
@ -27,37 +44,36 @@
&:hover,
&:focus,
&:active {
&:before{
position: absolute;
top: 0;
left: 0;
width: 100%;
box-sizing: border-box;
display: block;
padding: @margin-small;
text-decoration: none;
z-index:2;
background: @ini_button_background;
color: @ini_button_color;
content:attr(title);
&::before {
content: attr(title);
}
img {
border: 1px solid @ini_button_background;
}
}
}
}
// meta data
div.img_detail {
/* vertical minus margin of .img-detail corresponds to the padding of .page */
margin: @margin-default -(@margin-default);
/* + + + + + meta data + + + + + */
div.img_detail {
/* vertical minus margin of .img-detail corresponds to the padding of .page */
background-color: @ini_background_page_header;
border: solid @ini_border_light;
border-width: 1px 0;
background-color: @ini_background_page_header;
h1, h2, h3, h4, h5, h6, p{
margin: @margin-default -(@margin-default);
h1,
h2,
h3,
h4,
h5,
h6,
p {
padding-left: @margin-default;
padding-right: @margin-default;
}
@ -67,64 +83,83 @@
}
dl {
display: flex;
display: -webkit-flex;
display: -ms-flexbox;
flex-direction: row;
-webkit-flex-direction: row;
-ms-flex-direction: row;
flex-wrap: wrap;
-webkit-flex-wrap: wrap;
-ms-flex-wrap: wrap;
.display-flex();
.flex-wrap();
width: 100%;
dt, dd {
dt,
dd {
box-sizing: border-box;
margin: .2em 0;
padding: (@small-spacing * 2) @small-spacing;
}
dt {
width: 33.3%;
background-color: @ini_highlight;
color: @ini_highlight_text;
}
dd {
width: 66.6%;
padding-left: (@small-spacing * 2);
@media @screen_min-xs {
width: 33.3%;
}
@media @screen_max-xs {
width: 40%;
}
}
dd {
padding-left: (@small-spacing * 2);
@media @screen_min-xs {
width: 66.6%;
}
@media @screen_max-xs {
width: 59.9%;
}
}
}
.os-map {
p {
text-align: right;
}
iframe {
padding: 0;
margin: 0;
border: solid @ini_button_background;
border-width: 1px 0;
margin: 0;
padding: 0;
}
}
@media @screen_max-md {
margin-right: -(@margin-default * 1.6);
h1, h2, h3, h4, h5, h6, p {
h1,
h2,
h3,
h4,
h5,
h6,
p {
padding-right: (@margin-default * 1.6);
}
}
@media @screen_max-xs {
margin-left: -(@margin-small);
h1, h2, h3, h4, h5, h6, p {
h1,
h2,
h3,
h4,
h5,
h6,
p {
padding-left: @margin-small;
}
}
}
}

View file

@ -14,14 +14,20 @@ if (!defined('DOKU_INC')) die(); /* must be run from with
header('X-UA-Compatible: IE=edge,chrome=1');
global $JSINFO;
if (empty($JSINFO)) {
$JSINFO = array();
if (empty($JSINFO['template'])) {
$JSINFO['template'] = array();
}
$JSINFO['template']['sprintdoc'] = array('sidebar_toggle_elements' => tpl_getConf('sidebar_sections'));
$showTools = true;
$showSidebar = true;
?>
<html class="edge no-js" lang="<?php echo $conf['lang'] ?>" dir="<?php echo $lang['direction'] ?>">
<head>
<?php
/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
/* meta and link relations */
/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
@ -223,7 +229,7 @@ include('tpl/favicon_tiles.php');
<div class="container">
<div class="row">
<div class="col-xs-12">
<div class="breadcrumbs" data-do="<?php echo $ACT ?>">
<div class="breadcrumbs" data-do="<?php echo tpl_getLang('image_detail') ?>">
<div class="togglelink page_main-content">
<a href="#"><span class="sr-out"><?php echo tpl_getLang('a11y_sidebartoggle') ?></span></a>
@ -247,7 +253,8 @@ include('tpl/favicon_tiles.php');
/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
/* page tools */
/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */ ?>
/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
?>
<nav id="dokuwiki__pagetools">
<div class="tools">
<ul>
@ -307,8 +314,6 @@ include('tpl/favicon_tiles.php');
tpl_img_meta();
/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
/* open street maps if geo data is available */
/** @var helper_plugin_spatialhelper_index $spatial */

View file

@ -1,18 +1,30 @@
/**
* Sets up the breadcrumb behaviour (adds do / ACT status information)
* or adds tpl_getLang('image_detail') on detail template
*/
jQuery(function () {
var $breadcrumb = jQuery('.breadcrumbs');
if (!$breadcrumb.length) return;
(function($) {
/**
* add ACT status to breadcrumb (if not show)
*
*/
var mode = $breadcrumb.attr('data-do');
if(mode && mode.indexOf('show') !== 0){
var markup = '<bdi lang="en"><span class="curid"> : <strong>' + mode + '</strong></span></bdi>';
$breadcrumb.find('p').append(markup);
}
});
var setBreadcrumbSuffix = function(){
var $breadcrumb = $('.breadcrumbs');
if (!$breadcrumb.length) return;
/**
* add ACT status to breadcrumb (if not show)
* or tpl_getLang('image_detail') on detail.php
*/
var mode = $breadcrumb.attr('data-do');
if(mode && mode.indexOf('show') !== 0){
var markup = '<bdi lang="en"><span class="curid"> : <strong>' + mode + '</strong></span></bdi>';
$breadcrumb.find('p').append(markup);
}
};
$(function(){
setBreadcrumbSuffix();
});
})(jQuery);

24
js/plugins/bookcreator.js Normal file
View file

@ -0,0 +1,24 @@
/**
* prevents Uncaught TypeError in detail template if bookcreator plug-in is installed
*
*/
(function($) {
var debugBookCreatorOnDetailTemplate = function(){
var $detail = $('#dokuwiki__detail');
if (!$detail.length) return;
if(JSINFO.bookcreator === undefined) {
JSINFO.bookcreator = {};
JSINFO.bookcreator.areToolsVisible = false;
}
};
$(function(){
debugBookCreatorOnDetailTemplate();
});
})(jQuery);

25
js/plugins/folded.js Normal file
View file

@ -0,0 +1,25 @@
/**
* prevents Uncaught TypeError in detail template if folded plug-in is installed
*
*/
(function($) {
var debugFoldedOnDetailTemplate = function(){
var $detail = $('#dokuwiki__detail');
if (!$detail.length) return;
if(JSINFO.plugin_folded === undefined) {
JSINFO.plugin_folded = {};
JSINFO.plugin_folded.reveal = '';
JSINFO.plugin_folded.hide = '';
}
};
$(function(){
debugFoldedOnDetailTemplate();
});
})(jQuery);

View file

@ -46,6 +46,7 @@ $lang['userpage'] = 'Benutzer-Seite';
$lang['meta_data'] = 'Meta Daten des Bildes';
$lang['osm_zoom_link_text'] = 'größere Karte anzeigen';
$lang['osm_zoom_link_title'] = 'externer Link - öffnet in neuem Fenster';
$lang['image_detail'] = 'Detailinformationen zum Bild';
/**

View file

@ -47,6 +47,8 @@ $lang['userpage'] = 'User page';
$lang['meta_data'] = 'Meta Data';
$lang['osm_zoom_link_text'] = 'view larger map';
$lang['osm_zoom_link_title'] = 'external link opens new window';
$lang['image_detail'] = 'image details';
/**

View file

@ -21,7 +21,7 @@ if (empty($JSINFO['template'])) {
$JSINFO['template']['sprintdoc'] = array('sidebar_toggle_elements' => tpl_getConf('sidebar_sections'));
$showTools = true;
$showSidebar = true; /* */
$showSidebar = true;
?>
<html class="edge no-js" lang="<?php echo $conf['lang'] ?>" dir="<?php echo $lang['direction'] ?>">
<head>

View file

@ -3,8 +3,9 @@
/* DOKUWIKI:include js/plugins/do_tasks.js */
/* DOKUWIKI:include js/plugins/qc.js */
/* DOKUWIKI:include js/plugins/bookcreator.js */
/* DOKUWIKI:include js/plugins/folded.js */
/* DOKUWIKI:include js/meta-box.js */
/* DOKUWIKI:include js/sidebar.js */
/* DOKUWIKI:include js/breadcrumb.js */