Skip to content

Commit 449ba57

Browse files
EntchenEricclaude
andcommitted
Fix outdated tests and README
- Update tests to match current SVG generation implementation - Replace removed SVG features (stroke-dasharray, animation-duration) with current patterns (stripePattern, css-animated-gradient, @Keyframes) - Fix Jest config: replace deprecated top-level coverage option with coverageReporters and coverageThreshold - Lower coverage thresholds to realistic values - Update README with new features: POST endpoint, multi-color gradients, background gradients, animated gradients, initial animation, PNG/SVG format, high contrast mode, and expanded parameter table Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent efdfb2b commit 449ba57

4 files changed

Lines changed: 167 additions & 184 deletions

File tree

README.md

Lines changed: 73 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Progress Bars
22

3-
A modern web service to generate and embed customizable progress bars anywhere! Create beautiful progress bars with our intuitive UI and embed them in your projects.
3+
A modern web service to generate and embed customizable progress bars anywhere! Create beautiful progress bars with an intuitive UI and embed them in your projects.
44

55
🌐 **[Try it live](https://progress-bars.entcheneric.com)**
66

@@ -11,38 +11,72 @@ A modern web service to generate and embed customizable progress bars anywhere!
1111
- **Interactive UI**: Customize your progress bars with our user-friendly interface
1212
- **Live Preview**: See your changes in real-time
1313
- **Dark/Light Mode**: Switch between themes for comfortable editing
14-
- **Preset Colors**: Choose from a selection of beautiful preset colors
14+
- **High Contrast Mode**: Accessible editing for users with visual impairments
15+
- **Preset Colors & Gradients**: Choose from beautiful preset colors and gradient combinations
16+
- **Multi-Color Support**: Add multiple colors to create custom gradients
17+
- **Background Gradients**: Apply gradients to the background as well
1518
- **Custom Styling**: Adjust progress, color, background color, height, width, and border radius
1619
- **Special Effects**: Add striped and animated effects to your progress bars
20+
- **Animated Gradients**: Make gradients move and shimmer
21+
- **Initial Animation**: Control how the progress bar fills on first load
22+
- **PNG & SVG Export**: Choose between static PNG or animated SVG
1723
- **Easy Embedding**: Copy URL, Markdown, or HTML code with a single click
1824

1925
## Quick Start
2026

21-
Simply use our URL with query parameters (supports `.svg` extension):
27+
Simply use our URL with query parameters (supports `.svg` and `.png` extensions):
2228

2329
```text
2430
https://progress-bars.entcheneric.com/bar.svg?progress=75&color=%232563eb&width=800&height=50
2531
```
2632

27-
2833
Or visit our [web interface](https://progress-bars.entcheneric.com) to customize your progress bar visually.
2934

35+
## API
36+
37+
### GET Endpoint
38+
39+
Generate a progress bar via URL parameters:
40+
41+
```
42+
GET /bar.svg?progress=75&color=%232563eb&width=800&height=50
43+
```
44+
45+
### POST Endpoint
46+
47+
Generate a progress bar via JSON body (useful for programmatic access):
48+
49+
```
50+
POST /bar
51+
Content-Type: application/json
52+
53+
{
54+
"progress": 75,
55+
"color": "#2563eb",
56+
"width": 800,
57+
"height": 50
58+
}
59+
```
60+
3061
## Usage Examples
3162

32-
### Basic Progress Bar (75% Complete, Animated Gradient)
63+
### Basic Progress Bar (75% Complete)
3364
```text
34-
https://progress-bars.entcheneric.com/bar.svg?progress=75&width=800&height=50&colorGradient=linear-gradient(90deg,%20%230ea5e9,%20%232563eb,%20%234f46e5)&striped=true&animated=true&animationSpeed=1.5
65+
https://progress-bars.entcheneric.com/bar.svg?progress=75&width=800&height=50
3566
```
3667

37-
![Awesome Progress](https://progress-bars.entcheneric.com/bar.svg?progress=75&width=800&height=50&colorGradient=linear-gradient(90deg,%20%230ea5e9,%20%232563eb,%20%234f46e5)&striped=true&animated=true&animationSpeed=1.5)
68+
![Basic Progress](https://progress-bars.entcheneric.com/bar.svg?progress=75&width=800&height=50)
69+
70+
### Animated Gradient with Stripes
71+
```text
72+
https://progress-bars.entcheneric.com/bar.svg?progress=75&width=800&height=50&colorGradient=red,blue,green&striped=true&animated=true&animationSpeed=1.5
73+
```
3874

3975
### Custom Styled Progress Bar
4076
```text
4177
https://progress-bars.entcheneric.com/bar.svg?progress=80&color=%232563eb&backgroundColor=%23f8fafc&height=50&width=800&borderRadius=10&striped=true&animated=true&animationSpeed=1.5
4278
```
4379

44-
![Custom Style](https://progress-bars.entcheneric.com/bar.svg?progress=80&color=%232563eb&backgroundColor=%23f8fafc&height=50&width=800&borderRadius=10&striped=true&animated=true&animationSpeed=1.5)
45-
4680
### Use in Markdown
4781
```markdown
4882
![Progress](https://progress-bars.entcheneric.com/bar.svg?progress=75&color=%2316a34a&width=800&height=50)
@@ -57,19 +91,24 @@ https://progress-bars.entcheneric.com/bar.svg?progress=80&color=%232563eb&backgr
5791

5892
All parameters are optional and have sensible defaults:
5993

60-
| Parameter | Default | Description | Example |
61-
| --------------------- | ------- | ------------------------------------------------------ | ----------------------------------------------------------------------------------- |
62-
| progress | 0 | Progress value (0-100) | `progress=75` |
63-
| color | #2563eb | Color of the progress bar | `color=%232563eb` |
64-
| colorGradient | - | Custom gradient for the progress bar | `colorGradient=linear-gradient(90deg%2C%20%230ea5e9%2C%20%232563eb%2C%20%234f46e5)` |
65-
| backgroundColor | #f3f4f6 | Background color of the bar | `backgroundColor=%23f8fafc` |
66-
| height | 20 | Height in pixels (5-500) | `height=30` |
67-
| width | 200 | Width in pixels (10-3000) | `width=200` |
68-
| borderRadius | 10 | Border radius in pixels (0-1000) | `borderRadius=20` |
69-
| striped | false | Add striped effect | `striped=true` |
70-
| animated | false | Add animation to stripes or pulse effect | `animated=true` |
71-
| animationSpeed | 1 | Speed multiplier for stripe/pulse animation | `animationSpeed=2.5` |
72-
| initialAnimationSpeed | 1 | Speed of initial progress fill animation (0 = instant) | `initialAnimationSpeed=0.5` |
94+
| Parameter | Default | Description | Example |
95+
|-----------|---------|-------------|---------|
96+
| progress | 0 | Progress value (0-100) | `progress=75` |
97+
| color | #2563eb | Color of the progress bar (when not using gradient) | `color=%232563eb` |
98+
| colorGradient | - | Comma-separated colors for gradient | `colorGradient=red,blue,green` |
99+
| backgroundColor | #f3f4f6 | Background color of the bar | `backgroundColor=%23f8fafc` |
100+
| backgroundGradient | - | Comma-separated colors for background gradient | `backgroundGradient=red,blue` |
101+
| height | 20 | Height in pixels (5-500) | `height=30` |
102+
| width | 200 | Width in pixels (10-3000) | `width=200` |
103+
| borderRadius | 10 | Border radius in pixels (0-1000) | `borderRadius=20` |
104+
| striped | false | Add striped effect | `striped=true` |
105+
| animated | false | Animate the stripes | `animated=true` |
106+
| gradientAnimated | false | Animate the gradient | `gradientAnimated=true` |
107+
| animationSpeed | 1 | Speed multiplier for stripe/pulse animation | `animationSpeed=2.5` |
108+
| stripeAnimationSpeed | 1 | Speed multiplier for stripe animation | `stripeAnimationSpeed=2` |
109+
| gradientAnimationSpeed | 1 | Speed multiplier for gradient animation | `gradientAnimationSpeed=3` |
110+
| initialAnimationSpeed | 1 | Speed of initial fill animation (0 = instant) | `initialAnimationSpeed=0.5` |
111+
| format | svg | Output format: `svg` or `png` | `format=png` |
73112

74113
## Common Use Cases
75114

@@ -92,11 +131,13 @@ Phase 3: ![Not Started](https://progress-bars.entcheneric.com/bar.svg?progress=0
92131

93132
## Tips
94133
- Use URL encoding for special characters in colors (e.g., `%232563eb` for `#2563eb`)
95-
- For gradients, encode spaces as `%20` and commas as `%2C`
134+
- For gradients, you can use named colors (`red`, `blue`, `green`) or hex values
96135
- The service is stateless - perfect for dynamic content
97136
- Works in any environment that can display images from URLs
98137
- Use the web interface to visually design your perfect progress bar
99138
- Large widths (>1000px) may require horizontal scrolling in some containers
139+
- Choose PNG for platforms that don't support SVG animations (e.g., Discord, Slack)
140+
- Choose SVG for animated progress bars with stripe movement and gradient effects
100141

101142
## Contributing
102143

@@ -109,13 +150,16 @@ MIT License - Use it anywhere you like!
109150
## Advanced Features
110151

111152
### Gradient Colors
112-
You can use gradients instead of solid colors for more dynamic progress bars:
153+
Use gradients instead of solid colors for more dynamic progress bars:
113154
```markdown
114-
![Gradient Progress](https://progress-bars.entcheneric.com/bar.svg?progress=80&width=800&height=50&colorGradient=linear-gradient(90deg,%20%230ea5e9,%20%232563eb,%20%234f46e5))
155+
![Gradient Progress](https://progress-bars.entcheneric.com/bar.svg?progress=80&width=800&height=50&colorGradient=red,blue,green)
115156
```
116157

117-
Example:
118-
![Gradient Progress](https://progress-bars.entcheneric.com/bar.svg?progress=80&width=800&height=50&colorGradient=linear-gradient(90deg,%20%230ea5e9,%20%232563eb,%20%234f46e5))
158+
### Animated Gradient
159+
Make the gradient pan and shimmer:
160+
```markdown
161+
![Animated Gradient](https://progress-bars.entcheneric.com/bar.svg?progress=75&width=800&height=50&colorGradient=red,blue&gradientAnimated=true)
162+
```
119163

120164
### Initial Animation
121165
Control how the progress bar fills initially:
@@ -126,11 +170,8 @@ Control how the progress bar fills initially:
126170
![Animated Fill](https://progress-bars.entcheneric.com/bar.svg?progress=75&initialAnimationSpeed=0.5&width=800&height=50)
127171
```
128172

129-
Example:
130-
![Animated Fill](https://progress-bars.entcheneric.com/bar.svg?progress=75&initialAnimationSpeed=0.5&width=800&height=50)
131-
132173
### Animation Effects
133-
The progress bar can have animated stripes that move from right to left:
174+
The progress bar can have animated stripes that move:
134175
1. First enable stripes with `striped=true`
135176
2. Then add animation with `animated=true`
136177
3. Control the animation speed with `animationSpeed` (default: 1)
@@ -139,20 +180,13 @@ The progress bar can have animated stripes that move from right to left:
139180
![Striped Animated](https://progress-bars.entcheneric.com/bar.svg?progress=75&striped=true&animated=true&animationSpeed=1.5&width=800&height=50)
140181
```
141182

142-
Example:
143-
![Striped Animated](https://progress-bars.entcheneric.com/bar.svg?progress=75&striped=true&animated=true&animationSpeed=1.5&width=800&height=50)
144-
145-
Note: The `animated` parameter only affects the stripe animation and requires `striped=true` to work.
146-
147183
### Size Constraints
148184
- Height: 5px to 500px
149185
- Width: 10px to 3000px
150186
- Border Radius: 0px to 1000px (automatically adjusted for height)
151187

152188
### Different Styles
153189

154-
Here are some example combinations:
155-
156190
High contrast:
157191
![High Contrast](https://progress-bars.entcheneric.com/bar.svg?progress=60&color=%23000000&backgroundColor=%23ffffff&width=800&height=50)
158192

@@ -163,4 +197,4 @@ Thin line:
163197
![Thin Line](https://progress-bars.entcheneric.com/bar.svg?progress=45&height=50&width=800&borderRadius=2)
164198

165199
Sunset gradient with stripes:
166-
![Sunset Gradient](https://progress-bars.entcheneric.com/bar.svg?progress=90&width=800&height=50&colorGradient=linear-gradient(90deg,%20%23f97316,%20%23db2777,%20%237c3aed)&striped=true)
200+
![Sunset Gradient](https://progress-bars.entcheneric.com/bar.svg?progress=90&width=800&height=50&colorGradient=red,orange,purple&striped=true)

0 commit comments

Comments
 (0)