Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@frameright/image-display-control-metadata-parser

Package Overview
Dependencies
Maintainers
2
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@frameright/image-display-control-metadata-parser - npm Package Compare versions

Comparing version 1.0.2 to 1.0.3

23

package.json

@@ -18,3 +18,3 @@ {

],
"version": "1.0.2",
"version": "1.0.3",
"license": "MIT",

@@ -42,4 +42,2 @@ "author": {

"prepare": "husky install && tsdx build && rollup -c",
"size": "size-limit",
"analyze": "size-limit --why",
"gendoc": "typedoc",

@@ -56,16 +54,6 @@ "gentoc": "./bin/gentoc.sh",

"module": "dist/image-display-control-metadata-parser.esm.js",
"size-limit": [
{
"path": "dist/image-display-control-metadata-parser.cjs.production.min.js",
"limit": "10 KB"
},
{
"path": "dist/image-display-control-metadata-parser.esm.js",
"limit": "10 KB"
}
],
"devDependencies": {
"@rollup/plugin-commonjs": "^24.1.0",
"@rollup/plugin-node-resolve": "^15.0.2",
"@size-limit/preset-small-lib": "^8.2.4",
"@rollup/plugin-terser": "^0.4.1",
"@web/rollup-plugin-copy": "^0.4.0",

@@ -76,11 +64,10 @@ "husky": "^8.0.3",

"prettier": "^2.8.7",
"rollup": "^2.79.1",
"rollup": "^3.20.7",
"rollup-plugin-polyfill-node": "^0.12.0",
"rollup-plugin-summary": "^2.0.0",
"size-limit": "^8.2.4",
"tsdx": "^0.14.1",
"tslib": "^2.5.0",
"typedoc": "^0.24.4",
"typedoc-plugin-markdown": "^3.15.1",
"typescript": "^4.1.6"
"typedoc-plugin-markdown": "^3.15.2",
"typescript": "^5.0.4"
},

@@ -87,0 +74,0 @@ "dependencies": {

@@ -29,2 +29,4 @@ [<img src="https://avatars.githubusercontent.com/u/35964478?s=200&v=4" align="right" width="64" height="64">](https://frameright.io)

- [Usage](#usage)
* [In a Node.js back-end](#in-a-nodejs-back-end)
* [Directly in a browser](#directly-in-a-browser)
- [Image Display Control metadata](#image-display-control-metadata)

@@ -82,2 +84,4 @@ - [Changelog](#changelog)

### In a Node.js back-end
```jsx

@@ -107,2 +111,35 @@ #!/usr/bin/env node

### Directly in a browser
For testing purposes, you can use this library directly in the browser:
```html
<html>
<body onload="documentLoaded()">
<script
type="module"
src="https://cdn.jsdelivr.net/npm/@frameright/image-display-control-metadata-parser@1.0.3/dist/image-display-control-metadata-parser-standalone.min.js"
></script>
<script type="text/javascript">
async function documentLoaded() {
const image = await fetch(
'https://iptc.org/std/photometadata/examples/IPTC-PhotometadataRef-Std2021.1.jpg'
);
const arrayBuffer = await image.arrayBuffer();
const buffer = Buffer.Buffer.from(arrayBuffer);
const parser = new ImageDisplayControl.Parser(buffer);
const regions = parser.getIdcMetadata();
console.log(JSON.stringify(regions, null, 2 /*indent*/));
}
</script>
</body>
</html>
```
The parsed metadata can then directly be fed to the
[Image Display Control web component](https://github.com/Frameright/image-display-control-web-component).
&emsp; :sparkles: [Live mobile demo](https://webc.frameright.io)
## Image Display Control metadata

@@ -119,2 +156,5 @@

**1.0.3** (2023-04-22):
* Document how to use the browser build.
**1.0.2** (2023-04-21):

@@ -121,0 +161,0 @@ * Add missing `Buffer` class to the browser build.

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc