exifreader 4.9.0 → 4.9.2
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 +4 -2
- package/exif-reader.d.ts +8 -8
- package/package.json +1 -1
- package/src/exif-reader.js +1 -1
package/README.md
CHANGED
|
@@ -356,14 +356,14 @@ tags (resulting bundle will be ~16 % of a full build):
|
|
|
356
356
|
}
|
|
357
357
|
```
|
|
358
358
|
|
|
359
|
-
Then, if you didn't install ExifReader yet,
|
|
359
|
+
Then, if you didn't install ExifReader yet, run `npm install exifreader`.
|
|
360
360
|
Otherwise you have to re-build the library:
|
|
361
361
|
|
|
362
362
|
```bash
|
|
363
363
|
npm rebuild exifreader
|
|
364
364
|
```
|
|
365
365
|
|
|
366
|
-
If you use `yarn`,
|
|
366
|
+
If you use `yarn`, run `yarn add exifreader` to rebuild the library.
|
|
367
367
|
|
|
368
368
|
After that the new bundle is here: `node_modules/exifreader/dist/exif-reader.js`
|
|
369
369
|
|
|
@@ -498,6 +498,8 @@ case is covered.
|
|
|
498
498
|
Changelog
|
|
499
499
|
---------
|
|
500
500
|
|
|
501
|
+
- **December 2021**:
|
|
502
|
+
- Add option `length` to only read the first `length` bytes of the file.
|
|
501
503
|
- **October 2021**:
|
|
502
504
|
- Major version update 4.0.0. A couple of small breaking changes that
|
|
503
505
|
shouldn't affect too many users:
|
package/exif-reader.d.ts
CHANGED
|
@@ -93,7 +93,7 @@ interface StringArrayTag {
|
|
|
93
93
|
}
|
|
94
94
|
|
|
95
95
|
interface XmpTag {
|
|
96
|
-
value: string
|
|
96
|
+
value: string | Array<XmpTag> | XmpTags,
|
|
97
97
|
attributes: {
|
|
98
98
|
[name: string]: string
|
|
99
99
|
},
|
|
@@ -177,14 +177,14 @@ interface MPFImageTags {
|
|
|
177
177
|
}
|
|
178
178
|
|
|
179
179
|
export function load(data: ArrayBuffer | SharedArrayBuffer | Buffer): Tags & XmpTags & IccTags;
|
|
180
|
-
export function load(data: ArrayBuffer | SharedArrayBuffer | Buffer, options: {expanded: true}): ExpandedTags;
|
|
181
|
-
export function load(data: ArrayBuffer | SharedArrayBuffer | Buffer, options: {expanded?: false}): Tags & XmpTags & IccTags;
|
|
180
|
+
export function load(data: ArrayBuffer | SharedArrayBuffer | Buffer, options: {expanded: true, includeUnknown?: boolean, length?: number}): ExpandedTags;
|
|
181
|
+
export function load(data: ArrayBuffer | SharedArrayBuffer | Buffer, options: {expanded?: false, includeUnknown?: boolean, length?: number}): Tags & XmpTags & IccTags;
|
|
182
182
|
export function load(data: string | File): Promise<Tags & XmpTags & IccTags>;
|
|
183
|
-
export function load(data: string | File, options: {expanded: true}): Promise<ExpandedTags>;
|
|
184
|
-
export function load(data: string | File, options: {expanded?: false}): Promise<Tags & XmpTags & IccTags>;
|
|
183
|
+
export function load(data: string | File, options: {expanded: true, includeUnknown?: boolean, length?: number}): Promise<ExpandedTags>;
|
|
184
|
+
export function load(data: string | File, options: {expanded?: false, includeUnknown?: boolean, length?: number}): Promise<Tags & XmpTags & IccTags>;
|
|
185
185
|
export function loadView(data: DataView): Tags & XmpTags & IccTags;
|
|
186
|
-
export function loadView(data: DataView, options: {expanded: true}): ExpandedTags;
|
|
187
|
-
export function loadView(data: DataView, options: {expanded?: false}): Tags & XmpTags & IccTags;
|
|
186
|
+
export function loadView(data: DataView, options: {expanded: true, includeUnknown?: boolean}): ExpandedTags;
|
|
187
|
+
export function loadView(data: DataView, options: {expanded?: false, includeUnknown?: boolean}): Tags & XmpTags & IccTags;
|
|
188
188
|
|
|
189
189
|
export namespace errors {
|
|
190
190
|
export class MetadataMissingError extends Error {}
|
|
@@ -319,7 +319,7 @@ interface Tags {
|
|
|
319
319
|
'GPSTrackRef'?: StringArrayTag,
|
|
320
320
|
'GPSTrack'?: NumberTag,
|
|
321
321
|
'GPSImgDirectionRef'?: StringArrayTag,
|
|
322
|
-
'GPSImgDirection'?:
|
|
322
|
+
'GPSImgDirection'?: RationalTag,
|
|
323
323
|
'GPSMapDatum'?: StringArrayTag,
|
|
324
324
|
'GPSDestLatitudeRef'?: StringArrayTag,
|
|
325
325
|
'GPSDestLatitude'?: NumberArrayTag,
|
package/package.json
CHANGED
package/src/exif-reader.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* ExifReader
|
|
3
3
|
* http://github.com/mattiasw/exifreader
|
|
4
|
-
* Copyright (C) 2011-
|
|
4
|
+
* Copyright (C) 2011-2023 Mattias Wallander <mattias@wallander.eu>
|
|
5
5
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
6
6
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
7
7
|
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
|