let kanbanObj = $("#ejKanban").data("ejKanban");And this code update view of changed card (it call action with request type save and action edit), which works well, but it allways scroll to top of Kanban if I wasn't already on top of it.
kanbanObj.updateCard(this.editedTask.id, this.editedTask);
Hi,
yes I foun out why I have this problem. I wanted to have Kanban sized of 100vh - 290px, what I writed in css, because scrollSettings dosen't support this calculation or I can't make it right.
So baisicly there is question how to make kanban height 100vh - 290px or otherwise where to put this style.
Currently I have:
<style>
.e-kanbancontent { height: calc(100vh - 290px) !important; width: 100% !important; }
ej-kanban .e-content { overflow-y: scroll !important; }
</style>
and this obviesly is not good solution.
For more details you can look at my example code. So when scrolling kanban down and than clicking update button, then the kanban window scrolls up, which I don't wannt to.
Regards,
Marko
Kanban.component.ts
import {ViewEncapsulation} from '@angular/core'; // import view encapsulation
@Component({
……….
encapsulation: ViewEncapsulation.None // Set encapsulation mode as none
})
|
Kanban.component.html
<style> // Set styles
.e-kanbancontent { height: calc(100vh - 290px) !important; width: 100% !important; }
ej-kanban .e-kanbancontent { overflow-y: scroll !important; }
</style> |
Hi,
thank you for your reply, I have changed .e-content to .e-kanbancontent and now I don't get to scroll problem any more.
So my style code is now:
.e-kanbancontent { height: calc(100vh - 290px) !important; width: 100% !important; }
ej-kanban .e-kanbancontent { overflow-y: scroll !important; }
ej-kanban .e-content { height: auto !important; }
I don't know why, but now I don't have class e-content in Kanban from your example, but in my code there is...
Anyway thank you for your asistence, my problem has been solved now.
Regards,
Marko
Hi,
I found new problem in last solution. So if I have a few columns with fixed width, that I get kanban x-owerflow, then the scrollbar is always on the bottom of the tasks, so if I wannt to scrool right or left, I first need to scroll down on y cordinate, to get x scroller. For example look at pictures:
So how could I have both scroller always wisible?
Hi,
I wannt to create the following:
So I wannt to have kanban, which takes full window height minus height of header and button, which together takes 200px, so Kanban height should be 100vh - 200px, on any window size (so i can not assume this in advance in px).
So is there any good solution for this?
Regards,
Marko
kanban.component.html
<ej-kanban id="Kanban"
………………
allowScrolling="true" // Enabled allowScrolling property
(load)="load($event)"> // Load event
</ej-kanban> |
kanban.component.ts
export class KanbanComponent {
load(args){ // Triggered when load Kanban control
let height = window.innerHeight - 200; // Get current window height and subtract
args.model.scrollSettings.height = height; // Set scroll settings height
}
} |