Skip to content

Commit

Permalink
Workflow and domain page responsiveness (#728)
Browse files Browse the repository at this point in the history
* workflow and domain page responsiveness

* retain ellipses in wraped workflow label

* fix review comments

---------

Co-authored-by: Assem-Hafez <[email protected]>
  • Loading branch information
Assem-Uber and Assem-Hafez authored Nov 14, 2024
1 parent 42d7886 commit 6fbbecc
Show file tree
Hide file tree
Showing 5 changed files with 52 additions and 19 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,12 @@ import { styled as createStyled } from 'baseui';
export const styled = {
DomainDetailsContainer: createStyled('div', ({ $theme }) => ({
display: 'flex',
flexDirection: 'row',
flexDirection: 'column',
flexWrap: 'wrap',
columnGap: $theme.sizing.scale850,
rowGap: $theme.sizing.scale500,
[$theme.mediaQuery.medium]: {
flexDirection: 'row',
},
})),
};
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,24 @@ const cssStylesObj = {
display: 'flex',
flexDirection: 'column',
},
timelineEventHeader: {
timelineEventHeader: (theme) => ({
display: 'flex',
alignItems: 'center',
gap: '16px',
padding: '12px 0',
},
gap: theme.sizing.scale600,
padding: `${theme.sizing.scale500} 0`,
}),
timelineEventLabelAndTime: (theme) => ({
display: 'flex',
flexDirection: 'column',
gap: 0,
overflow: 'hidden',
[theme.mediaQuery.medium]: {
display: 'flex',
flexDirection: 'row',
alignItems: 'center',
gap: theme.sizing.scale200,
},
}),
timelineEventsLabel: (theme) => ({
...theme.typography.LabelLarge,
whiteSpace: 'nowrap',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,11 @@ export default function WorkflowHistoryTimelineGroup({
<div className={cls.groupContainer}>
<div className={cls.timelineEventHeader}>
<WorkflowHistoryEventStatusBadge status={status} size="medium" />
<div className={cls.timelineEventsLabel}>{label}</div>
<div suppressHydrationWarning className={cls.timelineEventsTime}>
{timeLabel}
<div className={cls.timelineEventLabelAndTime}>
<div className={cls.timelineEventsLabel}>{label}</div>
<div suppressHydrationWarning className={cls.timelineEventsTime}>
{timeLabel}
</div>
</div>
</div>
<div className={cls.timelineEventCardContainer}>
Expand Down
35 changes: 24 additions & 11 deletions src/views/workflow-history/workflow-history.styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,30 +9,43 @@ const cssStylesObj = {
flexDirection: 'column',
flex: 1,
},
pageHeader: {
pageHeader: (theme) => ({
display: 'flex',
alignItems: 'center',
flexDirection: 'column',
justifyContent: 'space-between',
flexWrap: 'wrap',
},
gap: theme.sizing.scale500,
[theme.mediaQuery.medium]: {
alignItems: 'center',
flexDirection: 'row',
},
}),
headerActions: (theme) => ({
display: 'flex',
flexDirection: 'column',
flexWrap: 'wrap',
gap: theme.sizing.scale500,
[theme.mediaQuery.medium]: {
flexDirection: 'row',
},
}),
eventsContainer: (theme) => ({
display: 'flex',
marginTop: theme.sizing.scale500,
// gap: theme.sizing.scale400,
}),
compactSection: (theme) => ({
display: 'flex',
flexDirection: 'column',
width: '362px',
maxHeight: `calc(100vh - ${theme.sizing.scale900})`, // fill page height excluding page bottom margin
overflow: 'auto',
position: 'sticky',
top: 0,
paddingRight: theme.sizing.scale800,
display: 'none',
[theme.mediaQuery.large]: {
display: 'flex',
flexDirection: 'column',
width: '362px',
maxHeight: `calc(100vh - ${theme.sizing.scale900})`, // fill page height excluding page bottom margin
overflow: 'auto',
position: 'sticky',
top: 0,
paddingRight: theme.sizing.scale800,
},
}),
compactCardContainer: (theme) => ({
display: 'flex',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ export const overrides = {
alignItems: 'center',
marginBottom: $theme.sizing.scale200,
...$theme.typography.LabelSmall,
lineHeight: $theme.typography.LabelMedium.lineHeight,
}),
},
} satisfies BreadcrumbsOverrides,
Expand Down

0 comments on commit 6fbbecc

Please sign in to comment.