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
123
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.7.3 to 2.8.0

dist/assets/index-0WRjmZSh.js

16

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

@@ -22,4 +22,4 @@ "main": "index.js",

"-": "^0.0.1",
"ava": "^5.3.1",
"axios": "^1.6.2",
"ava": "^6.0.1",
"axios": "^1.6.3",
"canvas": "^2.11.2",

@@ -31,6 +31,6 @@ "dotenv": "^16.3.1",

"pngjs": "^7.0.0",
"polotno": "^2.1.2",
"polotno": "^2.4.1",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"vite": "^5.0.2"
"vite": "^5.0.10"
},

@@ -40,5 +40,5 @@ "author": "Anton Lavrenov",

"dependencies": {
"@sparticuz/chromium": "119.0.0",
"puppeteer": "^21.5.2",
"puppeteer-core": "^21.5.2",
"@sparticuz/chromium": "119.0.2",
"puppeteer": "^21.6.1",
"puppeteer-core": "^21.6.1",
"tmp": "^0.2.1"

@@ -45,0 +45,0 @@ },

@@ -28,3 +28,2 @@ const fs = require('fs');

const convertToWebM = (input, output) => {
console.log(input, output);
return new Promise((resolve, reject) => {

@@ -70,2 +69,10 @@ ffmpeg(input)

const urlCache = {};
const cachedVideoToDataURL = async (url) => {
if (!urlCache[url]) {
urlCache[url] = videoToDataURL(url);
}
return urlCache[url];
};
function printProgress(progress) {

@@ -84,6 +91,8 @@ process.stdout.clearLine(0);

const videoEls = [];
for (const page of json.pages) {
for (const el of page.children) {
if (el.type === 'video') {
el.src = await videoToDataURL(el.src);
videoEls.push(el);
}

@@ -93,2 +102,8 @@ }

await Promise.all(
videoEls.map(async (el) => {
el.src = await cachedVideoToDataURL(el.src);
})
);
const duration = json.pages.reduce((acc, page) => {

@@ -95,0 +110,0 @@ return acc + page.duration;

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