@tileflow/static 0.1.0-alpha.2 → 0.1.0-alpha.21
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/GENERATED_OUTPUT_LICENSE.md +21 -0
- package/LICENSE +201 -0
- package/NOTICE +9 -0
- package/README.md +94 -2
- package/TRADEMARKS.md +10 -0
- package/dist/chunk-A23RC4BE.js +328 -0
- package/dist/chunk-KPT7PASB.js +122 -0
- package/dist/chunk-MGQCHCU3.js +228 -0
- package/dist/chunk-NHQK5UZ2.js +455 -0
- package/dist/chunk-S3WXE5P4.js +99 -0
- package/dist/client.d.ts +58 -0
- package/dist/client.js +25 -0
- package/dist/index.d.ts +6 -248
- package/dist/index.js +49 -375
- package/dist/manifest.d.ts +111 -0
- package/dist/manifest.js +18 -0
- package/dist/overlays.d.ts +16 -0
- package/dist/overlays.js +18 -0
- package/dist/scene-contract-DZMhLDnf.d.ts +159 -0
- package/dist/scene.d.ts +191 -0
- package/dist/scene.js +22 -0
- package/package.json +32 -5
package/dist/index.d.ts
CHANGED
|
@@ -1,248 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
readonly maxGeoJsonBytes: 96000;
|
|
8
|
-
readonly maxOverlays: 24;
|
|
9
|
-
readonly maxPathCoordinates: 2000;
|
|
10
|
-
readonly maxPhysicalPixels: number;
|
|
11
|
-
readonly minDimension: 64;
|
|
12
|
-
};
|
|
13
|
-
declare const coordinateSchema: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
14
|
-
declare const lineOverlaySchema: z.ZodObject<{
|
|
15
|
-
color: z.ZodDefault<z.ZodString>;
|
|
16
|
-
coordinates: z.ZodArray<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>;
|
|
17
|
-
id: z.ZodOptional<z.ZodString>;
|
|
18
|
-
opacity: z.ZodDefault<z.ZodNumber>;
|
|
19
|
-
type: z.ZodLiteral<"line">;
|
|
20
|
-
width: z.ZodDefault<z.ZodNumber>;
|
|
21
|
-
}, z.core.$strip>;
|
|
22
|
-
declare const circleOverlaySchema: z.ZodObject<{
|
|
23
|
-
color: z.ZodDefault<z.ZodString>;
|
|
24
|
-
coordinate: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
25
|
-
id: z.ZodOptional<z.ZodString>;
|
|
26
|
-
opacity: z.ZodDefault<z.ZodNumber>;
|
|
27
|
-
radius: z.ZodDefault<z.ZodNumber>;
|
|
28
|
-
strokeColor: z.ZodOptional<z.ZodString>;
|
|
29
|
-
strokeWidth: z.ZodDefault<z.ZodNumber>;
|
|
30
|
-
type: z.ZodLiteral<"circle">;
|
|
31
|
-
}, z.core.$strip>;
|
|
32
|
-
declare const markerOverlaySchema: z.ZodObject<{
|
|
33
|
-
color: z.ZodDefault<z.ZodString>;
|
|
34
|
-
coordinate: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
35
|
-
id: z.ZodOptional<z.ZodString>;
|
|
36
|
-
radius: z.ZodDefault<z.ZodNumber>;
|
|
37
|
-
strokeColor: z.ZodDefault<z.ZodString>;
|
|
38
|
-
strokeWidth: z.ZodDefault<z.ZodNumber>;
|
|
39
|
-
type: z.ZodLiteral<"marker">;
|
|
40
|
-
}, z.core.$strip>;
|
|
41
|
-
declare const polygonOverlaySchema: z.ZodObject<{
|
|
42
|
-
coordinates: z.ZodArray<z.ZodArray<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>>;
|
|
43
|
-
fill: z.ZodDefault<z.ZodString>;
|
|
44
|
-
id: z.ZodOptional<z.ZodString>;
|
|
45
|
-
opacity: z.ZodDefault<z.ZodNumber>;
|
|
46
|
-
stroke: z.ZodOptional<z.ZodString>;
|
|
47
|
-
strokeWidth: z.ZodDefault<z.ZodNumber>;
|
|
48
|
-
type: z.ZodLiteral<"polygon">;
|
|
49
|
-
}, z.core.$strip>;
|
|
50
|
-
declare const staticOverlaySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
51
|
-
color: z.ZodDefault<z.ZodString>;
|
|
52
|
-
coordinates: z.ZodArray<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>;
|
|
53
|
-
id: z.ZodOptional<z.ZodString>;
|
|
54
|
-
opacity: z.ZodDefault<z.ZodNumber>;
|
|
55
|
-
type: z.ZodLiteral<"line">;
|
|
56
|
-
width: z.ZodDefault<z.ZodNumber>;
|
|
57
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
58
|
-
color: z.ZodDefault<z.ZodString>;
|
|
59
|
-
coordinate: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
60
|
-
id: z.ZodOptional<z.ZodString>;
|
|
61
|
-
opacity: z.ZodDefault<z.ZodNumber>;
|
|
62
|
-
radius: z.ZodDefault<z.ZodNumber>;
|
|
63
|
-
strokeColor: z.ZodOptional<z.ZodString>;
|
|
64
|
-
strokeWidth: z.ZodDefault<z.ZodNumber>;
|
|
65
|
-
type: z.ZodLiteral<"circle">;
|
|
66
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
67
|
-
color: z.ZodDefault<z.ZodString>;
|
|
68
|
-
coordinate: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
69
|
-
id: z.ZodOptional<z.ZodString>;
|
|
70
|
-
radius: z.ZodDefault<z.ZodNumber>;
|
|
71
|
-
strokeColor: z.ZodDefault<z.ZodString>;
|
|
72
|
-
strokeWidth: z.ZodDefault<z.ZodNumber>;
|
|
73
|
-
type: z.ZodLiteral<"marker">;
|
|
74
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
75
|
-
coordinates: z.ZodArray<z.ZodArray<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>>;
|
|
76
|
-
fill: z.ZodDefault<z.ZodString>;
|
|
77
|
-
id: z.ZodOptional<z.ZodString>;
|
|
78
|
-
opacity: z.ZodDefault<z.ZodNumber>;
|
|
79
|
-
stroke: z.ZodOptional<z.ZodString>;
|
|
80
|
-
strokeWidth: z.ZodDefault<z.ZodNumber>;
|
|
81
|
-
type: z.ZodLiteral<"polygon">;
|
|
82
|
-
}, z.core.$strip>], "type">;
|
|
83
|
-
declare const staticSceneSchema: z.ZodObject<{
|
|
84
|
-
camera: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
85
|
-
bearing: z.ZodOptional<z.ZodNumber>;
|
|
86
|
-
center: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
87
|
-
type: z.ZodLiteral<"center">;
|
|
88
|
-
zoom: z.ZodNumber;
|
|
89
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
90
|
-
bearing: z.ZodOptional<z.ZodNumber>;
|
|
91
|
-
bounds: z.ZodTuple<[z.ZodNumber, z.ZodNumber, z.ZodNumber, z.ZodNumber], null>;
|
|
92
|
-
padding: z.ZodOptional<z.ZodNumber>;
|
|
93
|
-
type: z.ZodLiteral<"bounds">;
|
|
94
|
-
}, z.core.$strip>], "type">;
|
|
95
|
-
map: z.ZodString;
|
|
96
|
-
overlays: z.ZodDefault<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
97
|
-
color: z.ZodDefault<z.ZodString>;
|
|
98
|
-
coordinates: z.ZodArray<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>;
|
|
99
|
-
id: z.ZodOptional<z.ZodString>;
|
|
100
|
-
opacity: z.ZodDefault<z.ZodNumber>;
|
|
101
|
-
type: z.ZodLiteral<"line">;
|
|
102
|
-
width: z.ZodDefault<z.ZodNumber>;
|
|
103
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
104
|
-
color: z.ZodDefault<z.ZodString>;
|
|
105
|
-
coordinate: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
106
|
-
id: z.ZodOptional<z.ZodString>;
|
|
107
|
-
opacity: z.ZodDefault<z.ZodNumber>;
|
|
108
|
-
radius: z.ZodDefault<z.ZodNumber>;
|
|
109
|
-
strokeColor: z.ZodOptional<z.ZodString>;
|
|
110
|
-
strokeWidth: z.ZodDefault<z.ZodNumber>;
|
|
111
|
-
type: z.ZodLiteral<"circle">;
|
|
112
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
113
|
-
color: z.ZodDefault<z.ZodString>;
|
|
114
|
-
coordinate: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
115
|
-
id: z.ZodOptional<z.ZodString>;
|
|
116
|
-
radius: z.ZodDefault<z.ZodNumber>;
|
|
117
|
-
strokeColor: z.ZodDefault<z.ZodString>;
|
|
118
|
-
strokeWidth: z.ZodDefault<z.ZodNumber>;
|
|
119
|
-
type: z.ZodLiteral<"marker">;
|
|
120
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
121
|
-
coordinates: z.ZodArray<z.ZodArray<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>>;
|
|
122
|
-
fill: z.ZodDefault<z.ZodString>;
|
|
123
|
-
id: z.ZodOptional<z.ZodString>;
|
|
124
|
-
opacity: z.ZodDefault<z.ZodNumber>;
|
|
125
|
-
stroke: z.ZodOptional<z.ZodString>;
|
|
126
|
-
strokeWidth: z.ZodDefault<z.ZodNumber>;
|
|
127
|
-
type: z.ZodLiteral<"polygon">;
|
|
128
|
-
}, z.core.$strip>], "type">>>;
|
|
129
|
-
size: z.ZodObject<{
|
|
130
|
-
dpr: z.ZodOptional<z.ZodLiteral<1>>;
|
|
131
|
-
height: z.ZodNumber;
|
|
132
|
-
width: z.ZodNumber;
|
|
133
|
-
}, z.core.$strip>;
|
|
134
|
-
}, z.core.$strip>;
|
|
135
|
-
declare const staticRenderManifestSchema: z.ZodObject<{
|
|
136
|
-
mapId: z.ZodString;
|
|
137
|
-
rendererVersion: z.ZodString;
|
|
138
|
-
schemaVersion: z.ZodLiteral<1>;
|
|
139
|
-
scene: z.ZodObject<{
|
|
140
|
-
camera: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
141
|
-
bearing: z.ZodOptional<z.ZodNumber>;
|
|
142
|
-
center: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
143
|
-
type: z.ZodLiteral<"center">;
|
|
144
|
-
zoom: z.ZodNumber;
|
|
145
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
146
|
-
bearing: z.ZodOptional<z.ZodNumber>;
|
|
147
|
-
bounds: z.ZodTuple<[z.ZodNumber, z.ZodNumber, z.ZodNumber, z.ZodNumber], null>;
|
|
148
|
-
padding: z.ZodOptional<z.ZodNumber>;
|
|
149
|
-
type: z.ZodLiteral<"bounds">;
|
|
150
|
-
}, z.core.$strip>], "type">;
|
|
151
|
-
map: z.ZodString;
|
|
152
|
-
overlays: z.ZodDefault<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
153
|
-
color: z.ZodDefault<z.ZodString>;
|
|
154
|
-
coordinates: z.ZodArray<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>;
|
|
155
|
-
id: z.ZodOptional<z.ZodString>;
|
|
156
|
-
opacity: z.ZodDefault<z.ZodNumber>;
|
|
157
|
-
type: z.ZodLiteral<"line">;
|
|
158
|
-
width: z.ZodDefault<z.ZodNumber>;
|
|
159
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
160
|
-
color: z.ZodDefault<z.ZodString>;
|
|
161
|
-
coordinate: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
162
|
-
id: z.ZodOptional<z.ZodString>;
|
|
163
|
-
opacity: z.ZodDefault<z.ZodNumber>;
|
|
164
|
-
radius: z.ZodDefault<z.ZodNumber>;
|
|
165
|
-
strokeColor: z.ZodOptional<z.ZodString>;
|
|
166
|
-
strokeWidth: z.ZodDefault<z.ZodNumber>;
|
|
167
|
-
type: z.ZodLiteral<"circle">;
|
|
168
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
169
|
-
color: z.ZodDefault<z.ZodString>;
|
|
170
|
-
coordinate: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
171
|
-
id: z.ZodOptional<z.ZodString>;
|
|
172
|
-
radius: z.ZodDefault<z.ZodNumber>;
|
|
173
|
-
strokeColor: z.ZodDefault<z.ZodString>;
|
|
174
|
-
strokeWidth: z.ZodDefault<z.ZodNumber>;
|
|
175
|
-
type: z.ZodLiteral<"marker">;
|
|
176
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
177
|
-
coordinates: z.ZodArray<z.ZodArray<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>>;
|
|
178
|
-
fill: z.ZodDefault<z.ZodString>;
|
|
179
|
-
id: z.ZodOptional<z.ZodString>;
|
|
180
|
-
opacity: z.ZodDefault<z.ZodNumber>;
|
|
181
|
-
stroke: z.ZodOptional<z.ZodString>;
|
|
182
|
-
strokeWidth: z.ZodDefault<z.ZodNumber>;
|
|
183
|
-
type: z.ZodLiteral<"polygon">;
|
|
184
|
-
}, z.core.$strip>], "type">>>;
|
|
185
|
-
size: z.ZodObject<{
|
|
186
|
-
dpr: z.ZodOptional<z.ZodLiteral<1>>;
|
|
187
|
-
height: z.ZodNumber;
|
|
188
|
-
width: z.ZodNumber;
|
|
189
|
-
}, z.core.$strip>;
|
|
190
|
-
}, z.core.$strip>;
|
|
191
|
-
styleId: z.ZodOptional<z.ZodString>;
|
|
192
|
-
styleRevision: z.ZodString;
|
|
193
|
-
styleUrl: z.ZodString;
|
|
194
|
-
}, z.core.$strip>;
|
|
195
|
-
type StaticCoordinate = z.infer<typeof coordinateSchema>;
|
|
196
|
-
type StaticSceneInput = z.input<typeof staticSceneSchema>;
|
|
197
|
-
type StaticScene = z.infer<typeof staticSceneSchema>;
|
|
198
|
-
type StaticOverlayInput = z.input<typeof staticOverlaySchema>;
|
|
199
|
-
type StaticOverlay = z.infer<typeof staticOverlaySchema>;
|
|
200
|
-
type StaticRenderManifest = z.infer<typeof staticRenderManifestSchema>;
|
|
201
|
-
type StaticMapResult = {
|
|
202
|
-
cached: boolean;
|
|
203
|
-
hash: string;
|
|
204
|
-
imageUrl: string;
|
|
205
|
-
status: 'ready';
|
|
206
|
-
};
|
|
207
|
-
type StaticMapCreateOptions = {
|
|
208
|
-
apiKey?: string;
|
|
209
|
-
apiUrl?: string;
|
|
210
|
-
fetch?: typeof fetch;
|
|
211
|
-
};
|
|
212
|
-
declare function line(input: Omit<z.input<typeof lineOverlaySchema>, 'type'>): StaticOverlay;
|
|
213
|
-
declare function circle(input: Omit<z.input<typeof circleOverlaySchema>, 'type'>): StaticOverlay;
|
|
214
|
-
declare function marker(input: Omit<z.input<typeof markerOverlaySchema>, 'type'>): StaticOverlay;
|
|
215
|
-
declare function polygon(input: Omit<z.input<typeof polygonOverlaySchema>, 'type'>): StaticOverlay;
|
|
216
|
-
declare function validateStaticScene(input: unknown): {
|
|
217
|
-
ok: true;
|
|
218
|
-
scene: StaticScene;
|
|
219
|
-
} | {
|
|
220
|
-
error: string;
|
|
221
|
-
ok: false;
|
|
222
|
-
};
|
|
223
|
-
declare function validateStaticRenderManifest(input: unknown): {
|
|
224
|
-
manifest: StaticRenderManifest;
|
|
225
|
-
ok: true;
|
|
226
|
-
} | {
|
|
227
|
-
error: string;
|
|
228
|
-
ok: false;
|
|
229
|
-
};
|
|
230
|
-
declare function normalizeStaticScene(scene: StaticSceneInput): StaticScene;
|
|
231
|
-
declare function createRenderManifest(input: {
|
|
232
|
-
mapId: string;
|
|
233
|
-
rendererVersion: string;
|
|
234
|
-
scene: StaticSceneInput;
|
|
235
|
-
styleId?: string;
|
|
236
|
-
styleRevision: string;
|
|
237
|
-
styleUrl: string;
|
|
238
|
-
}): StaticRenderManifest;
|
|
239
|
-
declare function hashRenderManifest(manifest: StaticRenderManifest): Promise<string>;
|
|
240
|
-
declare function compileStaticOverlays(overlays: StaticOverlay[]): {
|
|
241
|
-
layers: Record<string, unknown>[];
|
|
242
|
-
sources: Record<string, Record<string, unknown>>;
|
|
243
|
-
};
|
|
244
|
-
declare function createStaticMap(scene: StaticSceneInput, options?: StaticMapCreateOptions): Promise<StaticMapResult>;
|
|
245
|
-
declare function precacheStaticMap(scene: StaticSceneInput, options?: StaticMapCreateOptions): Promise<StaticMapResult>;
|
|
246
|
-
declare function stableStringify(value: unknown): string;
|
|
247
|
-
|
|
248
|
-
export { type StaticCoordinate, type StaticMapCreateOptions, type StaticMapResult, type StaticOverlay, type StaticOverlayInput, type StaticRenderManifest, type StaticScene, type StaticSceneInput, circle, compileStaticOverlays, createRenderManifest, createStaticMap, hashRenderManifest, line, marker, normalizeStaticScene, polygon, precacheStaticMap, stableStringify, staticOverlaySchema, staticRenderManifestSchema, staticRendererSchemaVersion, staticSceneLimits, staticSceneSchema, staticSceneSchemaVersion, validateStaticRenderManifest, validateStaticScene };
|
|
1
|
+
export { StaticAutoFitErrorResponse, StaticAutoFitFailure, StaticMapRequestError, StaticMapRequestErrorResponse, StaticMapRequestFailure, normalizeStaticScene, staticMapRequestErrorResponseSchema, validateStaticScene } from './scene.js';
|
|
2
|
+
export { circle, compileStaticOverlays, line, marker, polygon } from './overlays.js';
|
|
3
|
+
export { StaticRenderManifest, createRenderManifest, hashRenderManifest, hashStaticSceneRequest, staticRenderManifestSchema, staticRendererSchemaVersion, validateStaticRenderManifest } from './manifest.js';
|
|
4
|
+
export { PreparedStaticMapRequest, StaticMapCreateOptions, StaticMapEndpointRequestOptions, StaticMapResult, createStaticMap, createStaticMapIdempotencyKey, precacheStaticMap, prepareStaticMapRequest, requestStaticMapUntilReady, stableStringify, staticMapProcessingResultSchema, staticMapReadyResultSchema, validateStaticMapIdempotencyKey } from './client.js';
|
|
5
|
+
export { M as MAX_OVERLAY_LATITUDE, S as StaticCoordinate, a as StaticOverlay, b as StaticOverlayInput, c as StaticPadding, d as StaticScene, e as StaticSceneInput, s as staticOverlaySchema, f as staticSceneLimits, g as staticSceneSchema, h as staticSceneSchemaVersion } from './scene-contract-DZMhLDnf.js';
|
|
6
|
+
import 'zod';
|