@spark-apps/quickpeek 1.0.1 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +200 -101
- package/dist/assets/qp.wm +0 -0
- package/dist/highlight.css +15 -0
- package/dist/qp.js +6143 -0
- package/package.json +64 -46
- package/dist/api-client.d.ts +0 -61
- package/dist/api-client.d.ts.map +0 -1
- package/dist/api-client.js +0 -180
- package/dist/api-client.js.map +0 -1
- package/dist/config.d.ts +0 -69
- package/dist/config.d.ts.map +0 -1
- package/dist/config.js +0 -43
- package/dist/config.js.map +0 -1
- package/dist/crawl.d.ts +0 -18
- package/dist/crawl.d.ts.map +0 -1
- package/dist/crawl.js +0 -175
- package/dist/crawl.js.map +0 -1
- package/dist/cursor.d.ts +0 -6
- package/dist/cursor.d.ts.map +0 -1
- package/dist/cursor.js +0 -6
- package/dist/cursor.js.map +0 -1
- package/dist/ffmpeg.d.ts +0 -50
- package/dist/ffmpeg.d.ts.map +0 -1
- package/dist/ffmpeg.js +0 -224
- package/dist/ffmpeg.js.map +0 -1
- package/dist/index.d.ts +0 -15
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js +0 -26
- package/dist/index.js.map +0 -1
- package/dist/prompts.d.ts +0 -13
- package/dist/prompts.d.ts.map +0 -1
- package/dist/prompts.js +0 -91
- package/dist/prompts.js.map +0 -1
- package/dist/styles.d.ts +0 -16
- package/dist/styles.d.ts.map +0 -1
- package/dist/styles.js +0 -66
- package/dist/styles.js.map +0 -1
- package/dist/tts.d.ts +0 -64
- package/dist/tts.d.ts.map +0 -1
- package/dist/tts.js +0 -236
- package/dist/tts.js.map +0 -1
- package/dist/utils.d.ts +0 -25
- package/dist/utils.d.ts.map +0 -1
- package/dist/utils.js +0 -106
- package/dist/utils.js.map +0 -1
- package/dist/voices.d.ts +0 -2
- package/dist/voices.d.ts.map +0 -1
- package/dist/voices.js +0 -73
- package/dist/voices.js.map +0 -1
- package/dist/watermark.d.ts +0 -27
- package/dist/watermark.d.ts.map +0 -1
- package/dist/watermark.js +0 -57
- package/dist/watermark.js.map +0 -1
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2024 Spark Apps
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,101 +1,200 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
```
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
1
|
+
[license-link]: ./LICENSE
|
|
2
|
+
[privacy-link]: ./PRIVACY.md
|
|
3
|
+
[discord-link]: https://discord.gg/5skXfKRytR
|
|
4
|
+
[stars-link]: ../../stargazers
|
|
5
|
+
[issues-link]: ../../issues
|
|
6
|
+
|
|
7
|
+
<div align="center">
|
|
8
|
+
|
|
9
|
+
<img src=imgs/logo.png>
|
|
10
|
+
|
|
11
|
+
**Demo videos for your web app with AI**
|
|
12
|
+
|
|
13
|
+
*Because Tutorial Videos are Overrated!*
|
|
14
|
+
|
|
15
|
+
[](https://www.npmjs.com/package/@spark-apps/quickpeek)
|
|
16
|
+
[][license-link]
|
|
17
|
+
[][discord-link]
|
|
18
|
+
[][stars-link]
|
|
19
|
+
|
|
20
|
+
</div>
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## Quick Start
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
npm install -g @spark-apps/quickpeek
|
|
28
|
+
qp localhost:3000
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
**Requirements:** [ffmpeg](https://ffmpeg.org/download.html), [Groq API key](https://console.groq.com/keys) (free)
|
|
32
|
+
|
|
33
|
+
## Features
|
|
34
|
+
|
|
35
|
+
| Feature | Description |
|
|
36
|
+
|---------|-------------|
|
|
37
|
+
| **AI Planning** | Groq AI analyzes your app and generates demo steps |
|
|
38
|
+
| **Script Mode** | Provide your own narration script, AI maps it to UI actions |
|
|
39
|
+
| **Capture Mode** | Record your own interactions → replayable plan.json |
|
|
40
|
+
| **Voice Over** | Free Edge TTS narration in 60+ languages |
|
|
41
|
+
| **Karaoke Captions** | Word-by-word highlighted subtitles |
|
|
42
|
+
| **Background Music** | Optional music with fade in/out |
|
|
43
|
+
| **Smart Zoom** | Per-step zoom for focused demos |
|
|
44
|
+
| **Chrome Extensions** | Record demos for Chrome extensions |
|
|
45
|
+
|
|
46
|
+
## Examples
|
|
47
|
+
|
|
48
|
+
### Basic — AI generates the plan
|
|
49
|
+
|
|
50
|
+
```bash
|
|
51
|
+
qp localhost:3000
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
### Script mode — you write the narration
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
qp localhost:3000 --script narration.txt
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
Script file format (one caption per line, `#` for comments):
|
|
61
|
+
|
|
62
|
+
```
|
|
63
|
+
# My app demo
|
|
64
|
+
We start on the dashboard — your main workspace.
|
|
65
|
+
Let's search for a customer by typing their name.
|
|
66
|
+
Click the result to open their profile.
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
### Capture mode — record your own interactions
|
|
70
|
+
|
|
71
|
+
```bash
|
|
72
|
+
qp capture localhost:3000
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
Browse the app freely, press Enter when done. QuickPeek converts your clicks, typing, and scrolls into a `plan.json` that can be replayed as a polished video.
|
|
76
|
+
|
|
77
|
+
### With options
|
|
78
|
+
|
|
79
|
+
```bash
|
|
80
|
+
qp localhost:3000 lang=es -d "A todo app for managing daily tasks"
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
### Chrome Extensions
|
|
84
|
+
|
|
85
|
+
Record demos for Chrome extensions using the `chrome:` prefix:
|
|
86
|
+
|
|
87
|
+
```bash
|
|
88
|
+
qp chrome:your-extension-id
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
QuickPeek will automatically:
|
|
92
|
+
1. Find the extension in your Chrome installation
|
|
93
|
+
2. Load and analyze the extension popup UI
|
|
94
|
+
3. Generate a demo plan with AI
|
|
95
|
+
|
|
96
|
+
The popup URL is detected from the extension's manifest.
|
|
97
|
+
|
|
98
|
+
| Option | Description |
|
|
99
|
+
|--------|-------------|
|
|
100
|
+
| `lang` | Voice language (en, es, ar, zh...) |
|
|
101
|
+
| `-d, --description` | App description to guide AI |
|
|
102
|
+
| `-s, --script` | Path to narration script file |
|
|
103
|
+
| `video.width/height` | Resolution (default: 1080x1920) |
|
|
104
|
+
| `video.quality` | Quality 0-1 (default: 0.5) |
|
|
105
|
+
| `music.path` | Background music file |
|
|
106
|
+
| `music.volume` | Music volume 0-1 (default: 0.3) |
|
|
107
|
+
| `output.dir` | Output directory (default: ./demo) |
|
|
108
|
+
|
|
109
|
+
Config is auto-generated on first run. Edit `quickpeek.config.json` to customize.
|
|
110
|
+
|
|
111
|
+
<details>
|
|
112
|
+
<summary><strong>Supported Languages</strong></summary>
|
|
113
|
+
|
|
114
|
+
| Code | Language | Code | Language |
|
|
115
|
+
|------|----------|------|----------|
|
|
116
|
+
| `en` | English | `ar` | Arabic |
|
|
117
|
+
| `es` | Spanish | `fr` | French |
|
|
118
|
+
| `de` | German | `zh` | Chinese |
|
|
119
|
+
| `ja` | Japanese | `ko` | Korean |
|
|
120
|
+
| `pt` | Portuguese | `hi` | Hindi |
|
|
121
|
+
| `it` | Italian | `ru` | Russian |
|
|
122
|
+
|
|
123
|
+
See `src/voices.ts` for all 60+ supported languages.
|
|
124
|
+
|
|
125
|
+
</details>
|
|
126
|
+
|
|
127
|
+
<details>
|
|
128
|
+
<summary><strong>Caption Style</strong></summary>
|
|
129
|
+
|
|
130
|
+
Edit `captions.css` (auto-generated) to customize:
|
|
131
|
+
|
|
132
|
+

|
|
133
|
+
|
|
134
|
+
```css
|
|
135
|
+
.caption {
|
|
136
|
+
font-family: Arial, sans-serif;
|
|
137
|
+
-webkit-text-stroke: 3px #000000;
|
|
138
|
+
}
|
|
139
|
+
.caption .regular {
|
|
140
|
+
font-size: 56px;
|
|
141
|
+
color: #FFFFFF;
|
|
142
|
+
}
|
|
143
|
+
.caption .highlight {
|
|
144
|
+
font-size: 64px;
|
|
145
|
+
color: #FFFF00;
|
|
146
|
+
}
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
</details>
|
|
150
|
+
|
|
151
|
+
## Plan Actions
|
|
152
|
+
|
|
153
|
+
Edit `demo/plan.json` to customize your demo. Each step uses one of these actions:
|
|
154
|
+
|
|
155
|
+
| Action | Target | Value | Description |
|
|
156
|
+
|--------|--------|-------|-------------|
|
|
157
|
+
| `wait` | - | - | Pause for narration (intro/outro) |
|
|
158
|
+
| `click` | `"button text"` | - | Click button/link |
|
|
159
|
+
| `click-N` | `"button text"` | - | Click N times (e.g., `click-2`, `click-3`) |
|
|
160
|
+
| `type` | `input[name="field"]` | `"text to type"` | Type into input field |
|
|
161
|
+
| `upload` | `input[type="file"]` | `"path/to/file"` | Upload file to form |
|
|
162
|
+
| `select` | `select[name="field"]` | `"option text"` | Select dropdown option |
|
|
163
|
+
| `check` | `input[type="checkbox"]` | - | Toggle checkbox |
|
|
164
|
+
| `drag` | `input[type="range"]` | `"0"`-`"100"` | Drag slider to value |
|
|
165
|
+
| `drag` | `canvas` | `"around"` | Full 360° rotation (returns to start) |
|
|
166
|
+
| `drag` | `canvas` | `"rotate"` | Rotate ~270° (stays at new angle) |
|
|
167
|
+
| `drag` | `canvas` | `"rotate:90"` | Rotate specific angle (circular) |
|
|
168
|
+
| `drag` | `canvas` | `"rotate:x-90"` | Rotate on X axis (horizontal drag) |
|
|
169
|
+
| `drag` | `canvas` | `"rotate:y45"` | Rotate on Y axis (vertical drag) |
|
|
170
|
+
| `drag` | - | `"left"` `"right"` `"up"` `"down"` | Directional drag |
|
|
171
|
+
| `scroll` | - | `"up"` `"down"` `"bottom"` | Scroll page |
|
|
172
|
+
| `scroll` | - | `"-10"` to `"10"` | Zoom camera (negative=out, positive=in) |
|
|
173
|
+
| `media` | `"scale"` or `"center"` | `"path/to/file"` | Display image/video fullscreen |
|
|
174
|
+
| `showDownload` | - | - | Show the last downloaded file |
|
|
175
|
+
|
|
176
|
+
**Target shortcuts:** For buttons and links, use simplified text like `"download"` or `"extract frame"` instead of CSS selectors.
|
|
177
|
+
|
|
178
|
+
## Output
|
|
179
|
+
|
|
180
|
+
| File | Description |
|
|
181
|
+
|------|-------------|
|
|
182
|
+
| `demo/demo.mp4` | Final video |
|
|
183
|
+
| `demo/plan.json` | Editable script (re-run to apply changes) |
|
|
184
|
+
|
|
185
|
+
## 🌱 Support & Contributions
|
|
186
|
+
|
|
187
|
+
⭐ **Star the repo** & I power up like Mario 🍄
|
|
188
|
+
☕ **Devs run on coffee** - [Buy me one?][coffee-link]
|
|
189
|
+
💖 **Sponsor** [Your support][stars-link] helps maintain and improve the tool<br>
|
|
190
|
+
💰 **Crypto tips welcome** - [Tip in crypto](https://tip.md/muammar-yacoob)
|
|
191
|
+
🤝 **Contributions are welcome** - [🍴 Fork][fork-link], improve, PR!
|
|
192
|
+
🎥 **Need help?** <img src="https://img.icons8.com/color/20/youtube-play.png" alt="YouTube" width="20" height="20" style="vertical-align: middle;"> [Setup Tutorial][vid-link] • <img src="https://img.icons8.com/color/20/discord--v2.png" alt="Discord" width="20" height="20" style="vertical-align: middle;"> [Join Discord][discord-link]
|
|
193
|
+
|
|
194
|
+
<div align="center">
|
|
195
|
+
|
|
196
|
+
---
|
|
197
|
+
|
|
198
|
+
MIT License - Made with ☕ by [Spark Apps](https://github.com/muammar-yacoob)
|
|
199
|
+
|
|
200
|
+
</div>
|
|
Binary file
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
#qp-highlight-overlay {
|
|
2
|
+
position: fixed;
|
|
3
|
+
inset: 0;
|
|
4
|
+
background: rgba(0, 0, 0, 0.5);
|
|
5
|
+
z-index: 999998;
|
|
6
|
+
pointer-events: none;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
[data-qp-highlight] {
|
|
10
|
+
position: relative !important;
|
|
11
|
+
z-index: 999999 !important;
|
|
12
|
+
outline: 3px solid #ffd700 !important;
|
|
13
|
+
outline-offset: 2px !important;
|
|
14
|
+
border-radius: 8px !important;
|
|
15
|
+
}
|