clipwise 0.5.2 → 0.6.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/README.ko.md CHANGED
@@ -80,6 +80,37 @@ const frames = await renderer.composeAll(session.frames);
80
80
  const mp4 = await encodeMp4(frames, scenario.output);
81
81
  ```
82
82
 
83
+ ## Claude Code 스킬
84
+
85
+ Clipwise에는 [Claude Code](https://claude.com/claude-code) 스킬이 내장되어 있습니다. 설치 후 Claude Code에서 `/clipwise`를 입력하면 자연어로 YAML 시나리오 생성, 검증, 녹화까지 한 번에 할 수 있습니다.
86
+
87
+ ### 스킬 설치
88
+
89
+ ```bash
90
+ npx clipwise install-skill
91
+ ```
92
+
93
+ `.claude/skills/clipwise.md`에 스킬 파일이 복사됩니다 (`.claude/` 디렉토리가 있으면 프로젝트 레벨, 없으면 `~/.claude/skills/`에 설치).
94
+
95
+ ### 사용법
96
+
97
+ Claude Code 세션에서:
98
+
99
+ ```
100
+ /clipwise
101
+ > http://localhost:3000 대시보드 데모 녹화해줘
102
+ — 로그인 버튼 클릭, 이메일/비밀번호 입력, 분석 페이지 이동
103
+ ```
104
+
105
+ Claude가 자동으로:
106
+ 1. `clipwise.yaml` 시나리오 생성
107
+ 2. `npx clipwise validate`로 검증
108
+ 3. `npx clipwise record`로 MP4 녹화
109
+
110
+ ### 업데이트
111
+
112
+ clipwise 업그레이드 후 `npx clipwise install-skill`을 다시 실행하면 최신 스킬로 업데이트됩니다.
113
+
83
114
  ## YAML 시나리오 형식
84
115
 
85
116
  시나리오는 4개 섹션으로 구성됩니다: 메타데이터, 이펙트, 출력, 스텝.
@@ -109,7 +140,10 @@ steps:
109
140
  url: "https://example.com"
110
141
  captureDelay: 200 # 액션 후 대기(ms)
111
142
  holdDuration: 800 # 결과 화면 유지(ms)
112
- transition: none # none | fade
143
+ transition: none # none | fade | slide-left | slide-up | blur
144
+ effects: # 스텝별 이펙트 오버라이드 (선택)
145
+ zoom:
146
+ enabled: false # 이 스텝에서만 줌 비활성화
113
147
  ```
114
148
 
115
149
  ### 액션
@@ -189,20 +223,26 @@ steps:
189
223
  ```yaml
190
224
  zoom:
191
225
  enabled: true
192
- intensity: moderate # subtle | light | moderate | strong | dramatic
226
+ intensity: light # subtle | light | moderate | strong | dramatic
193
227
  # 1.15x | 1.25x | 1.35x | 1.5x | 1.8x
194
- # scale: 1.35 # 숫자로 직접 지정할 때 사용 (intensity 미설정 시)
195
- duration: 500 # 애니메이션 ms
228
+ # scale: 1.25 # 숫자로 직접 지정할 때 사용 (intensity 미설정 시)
229
+ duration: 800 # 애니메이션 ms
230
+ autoZoom:
231
+ followCursor: true # 커서 위치를 따라 뷰포트 패닝
232
+ transitionDuration: 300
233
+ padding: 200
196
234
  ```
197
235
 
198
236
  | 강도 | 스케일 | 권장 사용처 |
199
237
  |------|--------|------------|
200
238
  | `subtle` | 1.15× | 정보 밀도 높은 UI, 큰 화면 |
201
- | `light` | 1.25× | Loom 스타일 부드러운 줌 (권장) |
202
- | `moderate` | 1.35× | 균형잡힌 기본값 (Camtasia 수준) |
239
+ | `light` | 1.25× | Loom 스타일 부드러운 줌 **(기본값)** |
240
+ | `moderate` | 1.35× | 균형잡힌 수준 (Camtasia 범위) |
203
241
  | `strong` | 1.5× | 명확한 포커스 |
204
242
  | `dramatic` | 1.8× | 최대 강조, 단순 UI 전용 |
205
243
 
244
+ **스마트 카메라**: 스크롤 중에는 줌이 자동 억제되어 어지러운 움직임을 방지합니다. `followCursor` 활성화 시 초점이 클릭 위치뿐 아니라 커서 위치를 부드럽게 따라갑니다.
245
+
206
246
  ### 커서
207
247
 
208
248
  커스텀 커서 + 클릭 리플 + 트레일 + 하이라이트 + 속도 조절.
@@ -211,7 +251,7 @@ zoom:
211
251
  cursor:
212
252
  enabled: true
213
253
  size: 20
214
- speed: "fast" # fast (~72ms) | normal (~144ms) | slow (~288ms)
254
+ speed: "normal" # fast (~72ms) | normal (~144ms) | slow (~288ms)
215
255
  clickEffect: true
216
256
  trail: true
217
257
  highlight: true
@@ -282,24 +322,81 @@ watermark:
282
322
  ```yaml
283
323
  speedRamp:
284
324
  enabled: true
285
- idleSpeed: 3.0
325
+ idleSpeed: 2.0 # 유휴 프레임 스킵 배수 (기본: 2.0)
286
326
  actionSpeed: 0.8
287
327
  ```
288
328
 
329
+ ### 트랜지션
330
+
331
+ 스텝 간 전환 효과를 지정합니다.
332
+
333
+ ```yaml
334
+ steps:
335
+ - name: "스텝 1"
336
+ transition: fade # none | fade | slide-left | slide-up | blur
337
+ actions: [...]
338
+ ```
339
+
340
+ | 트랜지션 | 설명 |
341
+ |----------|------|
342
+ | `none` | 하드 컷 (기본값) |
343
+ | `fade` | 크로스 디졸브 |
344
+ | `slide-left` | 나가는 프레임 왼쪽 슬라이드, 들어오는 프레임 오른쪽에서 진입 |
345
+ | `slide-up` | 나가는 프레임 위로 슬라이드, 들어오는 프레임 아래에서 진입 |
346
+ | `blur` | 나가는 프레임 블러 처리 + 크로스페이드 |
347
+
348
+ ### 스텝별 이펙트 오버라이드
349
+
350
+ 글로벌 이펙트를 스텝 단위로 오버라이드할 수 있습니다. 설정하지 않은 속성은 글로벌 설정을 상속합니다.
351
+
352
+ ```yaml
353
+ effects:
354
+ zoom:
355
+ enabled: true
356
+ intensity: light
357
+
358
+ steps:
359
+ - name: "개요"
360
+ effects:
361
+ zoom:
362
+ enabled: false # 이 스텝에서만 줌 비활성화
363
+ actions: [...]
364
+
365
+ - name: "상세 보기"
366
+ effects:
367
+ zoom:
368
+ intensity: strong # 이 스텝에서만 강한 줌
369
+ actions: [...]
370
+ ```
371
+
372
+ ### 오디오 내레이션
373
+
374
+ 출력 MP4에 오디오 파일(MP3, WAV 등)을 첨부합니다.
375
+
376
+ ```yaml
377
+ audio:
378
+ file: "./narration.mp3"
379
+ volume: 1.0 # 0.0 - 2.0 (기본: 1.0)
380
+ fadeIn: 0 # 페이드인 시간(초)
381
+ fadeOut: 0 # 페이드아웃 시간(초)
382
+ ```
383
+
289
384
  ## 성능
290
385
 
291
386
  **Apple M1 Max (10코어)** 기준 — Pulse Dashboard 데모, 44초 @ 30fps, 1280×800:
292
387
 
293
- | 단계 | v0.3.0 | v0.4.0 | v0.5.0 |
294
- |------|--------|--------|--------|
295
- | 녹화 | 30.8 s | 31.1 s | 31.1 s |
296
- | 합성 + 인코딩 | 97.2 s | 60.6 s | 60.6 s |
297
- | **전체** | **127.9 s** | **91.7 s** | **91.7 s** |
298
- | 캡처 프레임 수 | 1,303 | 902 | 902 |
388
+ | 단계 | v0.3.0 | v0.4.0 | v0.5.0 | v0.6.0 |
389
+ |------|--------|--------|--------|--------|
390
+ | 녹화 | 30.8 s | 31.1 s | 31.1 s | 31.1 s |
391
+ | 합성 + 인코딩 | 97.2 s | 60.6 s | 60.6 s | 60.6 s |
392
+ | **전체** | **127.9 s** | **91.7 s** | **91.7 s** | **91.7 s** |
393
+ | 캡처 프레임 수 | 1,303 | 902 | 902 | 902 |
299
394
 
300
395
  v0.4.0 주요 최적화: 동시 스트리밍 파이프라인, 정적 프레임 중복 제거(~33% 건너뜀), 워커별 StaticLayers 캐시, raw RGBA 버퍼 파이프라인.
301
396
 
302
- v0.5.0은 **녹화 품질** 개선에 집중: CSS 트랜지션 억제로 커서 부드러운 이동, 줌 강도 프리셋, 멀티세션 키스트로크 HUD.
397
+ v0.5.0은 **녹화 품질** 개선에 집중: 부드러운 커서, 줌 강도 프리셋, 멀티세션 키스트로크 HUD.
398
+
399
+ v0.6.0은 **컨벤션 정렬 & 표현력** 강화: 부드러운 기본값 (light 줌, normal 커서 속도), 스텝별 이펙트 오버라이드, 새 트랜지션 (slide, blur), 오디오 내레이션, 스마트 카메라 (스크롤 줌 억제 + 커서 추적 포컬 포인트).
303
400
 
304
401
  ## 출력 압축
305
402
 
@@ -337,37 +434,6 @@ VideoToolbox는 런타임에 자동 감지되며, 사용 불가 시 `libx264`로
337
434
 
338
435
  [PROMPTS.md](./PROMPTS.md)에 바로 사용할 수 있는 AI 프롬프트 템플릿이 있습니다. ChatGPT나 Claude에 복붙하고 내 사이트 URL만 넣으면 YAML 시나리오를 생성해줍니다.
339
436
 
340
- ## Claude Code 스킬
341
-
342
- Clipwise에는 [Claude Code](https://claude.com/claude-code) 스킬이 내장되어 있습니다. 설치 후 Claude Code에서 `/clipwise`를 입력하면 자연어로 YAML 시나리오 생성, 검증, 녹화까지 한 번에 할 수 있습니다.
343
-
344
- ### 스킬 설치
345
-
346
- ```bash
347
- npx clipwise install-skill
348
- ```
349
-
350
- `.claude/skills/clipwise.md`에 스킬 파일이 복사됩니다 (`.claude/` 디렉토리가 있으면 프로젝트 레벨, 없으면 `~/.claude/skills/`에 설치).
351
-
352
- ### 사용법
353
-
354
- Claude Code 세션에서:
355
-
356
- ```
357
- /clipwise
358
- > http://localhost:3000 대시보드 데모 녹화해줘
359
- — 로그인 버튼 클릭, 이메일/비밀번호 입력, 분석 페이지 이동
360
- ```
361
-
362
- Claude가 자동으로:
363
- 1. `clipwise.yaml` 시나리오 생성
364
- 2. `npx clipwise validate`로 검증
365
- 3. `npx clipwise record`로 MP4 녹화
366
-
367
- ### 업데이트
368
-
369
- clipwise 업그레이드 후 `npx clipwise install-skill`을 다시 실행하면 최신 스킬로 업데이트됩니다.
370
-
371
437
  ## GitHub Pages
372
438
 
373
439
  `docs/` 폴더에 문서 사이트와 라이브 데모 대시보드가 포함되어 있습니다:
package/README.md CHANGED
@@ -80,6 +80,37 @@ const frames = await renderer.composeAll(session.frames);
80
80
  const mp4 = await encodeMp4(frames, scenario.output);
81
81
  ```
82
82
 
83
+ ## Claude Code Skill
84
+
85
+ Clipwise ships a built-in [Claude Code](https://claude.com/claude-code) skill. Once installed, type `/clipwise` in Claude Code to generate YAML scenarios, validate, and record — all through natural language.
86
+
87
+ ### Install the skill
88
+
89
+ ```bash
90
+ npx clipwise install-skill
91
+ ```
92
+
93
+ This copies the skill file to `.claude/skills/clipwise.md` (project-level if `.claude/` exists, otherwise `~/.claude/skills/`).
94
+
95
+ ### Usage
96
+
97
+ In any Claude Code session:
98
+
99
+ ```
100
+ /clipwise
101
+ > Record a demo of my dashboard at http://localhost:3000
102
+ — click the login button, type credentials, navigate to analytics
103
+ ```
104
+
105
+ Claude will:
106
+ 1. Generate a complete `clipwise.yaml` scenario
107
+ 2. Run `npx clipwise validate` to check for errors
108
+ 3. Run `npx clipwise record` to produce the MP4
109
+
110
+ ### Update
111
+
112
+ Re-run `npx clipwise install-skill` after upgrading clipwise to get the latest skill.
113
+
83
114
  ## YAML Scenario Format
84
115
 
85
116
  A scenario has 4 sections: metadata, effects, output, and steps.
@@ -109,7 +140,10 @@ steps:
109
140
  url: "https://example.com"
110
141
  captureDelay: 200 # ms to wait after actions
111
142
  holdDuration: 800 # ms to hold on result
112
- transition: none # none | fade
143
+ transition: none # none | fade | slide-left | slide-up | blur
144
+ effects: # Per-step effects override (optional)
145
+ zoom:
146
+ enabled: false # Disable zoom for this step only
113
147
  ```
114
148
 
115
149
  ### Actions
@@ -189,12 +223,12 @@ Adaptive zoom follows cursor and zooms in on click targets.
189
223
  ```yaml
190
224
  zoom:
191
225
  enabled: true
192
- intensity: moderate # subtle | light | moderate | strong | dramatic
226
+ intensity: light # subtle | light | moderate | strong | dramatic
193
227
  # 1.15x | 1.25x | 1.35x | 1.5x | 1.8x
194
- # scale: 1.35 # Override with a numeric value instead of intensity
195
- duration: 500 # Zoom animation ms
228
+ # scale: 1.25 # Override with a numeric value instead of intensity
229
+ duration: 800 # Zoom animation ms
196
230
  autoZoom:
197
- followCursor: true
231
+ followCursor: true # Viewport pans to follow cursor position
198
232
  transitionDuration: 300
199
233
  padding: 200
200
234
  ```
@@ -202,11 +236,13 @@ zoom:
202
236
  | Intensity | Scale | Best for |
203
237
  |-----------|-------|----------|
204
238
  | `subtle` | 1.15× | Dense UIs, large viewports |
205
- | `light` | 1.25× | Loom-style gentle pull-in (recommended) |
206
- | `moderate` | 1.35× | Balanced default — Camtasia range |
239
+ | `light` | 1.25× | Loom-style gentle pull-in **(default)** |
240
+ | `moderate` | 1.35× | Balanced — Camtasia range |
207
241
  | `strong` | 1.5× | Clear focus, some context sacrificed |
208
242
  | `dramatic` | 1.8× | Maximum emphasis, sparse UIs only |
209
243
 
244
+ **Smart camera**: Zoom is automatically suppressed during scroll actions to avoid disorienting motion. When `followCursor` is enabled, the focal point smoothly pans to follow cursor position (not just click targets).
245
+
210
246
  ### Cursor
211
247
 
212
248
  Custom cursor with click ripple, trail, glow highlight, and speed control.
@@ -215,7 +251,7 @@ Custom cursor with click ripple, trail, glow highlight, and speed control.
215
251
  cursor:
216
252
  enabled: true
217
253
  size: 20
218
- speed: "fast" # fast (~72ms) | normal (~144ms) | slow (~288ms)
254
+ speed: "normal" # fast (~72ms) | normal (~144ms) | slow (~288ms)
219
255
  clickEffect: true
220
256
  clickColor: "rgba(59, 130, 246, 0.3)"
221
257
  trail: true
@@ -289,24 +325,81 @@ Automatically slows down near clicks and speeds up idle sections.
289
325
  ```yaml
290
326
  speedRamp:
291
327
  enabled: true
292
- idleSpeed: 3.0 # Skip factor for idle frames
328
+ idleSpeed: 2.0 # Skip factor for idle frames (default: 2.0)
293
329
  actionSpeed: 0.8 # Slow factor near clicks
294
330
  ```
295
331
 
332
+ ### Transitions
333
+
334
+ Control how steps transition to each other.
335
+
336
+ ```yaml
337
+ steps:
338
+ - name: "Step 1"
339
+ transition: fade # none | fade | slide-left | slide-up | blur
340
+ actions: [...]
341
+ ```
342
+
343
+ | Transition | Description |
344
+ |------------|-------------|
345
+ | `none` | Hard cut (default) |
346
+ | `fade` | Cross-dissolve between steps |
347
+ | `slide-left` | Outgoing frame slides left, incoming slides in from right |
348
+ | `slide-up` | Outgoing frame slides up, incoming slides in from bottom |
349
+ | `blur` | Outgoing frame blurs out while cross-fading to incoming |
350
+
351
+ ### Per-Step Effects Override
352
+
353
+ Override global effects on a per-step basis. Any effect property can be overridden — unset properties inherit from the global config.
354
+
355
+ ```yaml
356
+ effects:
357
+ zoom:
358
+ enabled: true
359
+ intensity: light
360
+
361
+ steps:
362
+ - name: "Overview"
363
+ effects:
364
+ zoom:
365
+ enabled: false # No zoom for this step
366
+ actions: [...]
367
+
368
+ - name: "Detail view"
369
+ effects:
370
+ zoom:
371
+ intensity: strong # Extra zoom for this step only
372
+ actions: [...]
373
+ ```
374
+
375
+ ### Audio Narration
376
+
377
+ Attach an audio file (MP3, WAV, etc.) to the output MP4.
378
+
379
+ ```yaml
380
+ audio:
381
+ file: "./narration.mp3"
382
+ volume: 1.0 # 0.0 - 2.0 (default: 1.0)
383
+ fadeIn: 0 # Fade-in duration in seconds
384
+ fadeOut: 0 # Fade-out duration in seconds
385
+ ```
386
+
296
387
  ## Performance
297
388
 
298
389
  Measured on **Apple M1 Max (10 cores)** — Pulse Dashboard demo, 44s @ 30fps, 1280×800:
299
390
 
300
- | Stage | v0.3.0 | v0.4.0 | v0.5.0 |
301
- |-------|--------|--------|--------|
302
- | Recording | 30.8 s | 31.1 s | 31.1 s |
303
- | Compose + Encode | 97.2 s | 60.6 s | 60.6 s |
304
- | **Total** | **127.9 s** | **91.7 s** | **91.7 s** |
305
- | Frames captured | 1,303 | 902 | 902 |
391
+ | Stage | v0.3.0 | v0.4.0 | v0.5.0 | v0.6.0 |
392
+ |-------|--------|--------|--------|--------|
393
+ | Recording | 30.8 s | 31.1 s | 31.1 s | 31.1 s |
394
+ | Compose + Encode | 97.2 s | 60.6 s | 60.6 s | 60.6 s |
395
+ | **Total** | **127.9 s** | **91.7 s** | **91.7 s** | **91.7 s** |
396
+ | Frames captured | 1,303 | 902 | 902 | 902 |
306
397
 
307
398
  Key optimisations in v0.4.0: concurrent streaming pipeline, static frame deduplication (~33% skipped), per-worker StaticLayers cache, and raw RGBA buffer pipeline.
308
399
 
309
- v0.5.0 focuses on **recording quality** rather than throughput: smooth cursor movement (CSS transition suppression), zoom intensity presets, and multi-session keystroke HUD.
400
+ v0.5.0 focuses on **recording quality**: smooth cursor, zoom intensity presets, multi-session keystroke HUD.
401
+
402
+ v0.6.0 focuses on **convention alignment & expressiveness**: gentler defaults (light zoom, normal cursor speed), per-step effects override, new transitions (slide, blur), audio narration, and smart camera (scroll-aware zoom suppression + cursor-following focal point).
310
403
 
311
404
  ## Output Compression
312
405
 
@@ -415,43 +508,12 @@ npx clipwise record my-scenario.yaml -f mp4 -o ./output
415
508
  - Start each interaction with enough scroll to make the target element visible
416
509
  - Use `waitUntil: "networkidle"` for pages with API calls
417
510
  - Keep `type.delay` at 15-25ms for a fast but readable typing effect
418
- - Use `transition: fade` between major sections for cinematic cuts
511
+ - Use `transition: fade` or `transition: blur` between major sections for cinematic cuts
419
512
 
420
513
  ### Writing Scenarios with AI
421
514
 
422
515
  See [PROMPTS.md](./PROMPTS.md) for a ready-to-use prompt template. Copy-paste it to ChatGPT or Claude with your site URL, and get a working YAML scenario back.
423
516
 
424
- ## Claude Code Skill
425
-
426
- Clipwise ships a built-in [Claude Code](https://claude.com/claude-code) skill. Once installed, type `/clipwise` in Claude Code to generate YAML scenarios, validate, and record — all through natural language.
427
-
428
- ### Install the skill
429
-
430
- ```bash
431
- npx clipwise install-skill
432
- ```
433
-
434
- This copies the skill file to `.claude/skills/clipwise.md` (project-level if `.claude/` exists, otherwise `~/.claude/skills/`).
435
-
436
- ### Usage
437
-
438
- In any Claude Code session:
439
-
440
- ```
441
- /clipwise
442
- > Record a demo of my dashboard at http://localhost:3000
443
- — click the login button, type credentials, navigate to analytics
444
- ```
445
-
446
- Claude will:
447
- 1. Generate a complete `clipwise.yaml` scenario
448
- 2. Run `npx clipwise validate` to check for errors
449
- 3. Run `npx clipwise record` to produce the MP4
450
-
451
- ### Update
452
-
453
- Re-run `npx clipwise install-skill` after upgrading clipwise to get the latest skill.
454
-
455
517
  ## GitHub Pages
456
518
 
457
519
  Clipwise includes a documentation site and a live demo dashboard in the `docs/` folder. To host it:
@@ -462,11 +524,7 @@ Clipwise includes a documentation site and a live demo dashboard in the `docs/`
462
524
  4. Docs go live at `https://kwakseongjae.github.io/clipwise/`
463
525
  5. Demo dashboard at `https://kwakseongjae.github.io/clipwise/demo/`
464
526
 
465
- Then anyone can record the demo site:
466
-
467
- ```bash
468
- npx clipwise demo --url https://kwakseongjae.github.io/clipwise/demo/
469
- ```
527
+ The built-in `npx clipwise demo` already points to this URL by default.
470
528
 
471
529
  ## Security
472
530