dev-annotate 0.1.0 → 0.2.0
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.md
CHANGED
|
@@ -38,7 +38,7 @@ injected DOM and listeners.
|
|
|
38
38
|
|
|
39
39
|
```ts
|
|
40
40
|
import { createSaveAnnotationHandler } from 'dev-annotate/server'
|
|
41
|
-
export default createSaveAnnotationHandler({ dir: '.
|
|
41
|
+
export default createSaveAnnotationHandler({ dir: '.dev-annotations' })
|
|
42
42
|
```
|
|
43
43
|
|
|
44
44
|
Or use the pure writer directly:
|
package/dist/cli.js
CHANGED
|
@@ -25,7 +25,7 @@ function latestAnnotation(dir) {
|
|
|
25
25
|
// src/server/save.ts
|
|
26
26
|
import { mkdirSync, writeFileSync } from "fs";
|
|
27
27
|
import { resolve } from "path";
|
|
28
|
-
var DEFAULT_DIR = ".
|
|
28
|
+
var DEFAULT_DIR = ".dev-annotations";
|
|
29
29
|
|
|
30
30
|
// src/cli/index.ts
|
|
31
31
|
function parseFlags(args) {
|
package/dist/nuxt/module.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { D as DevAnnotationOptions } from '../types-BzKl2hyk.js';
|
|
2
2
|
|
|
3
3
|
interface ModuleOptions extends DevAnnotationOptions {
|
|
4
|
-
/** Server-side save directory. Default '.
|
|
4
|
+
/** Server-side save directory. Default '.dev-annotations'. */
|
|
5
5
|
dir?: string;
|
|
6
6
|
}
|
|
7
7
|
declare const _default: NuxtModule<TOptions, TOptions, false>;
|
|
@@ -12,7 +12,7 @@ function resolveExt(input) {
|
|
|
12
12
|
// src/server/save.ts
|
|
13
13
|
import { mkdirSync, writeFileSync } from "fs";
|
|
14
14
|
import { resolve } from "path";
|
|
15
|
-
var DEFAULT_DIR = ".
|
|
15
|
+
var DEFAULT_DIR = ".dev-annotations";
|
|
16
16
|
function saveAnnotationBytes(data, opts = {}) {
|
|
17
17
|
const dir = resolve(process.cwd(), opts.dir ?? DEFAULT_DIR);
|
|
18
18
|
mkdirSync(dir, { recursive: true });
|
package/dist/server/index.d.ts
CHANGED
|
@@ -14,7 +14,7 @@ interface SaveAnnotationResult {
|
|
|
14
14
|
path: string;
|
|
15
15
|
bytes: number;
|
|
16
16
|
}
|
|
17
|
-
declare const DEFAULT_DIR = ".
|
|
17
|
+
declare const DEFAULT_DIR = ".dev-annotations";
|
|
18
18
|
declare function saveAnnotationBytes(data: Uint8Array, opts?: SaveAnnotationOptions): SaveAnnotationResult;
|
|
19
19
|
|
|
20
20
|
interface SaveHandlerOptions {
|
package/dist/server/index.js
CHANGED
|
@@ -9,7 +9,7 @@ function resolveExt(input) {
|
|
|
9
9
|
// src/server/save.ts
|
|
10
10
|
import { mkdirSync, writeFileSync } from "fs";
|
|
11
11
|
import { resolve } from "path";
|
|
12
|
-
var DEFAULT_DIR = ".
|
|
12
|
+
var DEFAULT_DIR = ".dev-annotations";
|
|
13
13
|
function saveAnnotationBytes(data, opts = {}) {
|
|
14
14
|
const dir = resolve(process.cwd(), opts.dir ?? DEFAULT_DIR);
|
|
15
15
|
mkdirSync(dir, { recursive: true });
|
package/package.json
CHANGED
|
@@ -25,7 +25,7 @@ annotated screenshot and act on it.
|
|
|
25
25
|
```
|
|
26
26
|
|
|
27
27
|
## Notes
|
|
28
|
-
- Screenshots live under `.
|
|
28
|
+
- Screenshots live under `.dev-annotations/annotated-*.{png,jpg,webp}`
|
|
29
29
|
by default (override with `--dir`).
|
|
30
30
|
- Treat an annotation as intent, not pixels: confirm the underlying cause
|
|
31
31
|
before changing how something looks.
|