Skip to content

Commit

Permalink
embedded cluster state display should not split up application state
Browse files Browse the repository at this point in the history
  • Loading branch information
laverya committed Jan 17, 2024
1 parent f8f4479 commit 78d8320
Showing 1 changed file with 29 additions and 29 deletions.
58 changes: 29 additions & 29 deletions web/src/features/Dashboard/components/AppStatus.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -109,35 +109,6 @@ export default class AppStatus extends Component<Props, State> {
>
{Utilities.toTitleCase(appStatus)}
</span>
{!isEmpty(embeddedClusterState) && (
<>
<span className="tw-mr-1 tw-ml-4 tw-text-sm tw-text-gray-500">
Cluster State:
</span>
<span
className={`status-dot ${
embeddedClusterState === "Installed"
? "u-color--success"
: embeddedClusterState === "Installing" ||
embeddedClusterState === "Enqueued"
? "u-color--warning"
: "u-color--error"
}`}
/>
<span
className={`u-fontSize--normal u-fontWeight--medium ${
embeddedClusterState === "Installed"
? "u-textColor--bodyCopy"
: embeddedClusterState === "Installing" ||
embeddedClusterState === "Enqueued"
? "u-textColor--warning"
: "u-textColor--error"
}`}
>
{Utilities.clusterState(embeddedClusterState)}
</span>
</>
)}
{this.props.hasStatusInformers && (
<span
onClick={this.props.onViewAppStatusDetails}
Expand All @@ -147,6 +118,35 @@ export default class AppStatus extends Component<Props, State> {
Details{" "}
</span>
)}
{!isEmpty(embeddedClusterState) && (
<>
<span className="tw-mr-1 tw-ml-4 tw-text-sm tw-text-gray-500">
Cluster State:
</span>
<span
className={`status-dot ${
embeddedClusterState === "Installed"
? "u-color--success"
: embeddedClusterState === "Installing" ||
embeddedClusterState === "Enqueued"
? "u-color--warning"
: "u-color--error"
}`}
/>
<span
className={`u-fontSize--normal u-fontWeight--medium ${
embeddedClusterState === "Installed"
? "u-textColor--bodyCopy"
: embeddedClusterState === "Installing" ||
embeddedClusterState === "Enqueued"
? "u-textColor--warning"
: "u-textColor--error"
}`}
>
{Utilities.clusterState(embeddedClusterState)}
</span>
</>
)}
<Link
to={`${url}/config/${app?.downstream?.currentVersion?.sequence}`}
className="link u-marginLeft--10 u-borderLeft--gray u-paddingLeft--10 u-fontSize--small"
Expand Down

0 comments on commit 78d8320

Please sign in to comment.