fixed id-selectors that get translated to fix non-english view, added mediamanager layout, fixed backlink view, added recent view

This commit is contained in:
Ruediger Marwein 2021-07-26 20:37:15 +02:00
parent ae1d414dae
commit fa2b283556
5 changed files with 91 additions and 81 deletions

@ -522,16 +522,19 @@ Resend password
padding-left:20px;
}
.act-recent #dw__recent ul,
.act-revisions #page__revisions ul {
list-style-type: none;
padding:0;
width:100%;
}
.act-recent #dw__recent ul li,
.act-revisions #page__revisions ul li {
padding:5px;
border: 1px solid #000;
border-width: 0px 0px 1px 0px;
}
.act-recent #dw__recent ul .li,
.act-revisions #page__revisions ul .li {
width:100%;
display:flex;
@ -539,47 +542,53 @@ Resend password
.act-revisions #page__revisions .li > input[type=checkbox] {
width: 3%;
}
.act-recent #dw__recent.li > .date,
.act-revisions #page__revisions .li > .date {
width: 20%;
}
.act-recent #dw__recent .li > *,
.act-revisions #page__revisions .li > * {
display: inline-block;
}
.act-recent #dw__recent .li > .diff_link,
.act-revisions #page__revisions .li > img,
.act-revisions #page__revisions .li > .diff_link {
text-align: center;
width: 3%;
}
.act-recent #dw__recent .li > a.wikilink1,
.act-revisions #page__revisions .li > a.wikilink1 {
width: 10%;
}
.act-recent #dw__recent > .sum,
.act-revisions #page__revisions .li > .sum {
flex: 1;
}
.act-recent #dw__recent > .user,
.act-revisions #page__revisions .li > .user {
text-align: right;
flex: 1;
}
.act-recent #dw__recent .li > .user + .act-recent #dw__recent .li > .sum,
.act-revisions #page__revisions .li > .user + .act-revisions #page__revisions .li > .sum {
width: 10%;
}
.act-recent #dw__recent .li > .sizechange,
.act-revisions #page__revisions .li > .sizechange {
width: 15%;
text-align: right;;
text-align: right;
}
/*
.act-revisions #page__revisions ul {
display: table;
.act-recent #dw__recent ul {
list-style-type: none;
padding: 0;
margin: 0;
}
.act-recent #dw__recent ul .li > * {
padding: 0 10px;
}
.act-revisions #page__revisions ul li {
display: table-row;
}
.act-revisions #page__revisions ul li .li > * {
display: table-cell;
}
*/
.act-diff .diffnav {
}
.act-diff .diffnav > * {
@ -649,41 +658,12 @@ Resend password
/**
Media Manager
**/
.act-media #media__tree ul {
padding: 0;
position:relative;
border-top: 1px solid gray;
.act-media .container-fluid {
max-width: 1920px;
}
.act-media #media__tree > ul {
}
.act-media #media__tree li > img {
float: left;
margin-top: 10px;
}
.act-media #media__tree li .li {
height: 2em;
padding-left: 20px;
padding-top: 5px;
}
.act-media #media__tree > ul ul {
left: 1em;
}
.act-media .thumbs {
list-style-type: none;
padding: 0;
display: flex;
flex-wrap: wrap;
align-content: stretch;
}
.act-media .thumbs li {
.act-media #mediamanager__page .filelist .thumbs li {
border: 1px solid black;
width: 30%;
float:left;
margin: 3px;
padding: 10px;
text-align: center;
}
.act-media .tabs {
border-radius: 5px;
}

@ -1,4 +1,7 @@
jQuery(function($) {
var mediaMgrInterval = null;
/**
* Edit form
*/
@ -47,10 +50,10 @@ jQuery(function($) {
* Login Form
*/
(function() {
$loginHeadline = $('#login');
if(!$loginHeadline.length) return;
$loginForm = $('#dw__login');
if(!$loginForm.length) return;
$loginContainer = $loginHeadline.parent();
$loginContainer = $loginForm.parent().parent();
$loginContainer.find('.level1').addClass('alert alert-warning');
$loginContainer.find('form').addClass('form-horizontal');
$loginContainer.find('input[name=u], input[name=p]').addClass('form-control');
@ -66,10 +69,10 @@ jQuery(function($) {
* Profile
*/
(function() {
$profileHeadline = $('#update_your_account_profile');
if(!$profileHeadline.length) return;
$profileContainer = $profileHeadline.parent();
$registerContainer = $profileContainer.find('#dw__register');
var $profileForm = $('#dw__register');
if(!$profileForm.length) return;
$profileContainer = $profileForm.parent().parent();
$registerContainer = $profileForm;
$registerContainer.find('input[type=text], input[type=password], input[type=email]').addClass('form-control');
$registerContainer.find('button[type=submit]').addClass('btn btn-primary');
//$('#dw__register').addClass('panel');
@ -166,8 +169,13 @@ jQuery(function($) {
potentialCurrent.addClass('bg-success');
}
})();
/* Show recent */
(function() {
$revisions = $('#dw__recent');
if(!$revisions.length) return;
})();
/* Diff revisions */
(function() {
$diff = $('#differences');
@ -194,28 +202,46 @@ jQuery(function($) {
})();
(function() {
$resendpwHeadline = $('#send_new_password');
if(!$resendpwHeadline.length) return;
$resendpw = $resendpwHeadline.parent();
$resendpwForm = $('#dw__resendpwd');
if(!$resendpwForm.length) return;
$resendpw = $resendpwForm.parent().parent();
$resendpw.find('.centeralign').removeClass('centeralign').addClass('panel alert alert-info');
$resendpw.find('form input[name=login]').addClass('form-control');
$resendpw.find('button').addClass('btn btn-primary');
})();
(function() {
$mediamanager = $('#mediamanager__page');
var $mediamanager = $('#mediamanager__page');
if(!$mediamanager.length) return;
$mediamanager.addClass('row');
$mediamanager.find('.panel.namespaces').addClass('col-md-3');
$mediamanager.find('.panel.filelist').removeClass('ui-resizable').addClass('col-md-6');
$mediamanager.find('.panel.file').addClass('col-md-3');
// resizable does mess with the grid
//dw_mediamanager.$resizables().resizable('destroy');
//$mediamanager.find('.tabs').addClass('btn-group');
//$mediamanager.find('.tabs li').addClass('btn btn-default');
// stuff inside ".thumbs" and ".rows" changes dynamically
// Couldn't find another way than to overload this function to fix the panel resize width issue.
// Copied from dokuwiki's media.js
// changed 99.9% to 99% to avoid flow into second row.
dw_mediamanager.update_resizable = function() {
var $resizables = dw_mediamanager.$resizables();
$resizables.resizable({
handles: (jQuery('html[dir=rtl]').length ? 'w' : 'e'),
resize: function (event, ui) {
var $page = $mediamanager;
var widthFull = $page.width();
var widthResizables = 0;
$resizables.each(function () {
widthResizables += jQuery(this).width();
});
var $filePanel = $page.find('div.panel.file');
// set max width of resizable column
var widthOtherResizable = widthResizables - jQuery(this).width();
var minWidthNonResizable = parseFloat($filePanel.css("min-width"));
var maxWidth = widthFull - (widthOtherResizable + minWidthNonResizable) - 1;
$resizables.resizable("option", "maxWidth", maxWidth);
// was: 99.9%
var relWidthNonResizable = 99 - (100 * widthResizables / widthFull);
$filePanel.width(relWidthNonResizable + '%');
dw_mediamanager.resize();
dw_mediamanager.opacity_slider();
dw_mediamanager.portions_slider();
}
});
dw_mediamanager.resize();
};
})();
});

@ -1,5 +1,10 @@
...
2021-07-26
Fixed id selectors that get translated to unilingual ones in the same module to fix ACT=login,register,resendpw
Fixed ACT=backlink view
Added ACT=mediamanager,recent
2021-07-18
Visually adjusted the areas of ACT=['show', 'profile', 'login', 'revisions', 'admin', 'diff', 'edit', 'preview', 'source']
Visually adjusted ACT=admin's stat page, config manager, user manager, revisions & differences, draft, resendpwd

@ -56,7 +56,7 @@ $loggedIn = $INPUT->server->str('REMOTE_USER');
<?php echo $editForm ?>
</div>
<?php endif ?>
<?php if(in_array($ACT, ['login', 'profile', 'revisions', 'admin', 'diff', 'draft', 'resendpwd', 'register', 'subscribe', 'index', 'backink', 'source'])): ?>
<?php if(in_array($ACT, ['login', 'profile', 'revisions', 'recent', 'admin', 'diff', 'draft', 'resendpwd', 'register', 'subscribe', 'index', 'backlink', 'source'])): ?>
<div class="container">
<?php tpl_link(wl($ID), "Back", 'class="btn btn-default"'); ?>
<?php echo $content ?>
@ -72,7 +72,7 @@ $loggedIn = $INPUT->server->str('REMOTE_USER');
</article>
<?php endif ?>
<?php if(in_array($ACT, ['show', 'profile', 'admin', 'revisions', 'diff', 'draft', 'resendpwd'])): ?>
<?php if(!in_array($ACT, ['edit'])): ?>
<aside id="dokuwiki__pagetools">
<div class="container">
<h3 class="a11y"><?php echo $lang['page_tools']; ?></h3>

@ -15,15 +15,14 @@
; included through LESS' @import statements are not
[stylesheets]
assets/bootstrap.min.css = screen
assets/bootstrap-theme.min.css = screen
;../bootstrap3/assets/bootstrap/paper/bootstrap.min.css = screen
;../bootstrap3/assets/bootstrap/cerulean/bootstrap.min.css = screen
;assets/ekko-lightbox.css = screen
assets/landing.css = screen
assets/offcanvas.css = screen
;../bootstrap3/css/core/_edit.css = screen
../dokuwiki/css/_diff.css = screen
assets/bootstrap.min.css = screen
assets/bootstrap-theme.min.css = screen
../dokuwiki/css/_tabs.css = screen
../dokuwiki/css/_media_fullscreen.css = screen
../dokuwiki/css/_media_popup.css = screen
../dokuwiki/css/_diff.css = screen
assets/landing.css = screen
assets/offcanvas.css = screen
; This section is used to configure some placeholder values used in
; the stylesheets. Changing this file is the simplest method to