doctype html

div.wrapper(
    tg-taskboard,
    ng-controller="TaskboardController as ctrl",
    ng-init="section='backlog'"
)
    tg-project-menu
    section.main.taskboard
        tg-filter(
          open="{{ctrl.openFilter}}"
          q="ctrl.filterQ"
          filters="ctrl.filters"
          custom-filters="ctrl.customFilters"
          selected-filters="ctrl.selectedFilters"
          customFilters="ctl.customFilters"
          on-save-custom-filter="ctrl.saveCustomFilter(name)"
          on-add-filter="ctrl.addFilter(filter)"
          on-select-custom-filter="ctrl.selectCustomFilter(filter)"
          on-remove-custom-filter="ctrl.removeCustomFilter(filter)"
          on-remove-filter="ctrl.removeFilter(filter)"
          on-change-q="ctrl.changeQ(q)"
        )
        .taskboard-header
            h1
                span(tg-bo-bind="project.name", class="project-name-short")
                span.green(tg-bo-bind="sprint.name")
                span.date(tg-date-range="sprint.estimated_start,sprint.estimated_finish")
            .taskboard-actions
                .zoom-loading(tg-loading="ctrl.zoomLoading")
                tg-taskboard-zoom(
                    on-zoom-change="ctrl.setZoom(zoomLevel, zoom)"
                )
                button.button-filter.e2e-open-filter(
                    ng-click="ctrl.openFilter = !ctrl.openFilter"
                )
                    span.filter-num(ng-if="ctrl.selectedFilters.length") {{ctrl.selectedFilters.length}}
                    tg-svg(svg-icon="icon-filters")

        .taskboard-inner

            include ../includes/components/sprint-summary

            div.graphics-container
                div.burndown(tg-sprint-graph)
                    include ../includes/modules/burndown

            include ../includes/modules/taskboard-table

    div.lightbox.lightbox-generic-form.lightbox-create-edit(tg-lb-create-edit)

    div.lightbox.lightbox-generic-bulk.lightbox-task-bulk(tg-lb-create-bulk-tasks)
        include ../includes/modules/lightbox-task-bulk

    div.lightbox.lightbox-generic-bulk(tg-lb-create-bulk-issues)
        include ../includes/modules/lightbox-issue-bulk

    div.lightbox.lightbox-select-user(tg-lb-assignedto)
        include ../common/lightbox/lightbox-assigned-to
