@cesarvenzac/closeup 0.0.0-stage → 0.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.
Files changed (49) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +127 -2
  3. package/dist/actions.d.ts +27 -0
  4. package/dist/actions.js +13 -0
  5. package/dist/capture.d.ts +28 -0
  6. package/dist/capture.js +33 -0
  7. package/dist/compositor.d.ts +62 -0
  8. package/dist/compositor.js +164 -0
  9. package/dist/cursor.d.ts +49 -0
  10. package/dist/cursor.js +152 -0
  11. package/dist/cursors.d.ts +11 -0
  12. package/dist/cursors.js +24 -0
  13. package/dist/frame.d.ts +86 -0
  14. package/dist/frame.js +78 -0
  15. package/dist/hover.d.ts +23 -0
  16. package/dist/hover.js +89 -0
  17. package/dist/index.d.ts +24 -0
  18. package/dist/index.js +37 -0
  19. package/dist/path.d.ts +41 -0
  20. package/dist/path.js +65 -0
  21. package/dist/player.d.ts +39 -0
  22. package/dist/player.js +140 -0
  23. package/dist/pointer.d.ts +30 -0
  24. package/dist/pointer.js +134 -0
  25. package/dist/script.d.ts +75 -0
  26. package/dist/script.js +94 -0
  27. package/dist/selector.d.ts +22 -0
  28. package/dist/selector.js +83 -0
  29. package/dist/settings.d.ts +61 -0
  30. package/dist/settings.js +59 -0
  31. package/dist/shortcut.d.ts +23 -0
  32. package/dist/shortcut.js +48 -0
  33. package/dist/sounds.d.ts +22 -0
  34. package/dist/sounds.js +94 -0
  35. package/dist/stage.d.ts +12 -0
  36. package/dist/stage.js +53 -0
  37. package/dist/store.d.ts +4 -0
  38. package/dist/store.js +22 -0
  39. package/dist/take.d.ts +69 -0
  40. package/dist/take.js +220 -0
  41. package/dist/ui/editor.d.ts +90 -0
  42. package/dist/ui/editor.js +612 -0
  43. package/dist/ui/icons.d.ts +28 -0
  44. package/dist/ui/icons.js +28 -0
  45. package/dist/ui/panel.d.ts +83 -0
  46. package/dist/ui/panel.js +739 -0
  47. package/dist/ui/styles.d.ts +6 -0
  48. package/dist/ui/styles.js +183 -0
  49. package/package.json +36 -4
@@ -0,0 +1,83 @@
1
+ /**
2
+ * The toolbar and everything round it: pick what to film (an element, or a region drawn by
3
+ * hand), choose photo or video and the options, film it, and look at the result before
4
+ * keeping it. One instance, mounted outside the page's <body> (stage mode moves <body>), its
5
+ * controls in a shadow root no page's styles reach.
6
+ */
7
+ export declare class Panel {
8
+ private readonly shortcutLabel;
9
+ private readonly ui;
10
+ private readonly layer;
11
+ private readonly shadow;
12
+ private readonly $;
13
+ private settings;
14
+ private image;
15
+ private imageName;
16
+ private state;
17
+ private picked;
18
+ private hovered;
19
+ private trail;
20
+ private dragFrom;
21
+ private running;
22
+ private result;
23
+ private resultUrl;
24
+ /** The actions offered on the take on show, in the order their buttons are drawn. */
25
+ private takeActions;
26
+ private timer;
27
+ private follow;
28
+ private mounted;
29
+ private optionsOpen;
30
+ /** While a script is edited: the editor, the stage it's on, and what puts the page back. */
31
+ private editing;
32
+ private rehearsal;
33
+ constructor(shortcutLabel: string);
34
+ get isOpen(): boolean;
35
+ open(): void;
36
+ close(): void;
37
+ toggle(): void;
38
+ private startPick;
39
+ private stopPick;
40
+ private onPickMove;
41
+ /** While picking, the page doesn't get the clicks: the click that picks shouldn't also press what it picks. */
42
+ private swallow;
43
+ private onDragStart;
44
+ private dragRect;
45
+ private onDragMove;
46
+ private onDragEnd;
47
+ private choose;
48
+ private showPicked;
49
+ /** Where the pick is now: an element where it is, a region where it was drawn on the page. */
50
+ private pickedRect;
51
+ private track;
52
+ private outline;
53
+ private renderBar;
54
+ /** What's outlined and what it would make: the take's size in pixels and how much it's enlarged. */
55
+ private renderInfo;
56
+ private renderOptions;
57
+ private onClick;
58
+ private onInput;
59
+ private onKey;
60
+ private get layers();
61
+ private hideControls;
62
+ private showControls;
63
+ private go;
64
+ /** Opens the script editor on the stage, at the size the take is filmed. */
65
+ private editScript;
66
+ /** Leaves the editor: the page back as it was, and the script set to play if there is one. */
67
+ private doneEditing;
68
+ /** Plays the script on the stage without filming it, to see it before recording. */
69
+ private rehearse;
70
+ private stop;
71
+ private showResult;
72
+ private closePreview;
73
+ private download;
74
+ /**
75
+ * Runs one of the page's own actions on the take: its button counts up while it works, then
76
+ * shows it's done (once is enough), and what it said, or why it failed, is said in a toast.
77
+ */
78
+ private runAction;
79
+ private copy;
80
+ private chooseImage;
81
+ private save;
82
+ private toast;
83
+ }