mirror of
https://github.com/wekan/wekan.git
synced 2025-04-25 06:27:10 -04:00
swimlane-view: have the swimlane header horizontal
This allows to use the header as a separator between swimlanes. This will be most useful when we can set the background color of these headers.
This commit is contained in:
parent
5fa0821e07
commit
dd88eb4cc1
5 changed files with 33 additions and 61 deletions
|
@ -23,6 +23,8 @@ template(name="boardBody")
|
||||||
if isViewSwimlanes
|
if isViewSwimlanes
|
||||||
each currentBoard.swimlanes
|
each currentBoard.swimlanes
|
||||||
+swimlane(this)
|
+swimlane(this)
|
||||||
|
if currentUser.isBoardMember
|
||||||
|
+addSwimlaneForm
|
||||||
if isViewLists
|
if isViewLists
|
||||||
+listsGroup
|
+listsGroup
|
||||||
if isViewCalendar
|
if isViewCalendar
|
||||||
|
|
|
@ -10,7 +10,6 @@
|
||||||
// transparent, because that won't work during a list drag.
|
// transparent, because that won't work during a list drag.
|
||||||
background: darken(white, 13%)
|
background: darken(white, 13%)
|
||||||
border-left: 1px solid darken(white, 20%)
|
border-left: 1px solid darken(white, 20%)
|
||||||
border-bottom: 1px solid #CCC
|
|
||||||
padding: 0
|
padding: 0
|
||||||
float: left
|
float: left
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
template(name="swimlane")
|
template(name="swimlane")
|
||||||
.swimlane.js-lists.js-swimlane
|
.swimlane.js-lists.js-swimlane
|
||||||
+swimlaneHeader
|
+swimlaneHeader
|
||||||
|
.swimlane.list-group.js-lists
|
||||||
if isMiniScreen
|
if isMiniScreen
|
||||||
if currentList
|
if currentList
|
||||||
+list(currentList)
|
+list(currentList)
|
||||||
|
@ -15,7 +16,7 @@ template(name="swimlane")
|
||||||
if currentCardIsInThisList _id ../_id
|
if currentCardIsInThisList _id ../_id
|
||||||
+cardDetails(currentCard)
|
+cardDetails(currentCard)
|
||||||
if currentUser.isBoardMember
|
if currentUser.isBoardMember
|
||||||
+addListAndSwimlaneForm
|
+addListForm
|
||||||
|
|
||||||
template(name="listsGroup")
|
template(name="listsGroup")
|
||||||
.swimlane.list-group.js-lists
|
.swimlane.list-group.js-lists
|
||||||
|
@ -35,19 +36,8 @@ template(name="listsGroup")
|
||||||
if currentUser.isBoardMember
|
if currentUser.isBoardMember
|
||||||
+addListForm
|
+addListForm
|
||||||
|
|
||||||
template(name="addListAndSwimlaneForm")
|
template(name="addSwimlaneForm")
|
||||||
.list.list-composer.js-list-composer
|
.list.list-composer.js-list-composer
|
||||||
.list-header
|
|
||||||
+inlinedForm(autoclose=false)
|
|
||||||
input.list-name-input.full-line(type="text" placeholder="{{_ 'add-list'}}"
|
|
||||||
autocomplete="off" autofocus)
|
|
||||||
.edit-controls.clearfix
|
|
||||||
button.primary.confirm(type="submit") {{_ 'save'}}
|
|
||||||
a.fa.fa-times-thin.js-close-inlined-form
|
|
||||||
else
|
|
||||||
a.open-list-composer.js-open-inlined-form
|
|
||||||
i.fa.fa-plus
|
|
||||||
| {{_ 'add-list'}}
|
|
||||||
.list-header
|
.list-header
|
||||||
+inlinedForm(autoclose=false)
|
+inlinedForm(autoclose=false)
|
||||||
input.swimlane-name-input.full-line(type="text" placeholder="{{_ 'add-swimlane'}}"
|
input.swimlane-name-input.full-line(type="text" placeholder="{{_ 'add-swimlane'}}"
|
||||||
|
|
|
@ -185,21 +185,7 @@ BlazeComponent.extendComponent({
|
||||||
return [{
|
return [{
|
||||||
submit(evt) {
|
submit(evt) {
|
||||||
evt.preventDefault();
|
evt.preventDefault();
|
||||||
let titleInput = this.find('.list-name-input');
|
let titleInput = this.find('.swimlane-name-input');
|
||||||
if (titleInput) {
|
|
||||||
const title = titleInput.value.trim();
|
|
||||||
if (title) {
|
|
||||||
Lists.insert({
|
|
||||||
title,
|
|
||||||
boardId: Session.get('currentBoard'),
|
|
||||||
sort: $('.list').length,
|
|
||||||
});
|
|
||||||
|
|
||||||
titleInput.value = '';
|
|
||||||
titleInput.focus();
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
titleInput = this.find('.swimlane-name-input');
|
|
||||||
const title = titleInput.value.trim();
|
const title = titleInput.value.trim();
|
||||||
if (title) {
|
if (title) {
|
||||||
Swimlanes.insert({
|
Swimlanes.insert({
|
||||||
|
@ -211,11 +197,10 @@ BlazeComponent.extendComponent({
|
||||||
titleInput.value = '';
|
titleInput.value = '';
|
||||||
titleInput.focus();
|
titleInput.focus();
|
||||||
}
|
}
|
||||||
}
|
|
||||||
},
|
},
|
||||||
}];
|
}];
|
||||||
},
|
},
|
||||||
}).register('addListAndSwimlaneForm');
|
}).register('addSwimlaneForm');
|
||||||
|
|
||||||
Template.swimlane.helpers({
|
Template.swimlane.helpers({
|
||||||
canSeeAddList() {
|
canSeeAddList() {
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
// transparent, because that won't work during a swimlane drag.
|
// transparent, because that won't work during a swimlane drag.
|
||||||
background: darken(white, 13%)
|
background: darken(white, 13%)
|
||||||
display: flex
|
display: flex
|
||||||
flex-direction: row
|
flex-direction: column
|
||||||
overflow: 0;
|
overflow: 0;
|
||||||
max-height: 100%
|
max-height: 100%
|
||||||
|
|
||||||
|
@ -27,20 +27,15 @@
|
||||||
.swimlane-header-wrap
|
.swimlane-header-wrap
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
flex: 0 0 50px;
|
flex: 0 0 24px;
|
||||||
padding-bottom: 30px;
|
background-color: #ccc;
|
||||||
border-bottom: 1px solid #CCC
|
|
||||||
|
|
||||||
.swimlane-header
|
.swimlane-header
|
||||||
-ms-writing-mode: tb-rl;
|
|
||||||
writing-mode: vertical-rl;
|
|
||||||
transform: rotate(180deg);
|
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
line-height: 50px;
|
padding: 5px 5px
|
||||||
margin-top: 50px;
|
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
min-height: 9px;
|
min-height: 9px;
|
||||||
width: 50px;
|
width: 100%;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
-o-text-overflow: ellipsis;
|
-o-text-overflow: ellipsis;
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
|
@ -49,7 +44,8 @@
|
||||||
|
|
||||||
.swimlane-header-menu
|
.swimlane-header-menu
|
||||||
position: absolute
|
position: absolute
|
||||||
padding: 20px 20px
|
padding: 5px 5px
|
||||||
|
|
||||||
.list-group
|
.list-group
|
||||||
|
flex-direction: row
|
||||||
height: 100%
|
height: 100%
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue