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

polotno-node

Package Overview
Dependencies
Maintainers
1
Versions
122
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

polotno-node - npm Package Compare versions

Comparing version 2.9.7 to 2.9.8

dist/assets/index-DsJ35GHi.js

31

instance.js

@@ -107,5 +107,20 @@ const path = require('path');

window.config.setAssetLoadTimeout(timeout);
} else {
console.error(
'setAssetLoadTimeout function is not defined in the client.'
);
}
}, args[1].assetLoadTimeout);
}
if (args[1]?.fontLoadTimeout) {
await page.evaluate((timeout) => {
if (window.config && window.config.setFontLoadTimeout) {
window.config.setFontLoadTimeout(timeout);
} else {
console.error(
'setFontLoadTimeout function is not defined in the client.'
);
}
}, args[1].assetLoadTimeout);
}
if (args[1]?.htmlTextRenderEnabled) {

@@ -115,2 +130,6 @@ await page.evaluate(() => {

window.config.unstable_useHtmlTextRender(true);
} else {
console.error(
'unstable_useHtmlTextRender function is not defined in the client.'
);
}

@@ -126,2 +145,6 @@ });

window.config.unstable_setTextVerticalResizeEnabled(true);
} else {
console.error(
'unstable_setTextVerticalResizeEnabled function is not defined in the client.'
);
}

@@ -134,2 +157,6 @@ });

window.config.unstable_setTextOverflow(overflow);
} else {
console.error(
'unstable_setTextOverflow function is not defined in the client.'
);
}

@@ -143,2 +170,6 @@ }, args[1].textOverflow);

});
} else {
console.error(
'onLoadError function is not defined in the client. Error handling will not work.'
);
}

@@ -145,0 +176,0 @@ });

4

package.json
{
"name": "polotno-node",
"version": "2.9.7",
"version": "2.9.8",
"description": "Polotno workflow from NodeJS",

@@ -29,3 +29,3 @@ "main": "index.js",

"pngjs": "^7.0.0",
"polotno": "^2.4.26",
"polotno": "^2.4.31",
"react": "^18.2.0",

@@ -32,0 +32,0 @@ "react-dom": "^18.2.0",

@@ -168,3 +168,3 @@ # Polotno-node

You can add `assetLoadTimeout` attribute to `attrs` object. It will be used to set timeout for loading assets (images, fonts, etc). By default it is 30000ms.
You can add `assetLoadTimeout` attribute to `attrs` object. It will be used to set timeout for loading assets. By default it is 30000ms.

@@ -175,2 +175,10 @@ ```js

### `attrs.assetFontTimeout`
Timeout for loading fonts. By default it is 6000ms.
```js
const url = await instance.jsonToPDFDataURL(json, { assetFontTimeout: 10000 });
```
### `attrs.htmlTextRenderEnabled`

@@ -177,0 +185,0 @@

Sorry, the diff of this file is not supported yet

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