@edgepdf/viewer-js 0.0.3 → 0.0.4
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 +76 -24
- package/dist/images/pin-gray-selected.png +0 -0
- package/dist/images/pin-gray.png +0 -0
- package/dist/images/pin-yellow-selected.png +0 -0
- package/dist/images/pin-yellow.png +0 -0
- package/dist/images/pin.png +0 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +45 -2
- package/dist/lib/marker-manager.d.ts +19 -1
- package/dist/lib/marker-manager.d.ts.map +1 -1
- package/dist/styles.d.ts +10 -0
- package/dist/styles.d.ts.map +1 -0
- package/package.json +2 -3
package/README.md
CHANGED
|
@@ -10,11 +10,7 @@ npm install @edgepdf/viewer-js
|
|
|
10
10
|
pnpm add @edgepdf/viewer-js
|
|
11
11
|
```
|
|
12
12
|
|
|
13
|
-
**Note:** Leaflet is bundled with this library, so you don't need to install it separately.
|
|
14
|
-
|
|
15
|
-
```typescript
|
|
16
|
-
import '@edgepdf/viewer-js/styles.css';
|
|
17
|
-
```
|
|
13
|
+
**Note:** Leaflet is bundled with this library, so you don't need to install it separately. **CSS styles are automatically injected** when you import the library - no manual CSS import needed!
|
|
18
14
|
|
|
19
15
|
## Usage
|
|
20
16
|
|
|
@@ -22,8 +18,8 @@ import '@edgepdf/viewer-js/styles.css';
|
|
|
22
18
|
|
|
23
19
|
```typescript
|
|
24
20
|
import { EdgePdfViewer } from '@edgepdf/viewer-js';
|
|
25
|
-
import '@edgepdf/viewer-js/styles.css'; // Required: Leaflet CSS
|
|
26
21
|
import type { ViewerConfig } from '@edgepdf/types';
|
|
22
|
+
// CSS is automatically injected - no need to import styles manually!
|
|
27
23
|
|
|
28
24
|
// Get container element
|
|
29
25
|
const container = document.getElementById('map-container');
|
|
@@ -36,8 +32,8 @@ const config: ViewerConfig = {
|
|
|
36
32
|
height: 3000,
|
|
37
33
|
tileSize: 256,
|
|
38
34
|
maxZoom: 5,
|
|
39
|
-
minZoom: 0
|
|
40
|
-
}
|
|
35
|
+
minZoom: 0,
|
|
36
|
+
},
|
|
41
37
|
};
|
|
42
38
|
|
|
43
39
|
// Create and initialize viewer
|
|
@@ -52,8 +48,8 @@ viewer.dispose();
|
|
|
52
48
|
|
|
53
49
|
```typescript
|
|
54
50
|
import { EdgePdfViewer } from '@edgepdf/viewer-js';
|
|
55
|
-
import '@edgepdf/viewer-js/styles.css'; // Required: Leaflet CSS
|
|
56
51
|
import type { ViewerConfig, MapOptions } from '@edgepdf/types';
|
|
52
|
+
// CSS is automatically injected - no need to import styles manually!
|
|
57
53
|
|
|
58
54
|
const config: ViewerConfig = {
|
|
59
55
|
tileUrl: 'https://example.com/tiles/{z}/{x}/{y}.png',
|
|
@@ -62,21 +58,21 @@ const config: ViewerConfig = {
|
|
|
62
58
|
height: 3000,
|
|
63
59
|
tileSize: 256,
|
|
64
60
|
maxZoom: 5,
|
|
65
|
-
minZoom: 0
|
|
66
|
-
}
|
|
61
|
+
minZoom: 0,
|
|
62
|
+
},
|
|
67
63
|
};
|
|
68
64
|
|
|
69
65
|
const mapOptions: MapOptions = {
|
|
70
66
|
center: [1500, 1000], // [y, x] in pixel coordinates
|
|
71
67
|
zoom: 2,
|
|
72
68
|
minZoom: 0,
|
|
73
|
-
maxZoom: 5
|
|
69
|
+
maxZoom: 5,
|
|
74
70
|
};
|
|
75
71
|
|
|
76
72
|
const viewer = new EdgePdfViewer({
|
|
77
73
|
container: document.getElementById('map-container'),
|
|
78
74
|
config,
|
|
79
|
-
mapOptions
|
|
75
|
+
mapOptions,
|
|
80
76
|
});
|
|
81
77
|
|
|
82
78
|
viewer.initialize();
|
|
@@ -99,11 +95,13 @@ new EdgePdfViewer(options: {
|
|
|
99
95
|
```
|
|
100
96
|
|
|
101
97
|
**Parameters:**
|
|
98
|
+
|
|
102
99
|
- `container` - HTML element that will contain the map
|
|
103
100
|
- `config` - Viewer configuration with tile URL and image info
|
|
104
101
|
- `mapOptions` - Optional Leaflet map options (center, zoom, etc.)
|
|
105
102
|
|
|
106
103
|
**Throws:**
|
|
104
|
+
|
|
107
105
|
- `Error` if container is not provided or invalid
|
|
108
106
|
- `Error` if config is not provided or invalid
|
|
109
107
|
- `Error` if tileUrl is missing
|
|
@@ -116,6 +114,7 @@ new EdgePdfViewer(options: {
|
|
|
116
114
|
Initializes the Leaflet map with custom CRS (Coordinate Reference System). Sets up a custom CRS.Simple coordinate system suitable for displaying image tiles without geographic coordinates.
|
|
117
115
|
|
|
118
116
|
**Throws:**
|
|
117
|
+
|
|
119
118
|
- `Error` if map initialization fails
|
|
120
119
|
|
|
121
120
|
##### `getMap(): L.Map | null`
|
|
@@ -140,9 +139,9 @@ Disposes of the map instance and cleans up resources. This should be called when
|
|
|
140
139
|
|
|
141
140
|
```typescript
|
|
142
141
|
interface ViewerConfig {
|
|
143
|
-
tileUrl: string;
|
|
144
|
-
imageInfo: ImageInfo;
|
|
145
|
-
onPinsUpdate?: (pins: Marker[]) => void;
|
|
142
|
+
tileUrl: string; // Tile URL template with {z}, {x}, {y} placeholders
|
|
143
|
+
imageInfo: ImageInfo; // Image metadata
|
|
144
|
+
onPinsUpdate?: (pins: Marker[]) => void; // Optional callback for marker updates
|
|
146
145
|
originalImagePath?: string; // Optional original image path
|
|
147
146
|
}
|
|
148
147
|
```
|
|
@@ -151,11 +150,11 @@ interface ViewerConfig {
|
|
|
151
150
|
|
|
152
151
|
```typescript
|
|
153
152
|
interface ImageInfo {
|
|
154
|
-
width: number;
|
|
155
|
-
height: number;
|
|
153
|
+
width: number; // Original image width in pixels
|
|
154
|
+
height: number; // Original image height in pixels
|
|
156
155
|
tileSize: number; // Tile size in pixels (default: 256)
|
|
157
|
-
maxZoom: number;
|
|
158
|
-
minZoom: number;
|
|
156
|
+
maxZoom: number; // Maximum zoom level
|
|
157
|
+
minZoom: number; // Minimum zoom level
|
|
159
158
|
}
|
|
160
159
|
```
|
|
161
160
|
|
|
@@ -163,10 +162,10 @@ interface ImageInfo {
|
|
|
163
162
|
|
|
164
163
|
```typescript
|
|
165
164
|
interface MapOptions {
|
|
166
|
-
center?: [number, number];
|
|
167
|
-
zoom?: number;
|
|
168
|
-
minZoom?: number;
|
|
169
|
-
maxZoom?: number;
|
|
165
|
+
center?: [number, number]; // Initial center coordinates [y, x]
|
|
166
|
+
zoom?: number; // Initial zoom level
|
|
167
|
+
minZoom?: number; // Minimum zoom level
|
|
168
|
+
maxZoom?: number; // Maximum zoom level
|
|
170
169
|
bounds?: {
|
|
171
170
|
southwest: [number, number];
|
|
172
171
|
northeast: [number, number];
|
|
@@ -174,6 +173,59 @@ interface MapOptions {
|
|
|
174
173
|
}
|
|
175
174
|
```
|
|
176
175
|
|
|
176
|
+
## Marker Icons
|
|
177
|
+
|
|
178
|
+
The library includes built-in pin icons that are automatically available in the `dist/images/` folder:
|
|
179
|
+
|
|
180
|
+
- `pin.png` - Default pin icon
|
|
181
|
+
- `pin-gray.png` - Gray pin icon
|
|
182
|
+
- `pin-yellow.png` - Yellow pin icon
|
|
183
|
+
- `pin-gray-selected.png` - Gray pin (selected state)
|
|
184
|
+
- `pin-yellow-selected.png` - Yellow pin (selected state)
|
|
185
|
+
|
|
186
|
+
### Using Built-in Icons
|
|
187
|
+
|
|
188
|
+
By default, the `MarkerManager` uses `./images/` as the icon base path. To use the built-in icons:
|
|
189
|
+
|
|
190
|
+
```typescript
|
|
191
|
+
const viewer = new EdgePdfViewer({ container, config });
|
|
192
|
+
viewer.initialize();
|
|
193
|
+
|
|
194
|
+
const markerManager = viewer.getMarkerManager();
|
|
195
|
+
// Icons are automatically loaded from the library's dist/images/ folder
|
|
196
|
+
// No configuration needed if serving from the library location
|
|
197
|
+
```
|
|
198
|
+
|
|
199
|
+
### Customizing Icons
|
|
200
|
+
|
|
201
|
+
To use custom icons, copy the icon files from `node_modules/@edgepdf/viewer-js/dist/images/` to your public folder, customize them, and set the icon base path:
|
|
202
|
+
|
|
203
|
+
```typescript
|
|
204
|
+
const markerManager = viewer.getMarkerManager();
|
|
205
|
+
|
|
206
|
+
// Option 1: Serve from your public folder (recommended for customization)
|
|
207
|
+
markerManager.setIconBasePath('/'); // Icons in public/ folder
|
|
208
|
+
|
|
209
|
+
// Option 2: Use a CDN
|
|
210
|
+
markerManager.setIconBasePath('https://cdn.example.com/icons/');
|
|
211
|
+
|
|
212
|
+
// Option 3: Use relative path
|
|
213
|
+
markerManager.setIconBasePath('./assets/icons/');
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
**Note:** Icon files must be named exactly as listed above (e.g., `pin.png`, `pin-gray.png`, etc.) for the library to find them.
|
|
217
|
+
|
|
218
|
+
### Available Icon Types
|
|
219
|
+
|
|
220
|
+
```typescript
|
|
221
|
+
type IconType =
|
|
222
|
+
| 'pin'
|
|
223
|
+
| 'pin-gray'
|
|
224
|
+
| 'pin-yellow'
|
|
225
|
+
| 'pin-gray-selected'
|
|
226
|
+
| 'pin-yellow-selected';
|
|
227
|
+
```
|
|
228
|
+
|
|
177
229
|
## Coordinate System
|
|
178
230
|
|
|
179
231
|
The viewer uses Leaflet's `CRS.Simple` coordinate system, which treats coordinates as pixel positions rather than geographic lat/lng. This is ideal for displaying image tiles:
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/dist/index.d.ts
CHANGED
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,UAAU,CAAC;AAElB,cAAc,iBAAiB,CAAC;AAChC,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAC/D,OAAO,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AAC9D,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AACxD,YAAY,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAGnE,YAAY,EACV,SAAS,EACT,UAAU,EACV,YAAY,EACZ,aAAa,EACb,WAAW,EACX,MAAM,EACN,UAAU,EACV,UAAU,EACV,UAAU,EACV,SAAS,EACT,gBAAgB,EAChB,eAAe,EACf,WAAW,EACX,iBAAiB,EACjB,mBAAmB,EACnB,uBAAuB,EACvB,oBAAoB,GACrB,MAAM,gBAAgB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -9575,6 +9575,28 @@ var require_leaflet_src = __commonJS({
|
|
|
9575
9575
|
}
|
|
9576
9576
|
});
|
|
9577
9577
|
|
|
9578
|
+
// packages/viewer-js/src/styles.ts
|
|
9579
|
+
if (typeof window !== "undefined" && typeof document !== "undefined") {
|
|
9580
|
+
const existingLink = document.querySelector("link[data-edgepdf-styles]");
|
|
9581
|
+
if (!existingLink) {
|
|
9582
|
+
const link = document.createElement("link");
|
|
9583
|
+
link.rel = "stylesheet";
|
|
9584
|
+
link.type = "text/css";
|
|
9585
|
+
link.setAttribute("data-edgepdf-styles", "true");
|
|
9586
|
+
try {
|
|
9587
|
+
if (typeof import.meta !== "undefined" && import.meta.url) {
|
|
9588
|
+
const baseUrl = new URL(import.meta.url);
|
|
9589
|
+
link.href = new URL("./styles.css", baseUrl).href;
|
|
9590
|
+
} else {
|
|
9591
|
+
link.href = "./styles.css";
|
|
9592
|
+
}
|
|
9593
|
+
} catch (e) {
|
|
9594
|
+
link.href = "./styles.css";
|
|
9595
|
+
}
|
|
9596
|
+
document.head.appendChild(link);
|
|
9597
|
+
}
|
|
9598
|
+
}
|
|
9599
|
+
|
|
9578
9600
|
// packages/viewer-js/src/lib/viewer.ts
|
|
9579
9601
|
var import_leaflet4 = __toESM(require_leaflet_src(), 1);
|
|
9580
9602
|
|
|
@@ -10587,7 +10609,8 @@ var MarkerManager = class {
|
|
|
10587
10609
|
showDeleteButton: true
|
|
10588
10610
|
};
|
|
10589
10611
|
defaultIconType = "pin";
|
|
10590
|
-
iconBasePath = "/";
|
|
10612
|
+
iconBasePath = "./images/";
|
|
10613
|
+
// Default to library's images folder
|
|
10591
10614
|
/**
|
|
10592
10615
|
* Creates a new MarkerManager instance
|
|
10593
10616
|
*
|
|
@@ -11076,11 +11099,31 @@ var MarkerManager = class {
|
|
|
11076
11099
|
/**
|
|
11077
11100
|
* Sets the base path for marker icons
|
|
11078
11101
|
*
|
|
11079
|
-
* @param basePath - Base path for icon files (default: '/')
|
|
11102
|
+
* @param basePath - Base path for icon files (default: './images/')
|
|
11103
|
+
*
|
|
11104
|
+
* @example
|
|
11105
|
+
* ```typescript
|
|
11106
|
+
* // Use library's built-in icons (default)
|
|
11107
|
+
* markerManager.setIconBasePath('./images/');
|
|
11108
|
+
*
|
|
11109
|
+
* // Use custom icons from public folder
|
|
11110
|
+
* markerManager.setIconBasePath('/');
|
|
11111
|
+
*
|
|
11112
|
+
* // Use icons from a CDN
|
|
11113
|
+
* markerManager.setIconBasePath('https://cdn.example.com/icons/');
|
|
11114
|
+
* ```
|
|
11080
11115
|
*/
|
|
11081
11116
|
setIconBasePath(basePath) {
|
|
11082
11117
|
this.iconBasePath = basePath.endsWith("/") ? basePath : `${basePath}/`;
|
|
11083
11118
|
}
|
|
11119
|
+
/**
|
|
11120
|
+
* Gets the current base path for marker icons
|
|
11121
|
+
*
|
|
11122
|
+
* @returns The current icon base path
|
|
11123
|
+
*/
|
|
11124
|
+
getIconBasePath() {
|
|
11125
|
+
return this.iconBasePath;
|
|
11126
|
+
}
|
|
11084
11127
|
/**
|
|
11085
11128
|
* Updates the icon type for a specific marker
|
|
11086
11129
|
*
|
|
@@ -315,9 +315,27 @@ export declare class MarkerManager {
|
|
|
315
315
|
/**
|
|
316
316
|
* Sets the base path for marker icons
|
|
317
317
|
*
|
|
318
|
-
* @param basePath - Base path for icon files (default: '/')
|
|
318
|
+
* @param basePath - Base path for icon files (default: './images/')
|
|
319
|
+
*
|
|
320
|
+
* @example
|
|
321
|
+
* ```typescript
|
|
322
|
+
* // Use library's built-in icons (default)
|
|
323
|
+
* markerManager.setIconBasePath('./images/');
|
|
324
|
+
*
|
|
325
|
+
* // Use custom icons from public folder
|
|
326
|
+
* markerManager.setIconBasePath('/');
|
|
327
|
+
*
|
|
328
|
+
* // Use icons from a CDN
|
|
329
|
+
* markerManager.setIconBasePath('https://cdn.example.com/icons/');
|
|
330
|
+
* ```
|
|
319
331
|
*/
|
|
320
332
|
setIconBasePath(basePath: string): void;
|
|
333
|
+
/**
|
|
334
|
+
* Gets the current base path for marker icons
|
|
335
|
+
*
|
|
336
|
+
* @returns The current icon base path
|
|
337
|
+
*/
|
|
338
|
+
getIconBasePath(): string;
|
|
321
339
|
/**
|
|
322
340
|
* Updates the icon type for a specific marker
|
|
323
341
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"marker-manager.d.ts","sourceRoot":"","sources":["../../src/lib/marker-manager.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,SAAS,CAAC;AACxB,OAAO,KAAK,EACV,MAAM,EACN,UAAU,EACV,aAAa,EACb,WAAW,EACX,SAAS,EACT,WAAW,EACX,eAAe,EACf,uBAAuB,EACvB,oBAAoB,EACrB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAI1D;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC,qCAAqC;IACrC,QAAQ,CAAC,EAAE,aAAa,CAAC;IACzB,qCAAqC;IACrC,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,gCAAgC;IAChC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,oCAAoC;IACpC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,0BAA0B;IAC1B,IAAI,CAAC,EAAE,MAAM,CA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;;;OAKG;IACH,OAAO,CAAC,kBAAkB;IAmD1B;;;;;OAKG;IACH,OAAO,CAAC,0BAA0B;IAyClC;;;;;OAKG;IACH,OAAO,CAAC,0BAA0B;IAgElC;;;;OAIG;YACW,UAAU;IAuCxB;;;;OAIG;YACW,YAAY;IA6B1B;;;;;OAKG;IACH,OAAO,CAAC,cAAc;IAgCtB;;;;;OAKG;IACH,OAAO,CAAC,kBAAkB;IAsE1B;;;;;OAKG;IACH,OAAO,CAAC,yBAAyB;IAwBjC;;;;OAIG;IACH,OAAO,CAAC,gBAAgB;CAGzB"}
|
package/dist/styles.d.ts
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CSS auto-loader for @edgepdf/viewer-js
|
|
3
|
+
*
|
|
4
|
+
* This file is automatically imported by the main index.ts file.
|
|
5
|
+
* It dynamically loads the CSS file at runtime, so users don't need to manually import CSS.
|
|
6
|
+
*
|
|
7
|
+
* The CSS is automatically injected when @edgepdf/viewer-js is imported.
|
|
8
|
+
*/
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=styles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../src/styles.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAmCH,OAAO,EAAE,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@edgepdf/viewer-js",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.4",
|
|
4
4
|
"description": "EdgePDF Viewer - JavaScript library for viewing PDF documents with interactive markers and zoom controls",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -30,8 +30,7 @@
|
|
|
30
30
|
"types": "./dist/index.d.ts",
|
|
31
31
|
"import": "./dist/index.js",
|
|
32
32
|
"default": "./dist/index.js"
|
|
33
|
-
}
|
|
34
|
-
"./styles.css": "./dist/styles.css"
|
|
33
|
+
}
|
|
35
34
|
},
|
|
36
35
|
"files": [
|
|
37
36
|
"dist",
|