New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(ui): Add drawer with more details for each workflow in Workflow List #3151
Merged
Merged
Changes from all commits
Commits
Show all changes
35 commits
Select commit
Hold shift + click to select a range
8b20eda
Add labels column to workflows list
rbreeze 736cd00
feat(ui): add ability to filter workflows by label by clicking on a l…
rbreeze 6af5d5d
Refactor labels column into its own component. Add show / hide button…
rbreeze 0b4cf34
fix(ui): linting issue with FontAwesome tags not being self closing
rbreeze 5001871
Fix no new line at EOF issue
rbreeze e88cd10
Linted
rbreeze b61ca97
Remove text-decoration from SHOW / HIDE buttons and remove async / aw…
rbreeze 58e61f4
Merge branch 'master' of github.com:argoproj/argo into label-filtering
rbreeze 9a7b5dc
Resize workflows list columns for better visibility.
rbreeze a7a7c02
Change variable name of workflow to match convention
rbreeze 376d96f
Linted
rbreeze 7186409
Refactor workflows list by separating out rows into an independent co…
rbreeze 27db356
Merge branch 'master' of github.com:argoproj/argo into label-filtering
rbreeze 85e115a
Style labels to emphasize which row they belong to
rbreeze c0b630f
Fix colors of label drawer for better contrast
rbreeze 1a5031f
feat(ui): Add more details to workflow labels drawer: message, resour…
rbreeze d85d192
Linted
rbreeze 45eab5d
Resolve merge conflicts
rbreeze b24ee90
Fix format of labels
rbreeze 251f89f
Linted
rbreeze 7ec9961
Add lazy loading for workflows list drawer
rbreeze 59c21b0
Merge branch 'master' of github.com:argoproj/argo into info-drawer
rbreeze ae73519
fix(server): Allow for field selection for workflow-event endpoint. F…
rbreeze 084f923
Fix lazy loading referencing prop instead of state
rbreeze 1017094
Codegen
simster7 161c3cb
Merge branch 'master' into HEAD
simster7 42155c3
Revert go.mod and go.sum changes
simster7 f209bdb
Swagger
simster7 e572625
Reorder display of info in drawer, small refactor of Workflows Row co…
rbreeze 6c686d8
Merge branch 'master' of github.com:argoproj/argo into info-drawer
rbreeze 7d9cbe0
Remove changes from #3165
rbreeze 0231220
Reformat drawer to better display workflow conditions
rbreeze 2720473
Revert generated file to older version
rbreeze dce8c0d
Change how conditions are displayed in workflow drawer
rbreeze 57fb2d3
Lint
simster7 File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
119 changes: 119 additions & 0 deletions
119
ui/src/app/workflows/components/workflow-drawer/workflow-drawer.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,119 @@ | ||
@import 'node_modules/argo-ui/src/styles/config'; | ||
|
||
.workflow-drawer { | ||
height: 100%; | ||
font-size: .8125em; | ||
background-color: $argo-color-gray-1; | ||
margin-top: -8px; | ||
padding: 1.5em 15px; | ||
border-radius: 0 0 3px 3px; | ||
|
||
&__section { | ||
padding: 1em 0; | ||
box-sizing: border-box; | ||
border-top: 2px solid $argo-color-gray-3; | ||
|
||
&:first-child { | ||
padding-top: 0; | ||
border-top: none; | ||
} | ||
|
||
&:last-child { | ||
padding-bottom: 0; | ||
} | ||
|
||
&:only-child { | ||
padding: 0; | ||
} | ||
} | ||
|
||
&__message { | ||
|
||
&--label { | ||
margin-bottom: 1em; | ||
} | ||
|
||
&--content { | ||
font-weight: 600; | ||
} | ||
|
||
} | ||
|
||
&__labels { | ||
&--list { | ||
margin-top: 0.5em; | ||
} | ||
} | ||
|
||
&__message { | ||
border-top: none; | ||
} | ||
|
||
.tag { | ||
line-height: normal; | ||
background-color: $argo-color-gray-3; | ||
border-radius: 3px; | ||
height: auto; | ||
margin: 0.5em 0; | ||
margin-right: 10px; | ||
display: flex; | ||
overflow: hidden; | ||
cursor: pointer; | ||
|
||
&:hover { | ||
.key { | ||
color: $argo-color-teal-5; | ||
} | ||
.value { | ||
color: $argo-color-gray-3; | ||
} | ||
} | ||
|
||
.key, .value { | ||
padding: 0.5em 8px; | ||
} | ||
|
||
.key { | ||
color: $argo-color-gray-6; | ||
} | ||
|
||
.value { | ||
color: white; | ||
background-color: $argo-color-teal-5; | ||
} | ||
} | ||
|
||
&__resourcesDuration { | ||
display: flex; | ||
align-items: center; | ||
|
||
$gutter: 2em; | ||
|
||
&--label { | ||
margin-left: 0.5em; | ||
} | ||
|
||
&--value { | ||
font-weight: 600; | ||
} | ||
|
||
&--container { | ||
padding-left: $gutter / 2; | ||
margin-left: $gutter / 2; | ||
border-left: 1px solid $argo-color-gray-3; | ||
} | ||
|
||
} | ||
|
||
&__conditions { | ||
margin-top: 0.5em; | ||
|
||
.condition-panel__type { | ||
font-weight: 600; | ||
} | ||
|
||
.type { | ||
font-weight: 600; | ||
} | ||
} | ||
} |
69 changes: 69 additions & 0 deletions
69
ui/src/app/workflows/components/workflow-drawer/workflow-drawer.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
import * as React from 'react'; | ||
import * as models from '../../../../models'; | ||
|
||
import {ConditionsPanel} from '../../../shared/conditions-panel'; | ||
import {WorkflowLabels} from '../workflow-labels/workflow-labels'; | ||
|
||
require('./workflow-drawer.scss'); | ||
|
||
interface WorkflowDrawerProps { | ||
workflow: models.Workflow; | ||
onChange: (key: string) => void; | ||
} | ||
|
||
export class WorkflowDrawer extends React.Component<WorkflowDrawerProps, {}> { | ||
public render() { | ||
const wf = this.props.workflow; | ||
return ( | ||
<div className='workflow-drawer'> | ||
{!wf.status.message ? null : ( | ||
<div className='workflow-drawer__section workflow-drawer__message'> | ||
<div className='workflow-drawer__title workflow-drawer__message--label'>MESSAGE</div> | ||
<div className='workflow-drawer__message--content'>{wf.status.message}</div> | ||
</div> | ||
)} | ||
{!wf.status.conditions ? null : ( | ||
<div className='workflow-drawer__section'> | ||
<div className='workflow-drawer__title'>CONDITIONS</div> | ||
<div className='workflow-drawer__conditions'> | ||
<ConditionsPanel conditions={wf.status.conditions} /> | ||
</div> | ||
</div> | ||
)} | ||
{!wf.status.resourcesDuration ? null : ( | ||
<div className='workflow-drawer__section'> | ||
<div className='workflow-drawer__resourcesDuration'> | ||
<div className='workflow-drawer__title'> | ||
RESOURCES DURATION | ||
<a href='https://github.com/argoproj/argo/blob/master/docs/resource-duration.md' target='_blank'> | ||
<i className='fas fa-info-circle' /> | ||
</a> | ||
</div> | ||
<div className='workflow-drawer__resourcesDuration--container'> | ||
<div> | ||
<span className='workflow-drawer__resourcesDuration--value'>{wf.status.resourcesDuration.cpu} sec</span> | ||
<span className='workflow-drawer__resourcesDuration--label'>(*1 CPU)</span> | ||
</div> | ||
<div> | ||
<span className='workflow-drawer__resourcesDuration--value'>{wf.status.resourcesDuration.memory} sec</span> | ||
<span className='workflow-drawer__resourcesDuration--label'>(*100Mi Memory)</span> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
)} | ||
<div className='workflow-drawer__section workflow-drawer__labels'> | ||
<div className='workflow-drawer__title'>LABELS</div> | ||
<div className='workflow-drawer__labels--list'> | ||
<WorkflowLabels | ||
workflow={wf} | ||
onChange={key => { | ||
this.props.onChange(key); | ||
}} | ||
/> | ||
</div> | ||
</div> | ||
</div> | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would change the ordering things are displayed here to be