components/Gauge : ajout
This commit is contained in:
parent
42838c7c6a
commit
34cc7a96e6
1 changed files with 29 additions and 0 deletions
29
src/components/Gauge.astro
Normal file
29
src/components/Gauge.astro
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
---
|
||||||
|
const { fillPercentage } = Astro.props;
|
||||||
|
---
|
||||||
|
|
||||||
|
<div class="gauge">
|
||||||
|
<div class="bar" style={ `width: ${fillPercentage}%` }></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
.gauge {
|
||||||
|
width: 100%;
|
||||||
|
height: 30px;
|
||||||
|
background-color: #221d30;
|
||||||
|
border-radius: 15px;
|
||||||
|
box-sizing: border-box;
|
||||||
|
//margin: 20px 30px;
|
||||||
|
box-shadow: inset 0 0 0 1px #c6bfd990;
|
||||||
|
margin: 20px 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.bar {
|
||||||
|
//<!-- background-color: green; -->
|
||||||
|
//width: 20px;
|
||||||
|
height: 100%;
|
||||||
|
background: linear-gradient(90deg, #9933ff 0%, #ff4dff 100%);
|
||||||
|
box-shadow: 0 0 30px 1px #ff1affd0;
|
||||||
|
border-radius: 15px;
|
||||||
|
}
|
||||||
|
</style>
|
Loading…
Reference in a new issue