img-upload-kit 1.1.1 → 2.0.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/CHANGELOG.md +89 -74
- package/MIGRATION.md +192 -0
- package/README.md +243 -259
- package/dist/bin.js +1186 -0
- package/dist/bin.js.map +1 -0
- package/dist/blur.cjs +40 -412
- package/dist/blur.cjs.map +1 -1
- package/dist/blur.d.cts +5 -5
- package/dist/blur.d.ts +5 -5
- package/dist/blur.js +39 -393
- package/dist/blur.js.map +1 -1
- package/dist/blurDataUtils-DveBRtqE.d.cts +43 -0
- package/dist/blurDataUtils-yx9Q6HlU.d.ts +43 -0
- package/dist/blurService-D5TpMNji.d.ts +83 -0
- package/dist/blurService-DacwylJx.d.cts +83 -0
- package/dist/chunk-25GYKQ6J.js +158 -0
- package/dist/chunk-25GYKQ6J.js.map +1 -0
- package/dist/chunk-34L4TEE3.cjs +226 -0
- package/dist/chunk-34L4TEE3.cjs.map +1 -0
- package/dist/chunk-DFCSN3X7.cjs +158 -0
- package/dist/chunk-DFCSN3X7.cjs.map +1 -0
- package/dist/chunk-EWVIL57J.js +294 -0
- package/dist/chunk-EWVIL57J.js.map +1 -0
- package/dist/chunk-FP5YIWG5.cjs +135 -0
- package/dist/chunk-FP5YIWG5.cjs.map +1 -0
- package/dist/chunk-HILELQGS.js +226 -0
- package/dist/chunk-HILELQGS.js.map +1 -0
- package/dist/chunk-IDLLCVGB.js +2370 -0
- package/dist/chunk-IDLLCVGB.js.map +1 -0
- package/dist/chunk-J6A44Y3W.js +514 -0
- package/dist/chunk-J6A44Y3W.js.map +1 -0
- package/dist/chunk-LOSVFO56.cjs +145 -0
- package/dist/chunk-LOSVFO56.cjs.map +1 -0
- package/dist/chunk-MBQJ6NVJ.cjs +294 -0
- package/dist/chunk-MBQJ6NVJ.cjs.map +1 -0
- package/dist/chunk-MHGQEBPW.js +145 -0
- package/dist/chunk-MHGQEBPW.js.map +1 -0
- package/dist/chunk-QHU7FUO4.cjs +37 -0
- package/dist/chunk-QHU7FUO4.cjs.map +1 -0
- package/dist/chunk-S2IFAWJK.js +37 -0
- package/dist/chunk-S2IFAWJK.js.map +1 -0
- package/dist/chunk-TA5Y64JM.cjs +2370 -0
- package/dist/chunk-TA5Y64JM.cjs.map +1 -0
- package/dist/chunk-VYVZVUNI.js +135 -0
- package/dist/chunk-VYVZVUNI.js.map +1 -0
- package/dist/chunk-XKQMCY5Z.cjs +514 -0
- package/dist/chunk-XKQMCY5Z.cjs.map +1 -0
- package/dist/cli.cjs +273 -76
- package/dist/cli.cjs.map +1 -1
- package/dist/cli.js +269 -73
- package/dist/cli.js.map +1 -1
- package/dist/headless.cjs +8 -1880
- package/dist/headless.cjs.map +1 -1
- package/dist/headless.d.cts +3 -1
- package/dist/headless.d.ts +3 -1
- package/dist/headless.js +25 -1886
- package/dist/headless.js.map +1 -1
- package/dist/index-BIdnqtW8.d.ts +234 -0
- package/dist/index-Brk_uHs6.d.cts +234 -0
- package/dist/{index-FVXXKf2v.d.ts → index-CPMlaQsC.d.ts} +76 -153
- package/dist/{index-FVXXKf2v.d.cts → index-DHINe-rA.d.cts} +76 -153
- package/dist/index.cjs +64 -532
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +7 -4
- package/dist/index.d.ts +7 -4
- package/dist/index.js +63 -504
- package/dist/index.js.map +1 -1
- package/dist/{memoryAdapter-CBu7_3Pp.d.ts → memoryAdapter-Ck0ccZbF.d.cts} +3 -2
- package/dist/{memoryAdapter-BJjyLR-1.d.cts → memoryAdapter-DxEKaG0b.d.ts} +3 -2
- package/dist/placeholders-C4ftwaII.d.ts +5 -0
- package/dist/placeholders-x_3rt65M.d.cts +5 -0
- package/dist/react.cjs +1952 -3257
- package/dist/react.cjs.map +1 -1
- package/dist/react.d.cts +188 -50
- package/dist/react.d.ts +188 -50
- package/dist/react.js +1763 -3013
- package/dist/react.js.map +1 -1
- package/dist/server-handler.cjs +14 -0
- package/dist/server-handler.cjs.map +1 -0
- package/dist/server-handler.d.cts +3 -0
- package/dist/server-handler.d.ts +3 -0
- package/dist/server-handler.js +14 -0
- package/dist/server-handler.js.map +1 -0
- package/dist/server.cjs +1096 -532
- package/dist/server.cjs.map +1 -1
- package/dist/server.d.cts +77 -154
- package/dist/server.d.ts +77 -154
- package/dist/server.js +1050 -448
- package/dist/server.js.map +1 -1
- package/dist/storage.cjs +239 -232
- package/dist/storage.cjs.map +1 -1
- package/dist/storage.d.cts +21 -5
- package/dist/storage.d.ts +21 -5
- package/dist/storage.js +227 -207
- package/dist/storage.js.map +1 -1
- package/dist/styles/animated-image.css +112 -0
- package/dist/styles/dropzone-and-tiles.css +247 -0
- package/dist/styles/modals-and-dock.css +248 -0
- package/dist/styles/primitives.css +197 -0
- package/dist/styles/quality-and-inputs.css +184 -0
- package/dist/styles/tokens.css +123 -0
- package/dist/styles.css +235 -220
- package/dist/types-BrP-o9nd.d.cts +85 -0
- package/dist/types-sZ3KoFQY.d.ts +85 -0
- package/dist/types-yShGNQnW.d.cts +61 -0
- package/dist/types-yShGNQnW.d.ts +61 -0
- package/dist/{types-CiLY0DwB.d.cts → upload-C5Trd6Dh.d.cts} +27 -53
- package/dist/{types-CiLY0DwB.d.ts → upload-C5Trd6Dh.d.ts} +27 -53
- package/package.json +92 -32
- package/dist/blurService-DqsnfPTd.d.cts +0 -172
- package/dist/blurService-DqsnfPTd.d.ts +0 -172
|
@@ -1,172 +0,0 @@
|
|
|
1
|
-
type BlurPlaceholderType = 'default' | 'hero' | 'card' | 'thumbnail';
|
|
2
|
-
type BlurSize = 'small' | 'medium';
|
|
3
|
-
interface BlurDataOptions {
|
|
4
|
-
type?: BlurPlaceholderType;
|
|
5
|
-
size?: BlurSize;
|
|
6
|
-
width?: number;
|
|
7
|
-
height?: number;
|
|
8
|
-
punch?: number;
|
|
9
|
-
}
|
|
10
|
-
interface BlurManifestEntry {
|
|
11
|
-
hash: string;
|
|
12
|
-
variants: {
|
|
13
|
-
small: string;
|
|
14
|
-
medium?: string;
|
|
15
|
-
[key: string]: string | undefined;
|
|
16
|
-
};
|
|
17
|
-
color: string;
|
|
18
|
-
width?: number;
|
|
19
|
-
height?: number;
|
|
20
|
-
metadata?: Record<string, string>;
|
|
21
|
-
}
|
|
22
|
-
interface BlurManifestData {
|
|
23
|
-
version: string;
|
|
24
|
-
generatedAt: string;
|
|
25
|
-
totalImages: number;
|
|
26
|
-
processedImages?: number;
|
|
27
|
-
cachedImages?: number;
|
|
28
|
-
failedImages?: number;
|
|
29
|
-
hashes: Record<string, BlurManifestEntry>;
|
|
30
|
-
}
|
|
31
|
-
interface BlurCacheEntry {
|
|
32
|
-
dataUrl: string;
|
|
33
|
-
timestamp: number;
|
|
34
|
-
}
|
|
35
|
-
interface BlurServiceMetrics {
|
|
36
|
-
totalRequests: number;
|
|
37
|
-
cacheHits: number;
|
|
38
|
-
cacheMisses: number;
|
|
39
|
-
errors: number;
|
|
40
|
-
}
|
|
41
|
-
interface BlurImageSource {
|
|
42
|
-
url?: string;
|
|
43
|
-
blurDataUrl?: string | null;
|
|
44
|
-
blurColor?: string | null;
|
|
45
|
-
blurHash?: string | null;
|
|
46
|
-
altText?: string | null;
|
|
47
|
-
width?: number;
|
|
48
|
-
height?: number;
|
|
49
|
-
}
|
|
50
|
-
interface BlurData {
|
|
51
|
-
blurDataUrl: string;
|
|
52
|
-
blurColor: string;
|
|
53
|
-
blurHash?: string;
|
|
54
|
-
hasBlur: boolean;
|
|
55
|
-
}
|
|
56
|
-
interface BlurServiceConfig {
|
|
57
|
-
cacheSize?: number;
|
|
58
|
-
manifest?: BlurManifestData | Record<string, BlurManifestEntry>;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
interface BlurPlaceholderStyle {
|
|
62
|
-
backgroundColor: string;
|
|
63
|
-
backgroundImage?: string;
|
|
64
|
-
backgroundSize?: string;
|
|
65
|
-
backgroundPosition?: string;
|
|
66
|
-
backgroundRepeat?: string;
|
|
67
|
-
filter?: string;
|
|
68
|
-
transform?: string;
|
|
69
|
-
}
|
|
70
|
-
declare function getBlurData(image: BlurImageSource | null | undefined): BlurData;
|
|
71
|
-
declare function getImagePropsWithBlur(image: BlurImageSource | null | undefined): {
|
|
72
|
-
placeholder?: "blur" | undefined;
|
|
73
|
-
blurDataURL?: string | undefined;
|
|
74
|
-
src: string;
|
|
75
|
-
alt: string;
|
|
76
|
-
width: number;
|
|
77
|
-
height: number;
|
|
78
|
-
} | null;
|
|
79
|
-
declare function getBackgroundPropsWithBlur(image: BlurImageSource | null | undefined): BlurPlaceholderStyle;
|
|
80
|
-
declare function getBlurPlaceholderStyle(image: BlurImageSource | null | undefined): BlurPlaceholderStyle;
|
|
81
|
-
declare function hasBlurData(image: BlurImageSource | null | undefined): boolean;
|
|
82
|
-
declare function getBulkBlurData(images: Array<BlurImageSource | null | undefined>): BlurData[];
|
|
83
|
-
declare function createSrcSetWithBlur(image: BlurImageSource | null | undefined): string;
|
|
84
|
-
declare function preloadImageWithBlur(image: BlurImageSource | null | undefined): void;
|
|
85
|
-
declare function extractImageUrls(image: BlurImageSource | null | undefined): string[];
|
|
86
|
-
/**
|
|
87
|
-
* Browser helper: Decodes a compact BlurHash string (e.g. "LEHV6nWB2yk8pyo0adR*.7kCMdnj")
|
|
88
|
-
* into a `data:image/png;base64,...` URL using an offscreen `<canvas>`.
|
|
89
|
-
*/
|
|
90
|
-
declare function decodeBlurHashToDataURL(hash: string, width?: number, height?: number, punch?: number): string | null;
|
|
91
|
-
|
|
92
|
-
declare const DEFAULT_CDN_PATTERNS: RegExp[];
|
|
93
|
-
interface NormalizePathOptions {
|
|
94
|
-
cdnPatterns?: RegExp[];
|
|
95
|
-
stripPrefixes?: string[];
|
|
96
|
-
}
|
|
97
|
-
interface PathInfo {
|
|
98
|
-
normalizedPath: string;
|
|
99
|
-
folder?: string;
|
|
100
|
-
filename?: string;
|
|
101
|
-
extension?: string;
|
|
102
|
-
isExternal: boolean;
|
|
103
|
-
originalPath: string;
|
|
104
|
-
}
|
|
105
|
-
/**
|
|
106
|
-
* Project-agnostic image URL / path normalizer.
|
|
107
|
-
* Strips query parameters, leading `/public/`, relative `./`, and common CDN prefixes
|
|
108
|
-
* so manifest keys match consistently across local and CDN environments.
|
|
109
|
-
*/
|
|
110
|
-
declare function normalizeImagePath(imageSrc: string, options?: NormalizePathOptions): PathInfo;
|
|
111
|
-
|
|
112
|
-
interface BlurServiceOptions {
|
|
113
|
-
cacheSize?: number;
|
|
114
|
-
manifest?: BlurManifestData | Record<string, BlurManifestEntry>;
|
|
115
|
-
pathOptions?: NormalizePathOptions;
|
|
116
|
-
}
|
|
117
|
-
declare class BlurService {
|
|
118
|
-
private blurData;
|
|
119
|
-
private readonly cache;
|
|
120
|
-
private readonly pathOptions?;
|
|
121
|
-
private metadata;
|
|
122
|
-
private metrics;
|
|
123
|
-
constructor(options?: BlurServiceOptions);
|
|
124
|
-
/**
|
|
125
|
-
* Hydrate the service with a generated `blur-hashes.json` manifest or hash map.
|
|
126
|
-
*/
|
|
127
|
-
loadManifest(manifest: BlurManifestData | Record<string, BlurManifestEntry>): void;
|
|
128
|
-
/**
|
|
129
|
-
* Register or update a single image's blur data at runtime.
|
|
130
|
-
*/
|
|
131
|
-
registerEntry(imagePath: string, entry: BlurManifestEntry): void;
|
|
132
|
-
getDefaultPlaceholder(type?: BlurPlaceholderType): string;
|
|
133
|
-
private findBlurDataByPath;
|
|
134
|
-
getDominantColor(imageSrc: string): string;
|
|
135
|
-
getBlurDataURL(imageSrc: string, options?: {
|
|
136
|
-
type?: BlurPlaceholderType;
|
|
137
|
-
size?: BlurSize;
|
|
138
|
-
}): string;
|
|
139
|
-
getBulkBlurData(imageSrcs: string[], options?: {
|
|
140
|
-
type?: BlurPlaceholderType;
|
|
141
|
-
size?: BlurSize;
|
|
142
|
-
}): Record<string, string>;
|
|
143
|
-
getProgressiveData(imageSrc: string, size?: BlurSize): {
|
|
144
|
-
color: string;
|
|
145
|
-
blur: string;
|
|
146
|
-
hasBlur: boolean;
|
|
147
|
-
};
|
|
148
|
-
hasBlurHash(imageSrc: string): boolean;
|
|
149
|
-
getMetadata(): {
|
|
150
|
-
cacheSize: number;
|
|
151
|
-
metrics: {
|
|
152
|
-
cacheHitRate: string;
|
|
153
|
-
totalRequests: number;
|
|
154
|
-
cacheHits: number;
|
|
155
|
-
cacheMisses: number;
|
|
156
|
-
errors: number;
|
|
157
|
-
};
|
|
158
|
-
version: string;
|
|
159
|
-
generatedAt: string;
|
|
160
|
-
totalImages: number;
|
|
161
|
-
};
|
|
162
|
-
clearCache(): void;
|
|
163
|
-
getBlurHash(imageSrc: string): string | null;
|
|
164
|
-
preloadBlurData(imageSrcs: string[], size?: BlurSize): void;
|
|
165
|
-
fetchBlurDataForImage(imageSrc: string, type?: BlurPlaceholderType): Promise<string>;
|
|
166
|
-
getAvailableKeys(): string[];
|
|
167
|
-
findMatchingKeys(searchTerm: string): string[];
|
|
168
|
-
}
|
|
169
|
-
declare function createBlurService(options?: BlurServiceOptions): BlurService;
|
|
170
|
-
declare const blurService: BlurService;
|
|
171
|
-
|
|
172
|
-
export { type BlurPlaceholderType as B, DEFAULT_CDN_PATTERNS as D, type NormalizePathOptions as N, type PathInfo as P, type BlurCacheEntry as a, type BlurData as b, type BlurDataOptions as c, type BlurImageSource as d, type BlurManifestData as e, type BlurManifestEntry as f, type BlurPlaceholderStyle as g, BlurService as h, type BlurServiceConfig as i, type BlurServiceMetrics as j, type BlurServiceOptions as k, type BlurSize as l, blurService as m, createBlurService as n, createSrcSetWithBlur as o, decodeBlurHashToDataURL as p, extractImageUrls as q, getBackgroundPropsWithBlur as r, getBlurData as s, getBlurPlaceholderStyle as t, getBulkBlurData as u, getImagePropsWithBlur as v, hasBlurData as w, normalizeImagePath as x, preloadImageWithBlur as y };
|
|
@@ -1,172 +0,0 @@
|
|
|
1
|
-
type BlurPlaceholderType = 'default' | 'hero' | 'card' | 'thumbnail';
|
|
2
|
-
type BlurSize = 'small' | 'medium';
|
|
3
|
-
interface BlurDataOptions {
|
|
4
|
-
type?: BlurPlaceholderType;
|
|
5
|
-
size?: BlurSize;
|
|
6
|
-
width?: number;
|
|
7
|
-
height?: number;
|
|
8
|
-
punch?: number;
|
|
9
|
-
}
|
|
10
|
-
interface BlurManifestEntry {
|
|
11
|
-
hash: string;
|
|
12
|
-
variants: {
|
|
13
|
-
small: string;
|
|
14
|
-
medium?: string;
|
|
15
|
-
[key: string]: string | undefined;
|
|
16
|
-
};
|
|
17
|
-
color: string;
|
|
18
|
-
width?: number;
|
|
19
|
-
height?: number;
|
|
20
|
-
metadata?: Record<string, string>;
|
|
21
|
-
}
|
|
22
|
-
interface BlurManifestData {
|
|
23
|
-
version: string;
|
|
24
|
-
generatedAt: string;
|
|
25
|
-
totalImages: number;
|
|
26
|
-
processedImages?: number;
|
|
27
|
-
cachedImages?: number;
|
|
28
|
-
failedImages?: number;
|
|
29
|
-
hashes: Record<string, BlurManifestEntry>;
|
|
30
|
-
}
|
|
31
|
-
interface BlurCacheEntry {
|
|
32
|
-
dataUrl: string;
|
|
33
|
-
timestamp: number;
|
|
34
|
-
}
|
|
35
|
-
interface BlurServiceMetrics {
|
|
36
|
-
totalRequests: number;
|
|
37
|
-
cacheHits: number;
|
|
38
|
-
cacheMisses: number;
|
|
39
|
-
errors: number;
|
|
40
|
-
}
|
|
41
|
-
interface BlurImageSource {
|
|
42
|
-
url?: string;
|
|
43
|
-
blurDataUrl?: string | null;
|
|
44
|
-
blurColor?: string | null;
|
|
45
|
-
blurHash?: string | null;
|
|
46
|
-
altText?: string | null;
|
|
47
|
-
width?: number;
|
|
48
|
-
height?: number;
|
|
49
|
-
}
|
|
50
|
-
interface BlurData {
|
|
51
|
-
blurDataUrl: string;
|
|
52
|
-
blurColor: string;
|
|
53
|
-
blurHash?: string;
|
|
54
|
-
hasBlur: boolean;
|
|
55
|
-
}
|
|
56
|
-
interface BlurServiceConfig {
|
|
57
|
-
cacheSize?: number;
|
|
58
|
-
manifest?: BlurManifestData | Record<string, BlurManifestEntry>;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
interface BlurPlaceholderStyle {
|
|
62
|
-
backgroundColor: string;
|
|
63
|
-
backgroundImage?: string;
|
|
64
|
-
backgroundSize?: string;
|
|
65
|
-
backgroundPosition?: string;
|
|
66
|
-
backgroundRepeat?: string;
|
|
67
|
-
filter?: string;
|
|
68
|
-
transform?: string;
|
|
69
|
-
}
|
|
70
|
-
declare function getBlurData(image: BlurImageSource | null | undefined): BlurData;
|
|
71
|
-
declare function getImagePropsWithBlur(image: BlurImageSource | null | undefined): {
|
|
72
|
-
placeholder?: "blur" | undefined;
|
|
73
|
-
blurDataURL?: string | undefined;
|
|
74
|
-
src: string;
|
|
75
|
-
alt: string;
|
|
76
|
-
width: number;
|
|
77
|
-
height: number;
|
|
78
|
-
} | null;
|
|
79
|
-
declare function getBackgroundPropsWithBlur(image: BlurImageSource | null | undefined): BlurPlaceholderStyle;
|
|
80
|
-
declare function getBlurPlaceholderStyle(image: BlurImageSource | null | undefined): BlurPlaceholderStyle;
|
|
81
|
-
declare function hasBlurData(image: BlurImageSource | null | undefined): boolean;
|
|
82
|
-
declare function getBulkBlurData(images: Array<BlurImageSource | null | undefined>): BlurData[];
|
|
83
|
-
declare function createSrcSetWithBlur(image: BlurImageSource | null | undefined): string;
|
|
84
|
-
declare function preloadImageWithBlur(image: BlurImageSource | null | undefined): void;
|
|
85
|
-
declare function extractImageUrls(image: BlurImageSource | null | undefined): string[];
|
|
86
|
-
/**
|
|
87
|
-
* Browser helper: Decodes a compact BlurHash string (e.g. "LEHV6nWB2yk8pyo0adR*.7kCMdnj")
|
|
88
|
-
* into a `data:image/png;base64,...` URL using an offscreen `<canvas>`.
|
|
89
|
-
*/
|
|
90
|
-
declare function decodeBlurHashToDataURL(hash: string, width?: number, height?: number, punch?: number): string | null;
|
|
91
|
-
|
|
92
|
-
declare const DEFAULT_CDN_PATTERNS: RegExp[];
|
|
93
|
-
interface NormalizePathOptions {
|
|
94
|
-
cdnPatterns?: RegExp[];
|
|
95
|
-
stripPrefixes?: string[];
|
|
96
|
-
}
|
|
97
|
-
interface PathInfo {
|
|
98
|
-
normalizedPath: string;
|
|
99
|
-
folder?: string;
|
|
100
|
-
filename?: string;
|
|
101
|
-
extension?: string;
|
|
102
|
-
isExternal: boolean;
|
|
103
|
-
originalPath: string;
|
|
104
|
-
}
|
|
105
|
-
/**
|
|
106
|
-
* Project-agnostic image URL / path normalizer.
|
|
107
|
-
* Strips query parameters, leading `/public/`, relative `./`, and common CDN prefixes
|
|
108
|
-
* so manifest keys match consistently across local and CDN environments.
|
|
109
|
-
*/
|
|
110
|
-
declare function normalizeImagePath(imageSrc: string, options?: NormalizePathOptions): PathInfo;
|
|
111
|
-
|
|
112
|
-
interface BlurServiceOptions {
|
|
113
|
-
cacheSize?: number;
|
|
114
|
-
manifest?: BlurManifestData | Record<string, BlurManifestEntry>;
|
|
115
|
-
pathOptions?: NormalizePathOptions;
|
|
116
|
-
}
|
|
117
|
-
declare class BlurService {
|
|
118
|
-
private blurData;
|
|
119
|
-
private readonly cache;
|
|
120
|
-
private readonly pathOptions?;
|
|
121
|
-
private metadata;
|
|
122
|
-
private metrics;
|
|
123
|
-
constructor(options?: BlurServiceOptions);
|
|
124
|
-
/**
|
|
125
|
-
* Hydrate the service with a generated `blur-hashes.json` manifest or hash map.
|
|
126
|
-
*/
|
|
127
|
-
loadManifest(manifest: BlurManifestData | Record<string, BlurManifestEntry>): void;
|
|
128
|
-
/**
|
|
129
|
-
* Register or update a single image's blur data at runtime.
|
|
130
|
-
*/
|
|
131
|
-
registerEntry(imagePath: string, entry: BlurManifestEntry): void;
|
|
132
|
-
getDefaultPlaceholder(type?: BlurPlaceholderType): string;
|
|
133
|
-
private findBlurDataByPath;
|
|
134
|
-
getDominantColor(imageSrc: string): string;
|
|
135
|
-
getBlurDataURL(imageSrc: string, options?: {
|
|
136
|
-
type?: BlurPlaceholderType;
|
|
137
|
-
size?: BlurSize;
|
|
138
|
-
}): string;
|
|
139
|
-
getBulkBlurData(imageSrcs: string[], options?: {
|
|
140
|
-
type?: BlurPlaceholderType;
|
|
141
|
-
size?: BlurSize;
|
|
142
|
-
}): Record<string, string>;
|
|
143
|
-
getProgressiveData(imageSrc: string, size?: BlurSize): {
|
|
144
|
-
color: string;
|
|
145
|
-
blur: string;
|
|
146
|
-
hasBlur: boolean;
|
|
147
|
-
};
|
|
148
|
-
hasBlurHash(imageSrc: string): boolean;
|
|
149
|
-
getMetadata(): {
|
|
150
|
-
cacheSize: number;
|
|
151
|
-
metrics: {
|
|
152
|
-
cacheHitRate: string;
|
|
153
|
-
totalRequests: number;
|
|
154
|
-
cacheHits: number;
|
|
155
|
-
cacheMisses: number;
|
|
156
|
-
errors: number;
|
|
157
|
-
};
|
|
158
|
-
version: string;
|
|
159
|
-
generatedAt: string;
|
|
160
|
-
totalImages: number;
|
|
161
|
-
};
|
|
162
|
-
clearCache(): void;
|
|
163
|
-
getBlurHash(imageSrc: string): string | null;
|
|
164
|
-
preloadBlurData(imageSrcs: string[], size?: BlurSize): void;
|
|
165
|
-
fetchBlurDataForImage(imageSrc: string, type?: BlurPlaceholderType): Promise<string>;
|
|
166
|
-
getAvailableKeys(): string[];
|
|
167
|
-
findMatchingKeys(searchTerm: string): string[];
|
|
168
|
-
}
|
|
169
|
-
declare function createBlurService(options?: BlurServiceOptions): BlurService;
|
|
170
|
-
declare const blurService: BlurService;
|
|
171
|
-
|
|
172
|
-
export { type BlurPlaceholderType as B, DEFAULT_CDN_PATTERNS as D, type NormalizePathOptions as N, type PathInfo as P, type BlurCacheEntry as a, type BlurData as b, type BlurDataOptions as c, type BlurImageSource as d, type BlurManifestData as e, type BlurManifestEntry as f, type BlurPlaceholderStyle as g, BlurService as h, type BlurServiceConfig as i, type BlurServiceMetrics as j, type BlurServiceOptions as k, type BlurSize as l, blurService as m, createBlurService as n, createSrcSetWithBlur as o, decodeBlurHashToDataURL as p, extractImageUrls as q, getBackgroundPropsWithBlur as r, getBlurData as s, getBlurPlaceholderStyle as t, getBulkBlurData as u, getImagePropsWithBlur as v, hasBlurData as w, normalizeImagePath as x, preloadImageWithBlur as y };
|