Skip to content
This repository has been archived by the owner on Nov 27, 2023. It is now read-only.

feat(viz): Provide an empty state for the canvas #1967

Merged
merged 1 commit into from
Jun 14, 2023
Merged

feat(viz): Provide an empty state for the canvas #1967

merged 1 commit into from
Jun 14, 2023

Conversation

lordrip
Copy link
Member

@lordrip lordrip commented Jun 14, 2023

Context

Currently, whenever there's no visible route in the canvas, a full gray area is shown.

image

Changes

The goal for this commit is to provide more information to the user about the status of the routes in the canvas itself. When there are no visible routes, an according message will be displayed.

No visible routes

image

No routes

image

fixes: #1909

@lordrip lordrip requested a review from a team June 14, 2023 14:04
@lhein
Copy link

lhein commented Jun 14, 2023

looks good!

igarashitm
igarashitm previously approved these changes Jun 14, 2023
<Background color="#aaa" gap={16} />
</ReactFlow>
</div>
{visibleFlowsInformation.isCanvasEmpty ? (
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OMG, I forgot to add tests for this clause, I'll add this test case and merge it afterward.

@tplevko covering this condition at the integration test side would be enough or should we add an e2e as well?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here we have the missing test

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well from my POV, I think the test you added should be enough, can add more testing for this in e2e if requested.

Currently, whenever there's no visible route in the canvas, a full
gray area is shown.

The goal for this commit is to provide more information to the user
about the status of the routes in the canvas itself. When there's no
visible routes, an according message will be displayed.
@sonarcloud
Copy link

sonarcloud bot commented Jun 14, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@codecov
Copy link

codecov bot commented Jun 14, 2023

Codecov Report

Merging #1967 (0e1bce7) into main (5a39054) will increase coverage by 0.46%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main    #1967      +/-   ##
==========================================
+ Coverage   60.25%   60.72%   +0.46%     
==========================================
  Files          76       78       +2     
  Lines        2521     2546      +25     
  Branches      565      576      +11     
==========================================
+ Hits         1519     1546      +27     
- Misses        955      956       +1     
+ Partials       47       44       -3     
Impacted Files Coverage Δ
src/components/Flows/FlowsListEmptyState.tsx 100.00% <100.00%> (ø)
src/components/Flows/FlowsMenu.tsx 88.88% <100.00%> (-1.59%) ⬇️
src/components/Visualization.tsx 73.52% <100.00%> (+7.90%) ⬆️
...mponents/Visualization/VisualizationEmptyState.tsx 100.00% <100.00%> (ø)
src/hooks/flows-visibility.hook.ts 100.00% <100.00%> (ø)
src/services/visualizationService.ts 83.74% <100.00%> (-0.47%) ⬇️

... and 4 files with indirect coverage changes

@lordrip lordrip merged commit 900f79a into KaotoIO:main Jun 14, 2023
@lordrip lordrip deleted the feat/canvas-empty-state branch July 10, 2023 11:26
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Indicate no routes are created
4 participants