From 8828426c9199e07897278441f79a0e497d0c4266 Mon Sep 17 00:00:00 2001 From: konrad Date: Sun, 24 Jan 2021 13:00:21 +0000 Subject: [PATCH] Move all content to cards (#387) Co-authored-by: kolaente Reviewed-on: https://kolaente.dev/vikunja/frontend/pulls/387 Co-authored-by: konrad Co-committed-by: konrad --- cypress/integration/list/list.spec.js | 14 +- src/components/misc/card.vue | 6 +- src/components/tasks/gantt-component.vue | 2 +- src/styles/components/gantt.scss | 6 +- src/styles/components/kanban.scss | 2 +- src/styles/components/list.scss | 2 +- src/styles/components/tasks.scss | 25 +- src/styles/theme/background.scss | 26 -- src/styles/theme/variables/variables.scss | 1 - src/views/list/views/Gantt.vue | 4 +- src/views/list/views/List.vue | 147 ++++++------ src/views/list/views/Table.vue | 276 +++++++++++----------- src/views/tasks/ShowTasks.vue | 38 +-- 13 files changed, 277 insertions(+), 272 deletions(-) diff --git a/cypress/integration/list/list.spec.js b/cypress/integration/list/list.spec.js index 3d85375a3..6093871e6 100644 --- a/cypress/integration/list/list.spec.js +++ b/cypress/integration/list/list.spec.js @@ -156,7 +156,7 @@ describe('Lists', () => { TaskFactory.create(1) cy.visit('/lists/1/gantt') - cy.get('.gantt-chart-container .gantt-chart.box .tasks') + cy.get('.gantt-chart-container .gantt-chart .tasks') .should('be.empty') }) @@ -164,7 +164,7 @@ describe('Lists', () => { const now = new Date() cy.visit('/lists/1/gantt') - cy.get('.gantt-chart-container .gantt-chart.box .months') + cy.get('.gantt-chart-container .gantt-chart .months') .should('contain', format(now, 'MMMM')) .should('contain', format(now.setMonth(now.getMonth() + 1), 'MMMM')) }) @@ -177,9 +177,9 @@ describe('Lists', () => { }) cy.visit('/lists/1/gantt') - cy.get('.gantt-chart-container .gantt-chart.box .tasks') + cy.get('.gantt-chart-container .gantt-chart .tasks') .should('not.be.empty') - cy.get('.gantt-chart-container .gantt-chart.box .tasks') + cy.get('.gantt-chart-container .gantt-chart .tasks') .should('contain', tasks[0].title) }) @@ -194,9 +194,9 @@ describe('Lists', () => { .contains('Show tasks which don\'t have dates set') .click() - cy.get('.gantt-chart-container .gantt-chart.box .tasks') + cy.get('.gantt-chart-container .gantt-chart .tasks') .should('not.be.empty') - cy.get('.gantt-chart-container .gantt-chart.box .tasks .task.nodate') + cy.get('.gantt-chart-container .gantt-chart .tasks .task.nodate') .should('exist') }) @@ -208,7 +208,7 @@ describe('Lists', () => { }) cy.visit('/lists/1/gantt') - cy.get('.gantt-chart-container .gantt-chart.box .tasks .task') + cy.get('.gantt-chart-container .gantt-chart .tasks .task') .first() .trigger('mousedown', {which: 1}) .trigger('mousemove', {clientX: 500, clientY: 0}) diff --git a/src/components/misc/card.vue b/src/components/misc/card.vue index dd415d6ca..fc5120758 100644 --- a/src/components/misc/card.vue +++ b/src/components/misc/card.vue @@ -11,7 +11,7 @@
-
+
@@ -42,6 +42,10 @@ export default { type: Boolean, default: true, }, + hasContent: { + type: Boolean, + default: true, + }, }, } diff --git a/src/components/tasks/gantt-component.vue b/src/components/tasks/gantt-component.vue index aa788afe6..7fa7a60c6 100644 --- a/src/components/tasks/gantt-component.vue +++ b/src/components/tasks/gantt-component.vue @@ -1,5 +1,5 @@ diff --git a/src/views/list/views/List.vue b/src/views/list/views/List.vue index 3f87d77b9..4f979355b 100644 --- a/src/views/list/views/List.vue +++ b/src/views/list/views/List.vue @@ -51,46 +51,48 @@ />
-
-
-

- - + +

+
+

+ + -

-

- - Add - +

+

+ + Add + +

+
+

+ Please specify a list title.

-

- Please specify a list title. + +

+ This list is currently empty. + Create a new task.

-
-

- This list is currently empty. - Create a new task. -

- -
-
-
+
+
-
-
- +
-
- + + diff --git a/src/views/list/views/Table.vue b/src/views/list/views/Table.vue index 1c707b35c..78981b03f 100644 --- a/src/views/list/views/Table.vue +++ b/src/views/list/views/Table.vue @@ -41,144 +41,146 @@ />
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- # - - - Done - - - Name - - - Priority - - - Labels - - Assignees - - Due Date - - - Start Date - - - End Date - - - % Done - - - Created - - - Updated - - - Created By -
- - - - - -
Done
-
- {{ t.title }} - - - - - - - {{ t.percentDone * 100 }}% - -
- - + + +
Done
+ + + {{ t.title }} + + + + + + + + + + + + + + {{ t.percentDone * 100 }}% + + + + + + + + + + + diff --git a/src/views/tasks/ShowTasks.vue b/src/views/tasks/ShowTasks.vue index 644959f11..12ccb206b 100644 --- a/src/views/tasks/ShowTasks.vue +++ b/src/views/tasks/ShowTasks.vue @@ -9,7 +9,7 @@ Show tasks without dates

Current tasks

-

+

Tasks from

-
- Today - Next Week - Next Month +
+ Today + Next Week + Next Month
-