Skip to content

Commit 5b5e654

Browse files
Minor design tweaks for ungrouped history view (#938)
- Change hover highlight from darkened background to darkened box shadow, to prevent JSON inputs from blending in - Add a black box shadow for the "animate on enter" behaviour - Remove darkened background from "animate on enter" - Rename animateBackgroundOnEnter to animateOnEnter
1 parent 1b18bc4 commit 5b5e654

File tree

4 files changed

+9
-9
lines changed

4 files changed

+9
-9
lines changed

src/views/workflow-history/workflow-history-ungrouped-event/workflow-history-ungrouped-event.styles.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ export const styled = {
3838
),
3939
};
4040

41-
export const overrides = (animateBackgroundOnEnter?: boolean) => ({
41+
export const overrides = (animateOnEnter?: boolean) => ({
4242
panel: {
4343
PanelContainer: {
4444
style: ({ $theme }: { $theme: Theme }): StyleObject => ({
@@ -48,16 +48,16 @@ export const overrides = (animateBackgroundOnEnter?: boolean) => ({
4848
marginTop: $theme.sizing.scale0,
4949
marginBottom: $theme.sizing.scale0,
5050
':hover': {
51-
backgroundColor: $theme.colors.backgroundSecondary,
51+
boxShadow: `0px 0px 0px 2px ${$theme.colors.borderTransparent}`,
5252
},
53-
...(animateBackgroundOnEnter && {
53+
...(animateOnEnter && {
5454
animationDuration: '2s',
5555
animationName: {
5656
from: {
57-
backgroundColor: $theme.colors.backgroundTertiary,
57+
boxShadow: `0px 0px 0px 2px ${$theme.colors.primary}`,
5858
},
5959
to: {
60-
backgroundColor: $theme.colors.backgroundPrimary,
60+
boxShadow: `0px 0px 0px 0px rgba(0, 0, 0, 0)`,
6161
},
6262
},
6363
}),

src/views/workflow-history/workflow-history-ungrouped-event/workflow-history-ungrouped-event.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@ export default function WorkflowHistoryUngroupedEvent({
2626
decodedPageUrlParams,
2727
isExpanded,
2828
toggleIsExpanded,
29-
animateBackgroundOnEnter,
29+
animateOnEnter,
3030
onReset,
3131
}: Props) {
3232
const retries = getRetriesForHistoryEvent(eventInfo.event);
33-
const overrides = getOverrides(animateBackgroundOnEnter);
33+
const overrides = getOverrides(animateOnEnter);
3434

3535
return (
3636
<Panel

src/views/workflow-history/workflow-history-ungrouped-event/workflow-history-ungrouped-event.types.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,6 @@ export type Props = {
3232
toggleIsExpanded: () => void;
3333

3434
// UI behavior
35-
animateBackgroundOnEnter?: boolean;
35+
animateOnEnter?: boolean;
3636
onReset?: () => void;
3737
};

src/views/workflow-history/workflow-history-ungrouped-table/workflow-history-ungrouped-table.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ export default function WorkflowHistoryUngroupedTable({
4343
decodedPageUrlParams={decodedPageUrlParams}
4444
isExpanded={getIsEventExpanded(eventInfo.id)}
4545
toggleIsExpanded={() => toggleIsEventExpanded(eventInfo.id)}
46-
animateBackgroundOnEnter={eventInfo.id === selectedEventId}
46+
animateOnEnter={eventInfo.id === selectedEventId}
4747
{...(eventInfo.canReset
4848
? { onReset: () => onResetToEventId(eventInfo.id) }
4949
: {})}

0 commit comments

Comments
 (0)