Skip to content

Commit 0dded37

Browse files
authored
Merge pull request #3956 from Northeastern-Electric-Racing/#3908-Gantt-Page-Improvements
#3908 gantt page improvements
2 parents 4a4bdcf + fef5619 commit 0dded37

1 file changed

Lines changed: 36 additions & 9 deletions

File tree

src/frontend/src/pages/GanttPage/ProjectGanttChart/GanttChartColorLegend.tsx

Lines changed: 36 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,14 @@ const GanttChartColorLegend = () => {
136136
display: 'none'
137137
},
138138
scrollbarWidth: 'none', // Firefox
139-
msOverflowStyle: 'none' // IE and Edge
139+
msOverflowStyle: 'none', // IE and Edge
140+
// Mobile responsiveness
141+
'@media (max-width: 768px)': {
142+
flexWrap: 'wrap',
143+
overflowX: 'visible',
144+
marginTop: 1,
145+
justifyContent: 'center'
146+
}
140147
}}
141148
>
142149
{Object.values(WorkPackageStage).map((stage) => {
@@ -148,10 +155,15 @@ const GanttChartColorLegend = () => {
148155
flexDirection: 'column',
149156
height: '2rem',
150157
width: '8.25rem',
151-
borderRadius: 1,
158+
borderRadius: 2,
152159
justifyContent: 'center',
153160
alignItems: 'center',
154-
px: 0.8
161+
px: 0.8,
162+
'@media (max-width: 768px)': {
163+
height: '1.75rem',
164+
width: 'fit-content',
165+
fontsize: '6.75rem'
166+
}
155167
}}
156168
>
157169
<Tooltip
@@ -174,10 +186,15 @@ const GanttChartColorLegend = () => {
174186
flexDirection: 'column',
175187
height: '2rem',
176188
width: '8.25rem',
177-
borderRadius: 1,
189+
borderRadius: 2,
178190
justifyContent: 'center',
179191
alignItems: 'center',
180-
px: 0.8
192+
px: 0.8,
193+
'@media (max-width: 768px)': {
194+
height: '1.75rem',
195+
width: 'fit-content',
196+
fontsize: '6.75rem'
197+
}
181198
}}
182199
>
183200
<Tooltip
@@ -198,10 +215,15 @@ const GanttChartColorLegend = () => {
198215
flexDirection: 'column',
199216
height: '2rem',
200217
width: '8.25rem',
201-
borderRadius: 1,
218+
borderRadius: 2,
202219
justifyContent: 'center',
203220
alignItems: 'center',
204-
px: 0.8
221+
px: 0.8,
222+
'@media (max-width: 768px)': {
223+
height: '1.75rem',
224+
width: 'fit-content',
225+
fontsize: '6.75rem'
226+
}
205227
}}
206228
>
207229
<Tooltip
@@ -222,10 +244,15 @@ const GanttChartColorLegend = () => {
222244
flexDirection: 'column',
223245
height: '2rem',
224246
width: '8.25rem',
225-
borderRadius: 1,
247+
borderRadius: 2,
226248
justifyContent: 'center',
227249
alignItems: 'center',
228-
px: 0.8
250+
px: 0.8,
251+
'@media (max-width: 768px)': {
252+
height: '1.75rem',
253+
width: 'fit-content',
254+
fontsize: '6.75rem'
255+
}
229256
}}
230257
>
231258
<Typography variant="body2" sx={{ color: 'white', overflow: 'hidden', textWrap: 'nowrap' }}>

0 commit comments

Comments
 (0)