@yurikilian/lex4 1.1.1 → 1.2.0
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.
|
@@ -12,10 +12,9 @@ export declare const PX_PER_MM: number;
|
|
|
12
12
|
export declare const A4_WIDTH_PX: number;
|
|
13
13
|
/** A4 height in CSS pixels (≈1123px) */
|
|
14
14
|
export declare const A4_HEIGHT_PX: number;
|
|
15
|
-
/** Standard A4
|
|
15
|
+
/** Standard A4 margin: 30mm on all sides (European standard) in CSS pixels */
|
|
16
16
|
export declare const PAGE_MARGIN_TOP_PX: number;
|
|
17
17
|
export declare const PAGE_MARGIN_BOTTOM_PX: number;
|
|
18
|
-
/** Standard A4 horizontal margin: 31.75mm (1.25 inches) in CSS pixels */
|
|
19
18
|
export declare const PAGE_MARGIN_LEFT_PX: number;
|
|
20
19
|
export declare const PAGE_MARGIN_RIGHT_PX: number;
|
|
21
20
|
/** Maximum header height as a ratio of page height */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dimensions.d.ts","sourceRoot":"","sources":["../../src/constants/dimensions.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,eAAO,MAAM,WAAW,MAAM,CAAC;AAC/B,eAAO,MAAM,YAAY,MAAM,CAAC;AAEhC,0CAA0C;AAC1C,eAAO,MAAM,SAAS,QAAY,CAAC;AAEnC,sCAAsC;AACtC,eAAO,MAAM,WAAW,QAAsC,CAAC;AAE/D,wCAAwC;AACxC,eAAO,MAAM,YAAY,QAAuC,CAAC;AAEjE,
|
|
1
|
+
{"version":3,"file":"dimensions.d.ts","sourceRoot":"","sources":["../../src/constants/dimensions.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,eAAO,MAAM,WAAW,MAAM,CAAC;AAC/B,eAAO,MAAM,YAAY,MAAM,CAAC;AAEhC,0CAA0C;AAC1C,eAAO,MAAM,SAAS,QAAY,CAAC;AAEnC,sCAAsC;AACtC,eAAO,MAAM,WAAW,QAAsC,CAAC;AAE/D,wCAAwC;AACxC,eAAO,MAAM,YAAY,QAAuC,CAAC;AAEjE,8EAA8E;AAC9E,eAAO,MAAM,kBAAkB,QAA6B,CAAC;AAC7D,eAAO,MAAM,qBAAqB,QAA6B,CAAC;AAChE,eAAO,MAAM,mBAAmB,QAA6B,CAAC;AAC9D,eAAO,MAAM,oBAAoB,QAA6B,CAAC;AAE/D,sDAAsD;AACtD,eAAO,MAAM,gBAAgB,MAAM,CAAC;AAEpC,sDAAsD;AACtD,eAAO,MAAM,gBAAgB,MAAM,CAAC;AAEpC,0CAA0C;AAC1C,eAAO,MAAM,oBAAoB,QAA8C,CAAC;AAEhF,0CAA0C;AAC1C,eAAO,MAAM,oBAAoB,QAA8C,CAAC"}
|
package/dist/lex4-editor.cjs
CHANGED
|
@@ -61,10 +61,10 @@ const A4_HEIGHT_MM = 297;
|
|
|
61
61
|
const PX_PER_MM = 96 / 25.4;
|
|
62
62
|
const A4_WIDTH_PX = Math.round(A4_WIDTH_MM * PX_PER_MM);
|
|
63
63
|
const A4_HEIGHT_PX = Math.round(A4_HEIGHT_MM * PX_PER_MM);
|
|
64
|
-
const PAGE_MARGIN_TOP_PX = Math.round(
|
|
65
|
-
const PAGE_MARGIN_BOTTOM_PX = Math.round(
|
|
66
|
-
const PAGE_MARGIN_LEFT_PX = Math.round(
|
|
67
|
-
const PAGE_MARGIN_RIGHT_PX = Math.round(
|
|
64
|
+
const PAGE_MARGIN_TOP_PX = Math.round(30 * PX_PER_MM);
|
|
65
|
+
const PAGE_MARGIN_BOTTOM_PX = Math.round(30 * PX_PER_MM);
|
|
66
|
+
const PAGE_MARGIN_LEFT_PX = Math.round(30 * PX_PER_MM);
|
|
67
|
+
const PAGE_MARGIN_RIGHT_PX = Math.round(30 * PX_PER_MM);
|
|
68
68
|
const MAX_HEADER_RATIO = 0.2;
|
|
69
69
|
const MAX_FOOTER_RATIO = 0.2;
|
|
70
70
|
const MAX_HEADER_HEIGHT_PX = Math.round(A4_HEIGHT_PX * MAX_HEADER_RATIO);
|