nuxt-tiff-provider 0.3.0 → 0.4.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
@@ -34,13 +34,15 @@ export default defineNuxtConfig({
34
34
  autoRegister: true, // false → call registerTiffServiceWorker() yourself
35
35
  retryRacedImages: true, // re-fetch images that raced the SW on first load
36
36
  paramPrefix: 'tp', // query-param namespace + interception marker
37
+ ignoreNativeTiff: false, // true → transcode in Safari too, skip native passthrough
37
38
  },
38
39
  })
39
40
  ```
40
41
 
41
42
  ## Notes
42
43
 
43
- - Safari paints TIFF natively; the SW detects this and passes through.
44
+ - Safari paints TIFF natively; the SW detects this and passes through. Set
45
+ `ignoreNativeTiff: true` to transcode there too.
44
46
  - First cold visit: images requested before the SW took control are re-fetched
45
47
  automatically once it does (disable with `retryRacedImages: false`).
46
48
  - Already run your own Service Worker? Set `autoRegister: false` and
package/dist/module.d.mts CHANGED
@@ -15,6 +15,8 @@ interface ModuleOptions {
15
15
  retryRacedImages: boolean;
16
16
  /** Query-param namespace for modifiers and the interception marker. Default 'tp'. */
17
17
  paramPrefix: string;
18
+ /** Transcode in the SW even where TIFF is native (Safari). Default false. */
19
+ ignoreNativeTiff: boolean;
18
20
  }
19
21
  declare const module$1: nuxt_schema.NuxtModule<ModuleOptions, ModuleOptions, false>;
20
22
 
package/dist/module.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "compatibility": {
5
5
  "nuxt": ">=3.0.0"
6
6
  },
7
- "version": "0.3.0",
7
+ "version": "0.4.0",
8
8
  "builder": {
9
9
  "@nuxt/module-builder": "1.0.2",
10
10
  "unbuild": "unknown"
package/dist/module.mjs CHANGED
@@ -17,7 +17,8 @@ const module$1 = defineNuxtModule({
17
17
  scope: "/",
18
18
  autoRegister: true,
19
19
  retryRacedImages: true,
20
- paramPrefix: "tp"
20
+ paramPrefix: "tp",
21
+ ignoreNativeTiff: false
21
22
  },
22
23
  async setup(options, nuxt) {
23
24
  const resolver = createResolver(import.meta.url);
@@ -63,7 +64,8 @@ const module$1 = defineNuxtModule({
63
64
  quality: options.quality,
64
65
  scope: options.scope,
65
66
  retryRacedImages: options.retryRacedImages,
66
- paramPrefix: options.paramPrefix
67
+ paramPrefix: options.paramPrefix,
68
+ ignoreNativeTiff: options.ignoreNativeTiff
67
69
  }
68
70
  );
69
71
  if (options.autoRegister) {
@@ -8,6 +8,7 @@ export default defineNuxtPlugin(() => {
8
8
  cacheName: cfg.cacheName,
9
9
  quality: cfg.quality,
10
10
  retryRacedImages: cfg.retryRacedImages,
11
- paramPrefix: cfg.paramPrefix
11
+ paramPrefix: cfg.paramPrefix,
12
+ ignoreNativeTiff: cfg.ignoreNativeTiff
12
13
  });
13
14
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nuxt-tiff-provider",
3
- "version": "0.3.0",
3
+ "version": "0.4.0",
4
4
  "description": "Nuxt module: render TIFFs via @nuxt/image off the main thread in a Service Worker.",
5
5
  "keywords": [
6
6
  "nuxt",
@@ -15,6 +15,13 @@
15
15
  ],
16
16
  "author": "San Chen <bigsan.chen@gmail.com>",
17
17
  "license": "MIT",
18
+ "repository": {
19
+ "type": "git",
20
+ "url": "git+https://github.com/bigsan/nuxt-tiff-provider.git",
21
+ "directory": "packages/nuxt"
22
+ },
23
+ "homepage": "https://github.com/bigsan/nuxt-tiff-provider/tree/main/packages/nuxt#readme",
24
+ "bugs": "https://github.com/bigsan/nuxt-tiff-provider/issues",
18
25
  "type": "module",
19
26
  "main": "./dist/module.mjs",
20
27
  "types": "./dist/types.d.mts",
@@ -29,13 +36,13 @@
29
36
  ],
30
37
  "dependencies": {
31
38
  "@nuxt/image": "^1.11.0",
32
- "@nuxt/kit": "^3.13.0",
39
+ "@nuxt/kit": "^4.0.0",
33
40
  "defu": "^6.1.0",
34
- "@tiff-provider/core": "0.3.0"
41
+ "@tiff-provider/core": "0.4.0"
35
42
  },
36
43
  "devDependencies": {
37
44
  "@nuxt/module-builder": "^1.0.0",
38
- "@nuxt/schema": "^3.13.0",
45
+ "@nuxt/schema": "^4.0.0",
39
46
  "@nuxt/test-utils": "^3.14.0",
40
47
  "@types/node": "^22",
41
48
  "nuxt": "^4.0.0",
@@ -43,7 +50,7 @@
43
50
  "vitest": "^3.2.0"
44
51
  },
45
52
  "peerDependencies": {
46
- "nuxt": "^3.0.0 || ^4.0.0"
53
+ "nuxt": "^4.0.0"
47
54
  },
48
55
  "scripts": {
49
56
  "build": "nuxt-module-build build",