|
1 | 1 | <template> |
2 | | - <div> |
| 2 | + <div class="task-log-view" :class="{'task-log-view--with-message': item.message}"> |
3 | 3 | <v-alert |
4 | 4 | type="info" |
5 | 5 | text |
6 | 6 | v-if="item.message" |
7 | | - >{{ item.message }}</v-alert> |
| 7 | + >{{ item.message }} |
| 8 | + </v-alert> |
8 | 9 |
|
9 | 10 | <v-container class="pa-0 mb-2"> |
10 | 11 | <v-row no-gutters> |
|
13 | 14 | <v-list-item class="pa-0"> |
14 | 15 | <v-list-item-content> |
15 | 16 | <div> |
16 | | - <TaskStatus :status="item.status" /> |
| 17 | + <TaskStatus :status="item.status"/> |
17 | 18 | </div> |
18 | 19 | </v-list-item-content> |
19 | 20 | </v-list-item> |
20 | 21 | </v-list> |
21 | 22 | </v-col> |
22 | 23 | <v-col> |
23 | | - <v-list two-line subheader class="pa-0"> |
24 | | - <v-list-item class="pa-0"> |
25 | | - <v-list-item-content> |
26 | | - <v-list-item-title>Author</v-list-item-title> |
27 | | - <v-list-item-subtitle>{{ user.name }}</v-list-item-subtitle> |
28 | | - </v-list-item-content> |
29 | | - </v-list-item> |
30 | | - </v-list> |
| 24 | + <v-list two-line subheader class="pa-0"> |
| 25 | + <v-list-item class="pa-0"> |
| 26 | + <v-list-item-content> |
| 27 | + <v-list-item-title>Author</v-list-item-title> |
| 28 | + <v-list-item-subtitle>{{ user.name }}</v-list-item-subtitle> |
| 29 | + </v-list-item-content> |
| 30 | + </v-list-item> |
| 31 | + </v-list> |
31 | 32 | </v-col> |
32 | 33 | <v-col> |
33 | 34 | <v-list two-line subheader class="pa-0"> |
|
53 | 54 | </v-col> |
54 | 55 | </v-row> |
55 | 56 | </v-container> |
56 | | - <div class="task-log-view" ref="output"> |
57 | | - <div class="task-log-view__record" v-for="record in output" :key="record.id"> |
58 | | - <div class="task-log-view__time"> |
| 57 | + <div class="task-log-records" ref="output"> |
| 58 | + <div class="task-log-records__record" v-for="record in output" :key="record.id"> |
| 59 | + <div class="task-log-records__time"> |
59 | 60 | {{ record.time | formatTime }} |
60 | 61 | </div> |
61 | | - <div class="task-log-view__output">{{ record.output }}</div> |
| 62 | + <div class="task-log-records__output">{{ record.output }}</div> |
62 | 63 | </div> |
63 | 64 | </div> |
64 | 65 |
|
|
72 | 73 | </v-btn> |
73 | 74 | </div> |
74 | 75 | </template> |
| 76 | + |
75 | 77 | <style lang="scss"> |
76 | | - .task-log-view { |
77 | | - background: black; |
78 | | - color: white; |
79 | | - height: calc(100vh - 300px); |
80 | | - overflow: auto; |
81 | | - font-family: monospace; |
82 | | - margin: 0 -24px; |
83 | | - padding: 5px 10px; |
84 | | - } |
85 | 78 |
|
86 | | - .task-log-view__record { |
87 | | - display: flex; |
88 | | - flex-direction: row; |
89 | | - justify-content: left; |
90 | | - } |
| 79 | +@import '~vuetify/src/styles/settings/_variables'; |
| 80 | +
|
| 81 | +.task-log-view { |
| 82 | +} |
| 83 | +
|
| 84 | +.task-log-records { |
| 85 | + background: black; |
| 86 | + color: white; |
| 87 | + height: calc(100vh - 250px); |
| 88 | + overflow: auto; |
| 89 | + font-family: monospace; |
| 90 | + margin: 0 -24px; |
| 91 | + padding: 5px 10px; |
| 92 | +} |
| 93 | +
|
| 94 | +.task-log-view--with-message .task-log-records { |
| 95 | + height: calc(100vh - 300px); |
| 96 | +} |
| 97 | +
|
| 98 | +.task-log-records__record { |
| 99 | + display: flex; |
| 100 | + flex-direction: row; |
| 101 | + justify-content: left; |
| 102 | +} |
| 103 | +
|
| 104 | +.task-log-records__time { |
| 105 | + width: 120px; |
| 106 | + min-width: 120px; |
| 107 | +} |
| 108 | +
|
| 109 | +.task-log-records__output { |
| 110 | + width: 100%; |
| 111 | +} |
91 | 112 |
|
92 | | - .task-log-view__time { |
93 | | - width: 120px; |
94 | | - min-width: 120px; |
| 113 | +@media #{map-get($display-breakpoints, 'sm-and-down')} { |
| 114 | + .task-log-records { |
| 115 | + height: calc(100vh - 340px); |
95 | 116 | } |
96 | 117 |
|
97 | | - .task-log-view__output { |
98 | | - width: 100%; |
| 118 | + .task-log-view--with-message .task-log-records { |
| 119 | + height: calc(100vh - 370px); |
99 | 120 | } |
| 121 | +} |
100 | 122 | </style> |
101 | 123 | <script> |
102 | 124 | import axios from 'axios'; |
|
0 commit comments