@pdfme/common
Advanced tools
Comparing version 1.0.18 to 1.1.0
{ | ||
"name": "@pdfme/common", | ||
"version": "1.0.18", | ||
"version": "1.1.0", | ||
"sideEffects": false, | ||
"author": "hand-dot", | ||
@@ -23,5 +24,11 @@ "license": "MIT", | ||
}, | ||
"main": "dist/index.js", | ||
"module": "dist/index.js", | ||
"types": "dist/types/index.d.ts", | ||
"main": "dist/cjs/src/index.js", | ||
"module": "dist/esm/src/index.js", | ||
"types": "dist/types/src/index.d.ts", | ||
"exports": { | ||
".": { | ||
"import": "./dist/esm/src/index.js", | ||
"require": "./dist/cjs/src/index.js" | ||
} | ||
}, | ||
"engines": { | ||
@@ -31,4 +38,6 @@ "node": ">=14" | ||
"scripts": { | ||
"develop": "webpack --watch --mode development", | ||
"build": "NODE_ENV=production webpack --mode production", | ||
"develop": "tsc -w", | ||
"build": "npm run build:cjs && npm run build:esm", | ||
"build:cjs": "tsc -p tsconfig.cjs.json", | ||
"build:esm": "tsc -p tsconfig.esm.json", | ||
"clean": "rimraf dist", | ||
@@ -45,5 +54,3 @@ "lint": "tsc --noEmit", | ||
"jest": { | ||
"moduleNameMapper": { | ||
"\\.(ttf)$": "<rootDir>../../fontTransformer.js" | ||
}, | ||
"resolver": "ts-jest-resolver", | ||
"moduleFileExtensions": [ | ||
@@ -58,3 +65,3 @@ "js", | ||
"ts-jest": { | ||
"tsconfig": "tsconfig.json" | ||
"tsconfig": "tsconfig.esm.json" | ||
} | ||
@@ -61,0 +68,0 @@ }, |
import { z } from 'zod'; | ||
import Helvetica from './assets/Helvetica.ttf'; | ||
import { Template, Schema, BasePdf, Font, CommonProps, isTextSchema, BarCodeType } from './type'; | ||
import { HELVETICA } from './constants.js'; | ||
import { Template, Schema, BasePdf, Font, CommonProps, isTextSchema, BarCodeType } from './type.js'; | ||
import { | ||
@@ -12,3 +12,3 @@ Inputs as InputsSchema, | ||
UIProps as UIPropsSchema, | ||
} from './schema'; | ||
} from './schema.js'; | ||
@@ -81,3 +81,3 @@ const DEFAULT_FONT_NAME = 'Helvetica'; | ||
export const getDefaultFont = (): Font => ({ | ||
[DEFAULT_FONT_NAME]: { data: b64toUint8Array(Helvetica), fallback: true }, | ||
[DEFAULT_FONT_NAME]: { data: b64toUint8Array(HELVETICA), fallback: true }, | ||
}); | ||
@@ -84,0 +84,0 @@ |
@@ -8,4 +8,4 @@ import { | ||
BLANK_PDF, | ||
} from './constants'; | ||
import { schemaTypes, isImageSchema, isBarcodeSchema, isTextSchema } from './type'; | ||
} from './constants.js'; | ||
import { schemaTypes, isImageSchema, isBarcodeSchema, isTextSchema } from './type.js'; | ||
import type { | ||
@@ -34,3 +34,3 @@ Lang, | ||
DesignerReactProps, | ||
} from './type'; | ||
} from './type.js'; | ||
import { | ||
@@ -50,3 +50,3 @@ getB64BasePdf, | ||
validateBarcodeInput, | ||
} from './helper'; | ||
} from './helper.js'; | ||
@@ -53,0 +53,0 @@ export { |
@@ -28,3 +28,3 @@ import { z } from 'zod'; | ||
DesignerReactProps, | ||
} from './schema'; | ||
} from './schema.js'; | ||
@@ -31,0 +31,0 @@ type CommonSchema = z.infer<typeof _CommonSchema>; |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Native code
Supply chain riskContains native code (e.g., compiled binaries or shared libraries). Including native code can obscure malicious behavior.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 1 instance in 1 package
1957331
39
0
100
12207
4
3