Skip to content

Commit

Permalink
update argo-ui once more for deprecated durationMs removal
Browse files Browse the repository at this point in the history
Signed-off-by: Anton Gilgur <agilgur5@gmail.com>
  • Loading branch information
Anton Gilgur committed Sep 14, 2024
1 parent ba27d44 commit 90e2cd1
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export const ApplicationDeploymentHistory = ({
const recentDeployments = deployments.map((info, i) => {
const nextDeployedAt = i === 0 ? null : deployments[i - 1].deployedAt;
const runEnd = nextDeployedAt ? moment(nextDeployedAt) : moment();
return {...info, nextDeployedAt, durationMs: runEnd.diff(moment(info.deployedAt)) / 1000};
return {...info, nextDeployedAt, durationS: runEnd.diff(moment(info.deployedAt)) / 1000};
});
return (
<div className='application-deployment-history'>
Expand All @@ -40,7 +40,7 @@ export const ApplicationDeploymentHistory = ({
<br />
<i className='fa fa-hourglass-half' /> <span className='show-for-large'>Time to deploy:</span>
<br />
{(info.deployStartedAt && <Duration durationS={moment(info.deployedAt).diff(moment(info.deployStartedAt)) / 1000} durationMs={0} />) || 'Unknown'}
{(info.deployStartedAt && <Duration durationS={moment(info.deployedAt).diff(moment(info.deployStartedAt)) / 1000} />) || 'Unknown'}
</div>
<div>
<br />
Expand All @@ -52,7 +52,7 @@ export const ApplicationDeploymentHistory = ({
<br />
Active for:
<br />
<Duration durationS={info.durationMs} durationMs={0} />
<Duration durationS={info.durationS} />
</div>
</div>
<div className='columns small-9'>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,7 @@ export const ApplicationOperationState: React.StatelessComponent<Props> = ({appl
value: (
<Ticker>
{time => (
<Duration
durationS={((operationState.finishedAt && moment(operationState.finishedAt)) || moment(time)).diff(moment(operationState.startedAt)) / 1000}
durationMs={0}
/>
<Duration durationS={((operationState.finishedAt && moment(operationState.finishedAt)) || moment(time)).diff(moment(operationState.startedAt)) / 1000} />
)}
</Ticker>
)
Expand Down
2 changes: 1 addition & 1 deletion ui/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2893,7 +2893,7 @@ arg@^4.1.0:

"argo-ui@git+https://github.com/argoproj/argo-ui.git":
version "1.0.0"
resolved "git+https://github.com/argoproj/argo-ui.git#a7b01f9f009aa9161da21f450b5aab2f0732eb74"
resolved "git+https://github.com/argoproj/argo-ui.git#d9a4285dc254bc473b9f26f5d72655296233f003"
dependencies:
"@fortawesome/fontawesome-free" "^6.2.1"
"@tippy.js/react" "^3.1.1"
Expand Down

0 comments on commit 90e2cd1

Please sign in to comment.