Skip to content
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

👻 Align TaskStateIcon Icon status fields with IconedStatus #1989

Merged
merged 1 commit into from
Jul 1, 2024

Conversation

sjd78
Copy link
Member

@sjd78 sjd78 commented Jul 1, 2024

Align TaskStateIcon Icon status fields with IconedStatus.

This amounts to setting some icons blue instead of black consistently across tables and the drawer.

Related to #1985

Copy link

codecov bot commented Jul 1, 2024

Codecov Report

Attention: Patch coverage is 0% with 2 lines in your changes missing coverage. Please review.

Project coverage is 42.23%. Comparing base (b654645) to head (cf58e87).
Report is 182 commits behind head on main.

Files Patch % Lines
client/src/app/components/Icons/TaskStateIcon.tsx 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1989      +/-   ##
==========================================
+ Coverage   39.20%   42.23%   +3.03%     
==========================================
  Files         146      170      +24     
  Lines        4857     5443     +586     
  Branches     1164     1373     +209     
==========================================
+ Hits         1904     2299     +395     
- Misses       2939     3027      +88     
- Partials       14      117     +103     
Flag Coverage Δ
client 42.23% <0.00%> (+3.03%) ⬆️
server ?

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@sjd78 sjd78 merged commit 16d063e into konveyor:main Jul 1, 2024
12 checks passed
dymurray pushed a commit that referenced this pull request Jul 2, 2024
…1985)

## Summary
On the application table's name column, add a status icon. The icon
summarizes the status of the various kinds of tasks attached to an
application (a single application has 0 or more tasks while a task acts
on a single application).

The icon will be driven off looking at the most recent task (by
`createTime`) per `kind` for an application:
  - If there are no tasks, show the application in No Tasks state
  - Else if any are "running", show the application in Running
  - Else if any are "queued", show the application in Queued state
  - Else if any are "failed", show the application as Failed
  - Else if any are "canceled", show the application as Canceled
  - Else if any are "succeeded", show the application as Success

A popover on hover will render on the application name column to display
summary information about the application's
tasks. The popover will have a table that shows the most recent tasks
for each kind of task associated to the application.
  - Task id
  - Task status icon with the task kind
  - How long ago the task was started/created (exact time in a tooltip)

Based on refactoring PR #1988 and PR #1989
Closes: #1934
Fixes: #1772

## Change Details
- Created `useDecoratedApplications()` hook to run all calculations and
cross-referencing necessary to render most of the table.

- Created `ColumnApplicationName` to handle the application name column
with the status icon and popover.

- Refactored `useFetchTasks()` hook to only do a simple sort. The
filtering based on kind is no longer necessary.

- The base `ApplicationsTable` received some basic refactoring to
utilize the content of `DecoratedApplication`

## Screen Shots
Base view with various application task statuses:
![screenshot-localhost_9000-2024 06
28-02_38_20](https://github.com/konveyor/tackle2-ui/assets/3985964/c712fc21-72f0-4529-a5bd-b0e2678910f7)

Popover details of an application with canceled tasks:
![screenshot-localhost_9000-2024 06
28-02_38_39](https://github.com/konveyor/tackle2-ui/assets/3985964/4f46159a-81a0-421a-b28a-0067f703f402)

Popover details of an application with successful tasks:
![screenshot-localhost_9000-2024 06
28-02_39_09](https://github.com/konveyor/tackle2-ui/assets/3985964/5d4bc6c3-1449-421e-b938-3bea2cf87377)

Popover details of an application with failed tasks:
![screenshot-localhost_9000-2024 06
28-02_39_43](https://github.com/konveyor/tackle2-ui/assets/3985964/421fd3e6-78fa-4689-b824-20f0ea95916a)

---------

Signed-off-by: Scott J Dickerson <[email protected]>
@sjd78 sjd78 deleted the align-icon-status branch July 17, 2024 12:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants