Last active
January 29, 2024 22:50
-
-
Save pangyuteng/97373400dcb70812359d8f7697c2c78a to your computer and use it in GitHub Desktop.
super simple workflow rendering with css and bootstrap
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
<!-- | |
ref | |
https://www.reddit.com/r/webdev/comments/uw0a5a/comment/i9ouqod | |
https://getbootstrap.com/docs/5.0/components/spinners | |
--> | |
<!doctype html> | |
<html lang="en" data-bs-theme="dark"> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous"> | |
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-C6RzsynM9kWDrMNeT87bh95OGNyZPhcTNXj1NW7RuBCsyN/o0jlpcV8Qyq46cDfL" crossorigin="anonymous"></script> | |
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/font/bootstrap-icons.min.css"> | |
<style> | |
.workflow { | |
max-width: 640px; | |
margin: 2rem auto; | |
display: flex; | |
align-items: flex-start; | |
justify-content: center; | |
text-align: center; | |
margin: 20px; | |
} | |
.step { | |
position: relative; | |
display: flex; | |
flex-direction: column; | |
align-items: center; | |
&:not(:last-of-type) { | |
margin-right: 2rem; | |
} | |
} | |
.wrap { | |
text-align: center; | |
margin: 20px; | |
position: relative; | |
} | |
.links { | |
padding: 0 10px; | |
display: flex; | |
justify-content: space-between; | |
position: relative; | |
} | |
.wrap:before { | |
content: ''; | |
position: absolute; | |
top: 25%; | |
left: 0; | |
border-top: 5px solid black; | |
background: black; | |
width: 100%; | |
transform: translateY(-50%); | |
} | |
</style> | |
</head> | |
<body> | |
<div class="workflow wrap"> | |
<div class="links"> | |
<div class="step step1"> | |
<div class="icon"> | |
<i class="bi bi-exclamation-circle-fill" style = "color:red;"></i> | |
</div> | |
<div class="text">error</div> | |
</div> | |
<div class="step step2"> | |
<div class="icon"> | |
<i class="bi bi-check-circle-fill" style="color:green;"></i> | |
</div> | |
<div class="text">done</div> | |
</div> | |
<div class="step step4"> | |
<div class="icon"> | |
<div class="spinner-grow spinner-grow-sm" role="status" style="color:gray;"></div> | |
</div> | |
<div class="text">in-progress</div> | |
</div> | |
<div class="step step3"> | |
<div class="icon"><i class="bi bi-circle-fill" style="color:gray;"></i></div> | |
<div class="text">pending</div> | |
</div> | |
</div> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
keywords: data pipeline workflow visualization css
graphviz so yucky:
https://learn.microsoft.com/en-us/nimbusml/tutorials/c_a-visualize-a-pipeline
related/inspiration:
https://docs.gitlab.com/ee/ci/pipeline_editor
https://docs.github.com/en/actions/monitoring-and-troubleshooting-workflows/using-the-visualization-graph
https://www.reddit.com/r/dataengineering/comments/otwwfe/this_nice_illustration_or_visualization_of_the
very simple, we'll take it:
https://www.reddit.com/r/webdev/comments/uw0a5a/is_there_any_simple_way_we_can_achieve_this_using