@pdfme/schemas 4.4.2 → 4.5.0-dev.2

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.
@@ -26,7 +26,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
26
26
  return (mod && mod.__esModule) ? mod : { "default": mod };
27
27
  };
28
28
  Object.defineProperty(exports, "__esModule", { value: true });
29
- exports.rotatePoint = exports.convertForPdfLayoutProps = exports.getDynamicHeightsForTable = exports.builtInPlugins = exports.ellipse = exports.rectangle = exports.tableBeta = exports.line = exports.barcodes = exports.readOnlySvg = exports.svg = exports.readOnlyImage = exports.image = exports.readOnlyText = exports.text = exports.multiVariableText = void 0;
29
+ exports.rotatePoint = exports.convertForPdfLayoutProps = exports.getDynamicHeightsForTable = exports.builtInPlugins = exports.ellipse = exports.rectangle = exports.table = exports.tableBeta = exports.line = exports.barcodes = exports.svg = exports.image = exports.text = exports.multiVariableText = exports.readOnlySvg = exports.readOnlyImage = exports.readOnlyText = void 0;
30
30
  const index_js_1 = __importDefault(require("./multiVariableText/index.js"));
31
31
  exports.multiVariableText = index_js_1.default;
32
32
  const index_js_2 = __importStar(require("./text/index.js"));
@@ -43,6 +43,7 @@ exports.barcodes = index_js_3.default;
43
43
  const line_js_1 = __importDefault(require("./shapes/line.js"));
44
44
  exports.line = line_js_1.default;
45
45
  const index_js_4 = __importDefault(require("./tables/index.js"));
46
+ exports.table = index_js_4.default;
46
47
  const dynamicTemplate_js_1 = require("./tables/dynamicTemplate.js");
47
48
  Object.defineProperty(exports, "getDynamicHeightsForTable", { enumerable: true, get: function () { return dynamicTemplate_js_1.getDynamicHeightsForTable; } });
48
49
  const rectAndEllipse_js_1 = require("./shapes/rectAndEllipse.js");
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,4EAA6D;AAgB3D,4BAhBK,kBAAiB,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AAqB9D,0FArBO,6BAAS,OAqBP;AACT,wFAtBkB,2BAAO,OAsBlB;AArBT,yCAAmE;AAyBjE,yGAzBO,mCAAwB,OAyBP;AACxB,4FA1BiC,sBAAW,OA0BjC;AAxBb,MAAM,SAAS,GAAG,kBAAK,CAAC;AAgBtB,8BAAS;AAdX,MAAM,cAAc,GAAG,EAAE,IAAI,EAAE,kBAAI,EAAE,CAAC;AAmBpC,wCAAc"}
@@ -10,7 +10,11 @@ import { rectangle, ellipse } from './shapes/rectAndEllipse.js';
10
10
  import { convertForPdfLayoutProps, rotatePoint } from './utils.js';
11
11
  const tableBeta = table;
12
12
  const builtInPlugins = { Text: text };
13
- export { multiVariableText, text, readOnlyText, image, readOnlyImage, svg, readOnlySvg, barcodes, line, tableBeta, rectangle, ellipse,
13
+ export {
14
+ // TODO remove
15
+ readOnlyText, readOnlyImage, readOnlySvg,
16
+ // schemas
17
+ multiVariableText, text, image, svg, barcodes, line, tableBeta, table, rectangle, ellipse,
14
18
  // utils
15
19
  builtInPlugins, getDynamicHeightsForTable, convertForPdfLayoutProps, rotatePoint, };
16
20
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,iBAAiB,MAAM,8BAA8B,CAAC;AAC7D,OAAO,IAAI,EAAE,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AACrD,OAAO,KAAK,EAAE,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAC3D,OAAO,GAAG,EAAE,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AACrD,OAAO,QAAQ,MAAM,qBAAqB,CAAC;AAC3C,OAAO,IAAI,MAAM,kBAAkB,CAAC;AACpC,OAAO,KAAK,MAAM,mBAAmB,CAAC;AACtC,OAAO,EAAE,yBAAyB,EAAE,MAAM,6BAA6B,CAAC;AACxE,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM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EACJ,SAAS,EACT,KAAK,EACL,SAAS,EACT,OAAO;AACP,QAAQ;AACR,cAAc,EACd,yBAAyB,EACzB,wBAAwB,EACxB,WAAW,GACZ,CAAC"}
@@ -4,6 +4,7 @@ import image, { readOnlyImage } from './graphics/image.js';
4
4
  import svg, { readOnlySvg } from './graphics/svg.js';
5
5
  import barcodes from './barcodes/index.js';
6
6
  import line from './shapes/line.js';
7
+ import table from './tables/index.js';
7
8
  import { getDynamicHeightsForTable } from './tables/dynamicTemplate.js';
8
9
  import { rectangle, ellipse } from './shapes/rectAndEllipse.js';
9
10
  import { convertForPdfLayoutProps, rotatePoint } from './utils.js';
@@ -11,4 +12,4 @@ declare const tableBeta: import("@pdfme/common").Plugin<import("./tables/types.j
11
12
  declare const builtInPlugins: {
12
13
  Text: import("@pdfme/common").Plugin<import("./text/types.js").TextSchema>;
13
14
  };
14
- export { multiVariableText, text, readOnlyText, image, readOnlyImage, svg, readOnlySvg, barcodes, line, tableBeta, rectangle, ellipse, builtInPlugins, getDynamicHeightsForTable, convertForPdfLayoutProps, rotatePoint, };
15
+ export { readOnlyText, readOnlyImage, readOnlySvg, multiVariableText, text, image, svg, barcodes, line, tableBeta, table, rectangle, ellipse, builtInPlugins, getDynamicHeightsForTable, convertForPdfLayoutProps, rotatePoint, };
@@ -23,6 +23,11 @@ export declare const rectangle: {
23
23
  opacity?: number | undefined;
24
24
  readOnly?: boolean | undefined;
25
25
  required?: boolean | undefined;
26
+ __bodyRange?: {
27
+ start: number;
28
+ end?: number | undefined;
29
+ } | undefined;
30
+ __isSplit?: boolean | undefined;
26
31
  };
27
32
  schema: ((propPanelProps: Omit<{
28
33
  rootElement: HTMLDivElement;
@@ -41,6 +46,11 @@ export declare const rectangle: {
41
46
  required?: boolean | undefined;
42
47
  content?: string | undefined;
43
48
  readOnly?: boolean | undefined;
49
+ __bodyRange?: {
50
+ start: number;
51
+ end?: number | undefined;
52
+ } | undefined;
53
+ __isSplit?: boolean | undefined;
44
54
  };
45
55
  activeElements: HTMLElement[];
46
56
  changeSchemas: import("@pdfme/common").ChangeSchemas;
@@ -59,6 +69,11 @@ export declare const rectangle: {
59
69
  required?: boolean | undefined;
60
70
  content?: string | undefined;
61
71
  readOnly?: boolean | undefined;
72
+ __bodyRange?: {
73
+ start: number;
74
+ end?: number | undefined;
75
+ } | undefined;
76
+ __isSplit?: boolean | undefined;
62
77
  }[];
63
78
  options: import("@pdfme/common").UIOptions;
64
79
  theme: import("antd").GlobalToken;
@@ -89,6 +104,11 @@ export declare const ellipse: {
89
104
  opacity?: number | undefined;
90
105
  readOnly?: boolean | undefined;
91
106
  required?: boolean | undefined;
107
+ __bodyRange?: {
108
+ start: number;
109
+ end?: number | undefined;
110
+ } | undefined;
111
+ __isSplit?: boolean | undefined;
92
112
  };
93
113
  schema: ((propPanelProps: Omit<{
94
114
  rootElement: HTMLDivElement;
@@ -107,6 +127,11 @@ export declare const ellipse: {
107
127
  required?: boolean | undefined;
108
128
  content?: string | undefined;
109
129
  readOnly?: boolean | undefined;
130
+ __bodyRange?: {
131
+ start: number;
132
+ end?: number | undefined;
133
+ } | undefined;
134
+ __isSplit?: boolean | undefined;
110
135
  };
111
136
  activeElements: HTMLElement[];
112
137
  changeSchemas: import("@pdfme/common").ChangeSchemas;
@@ -125,6 +150,11 @@ export declare const ellipse: {
125
150
  required?: boolean | undefined;
126
151
  content?: string | undefined;
127
152
  readOnly?: boolean | undefined;
153
+ __bodyRange?: {
154
+ start: number;
155
+ end?: number | undefined;
156
+ } | undefined;
157
+ __isSplit?: boolean | undefined;
128
158
  }[];
129
159
  options: import("@pdfme/common").UIOptions;
130
160
  theme: import("antd").GlobalToken;
@@ -26,11 +26,6 @@ export interface TableSchema extends Schema {
26
26
  showHead: boolean;
27
27
  head: string[];
28
28
  headWidthPercentages: number[];
29
- __bodyRange?: {
30
- start: number;
31
- end?: number;
32
- };
33
- __isSplit?: boolean;
34
29
  tableStyles: {
35
30
  borderColor: string;
36
31
  borderWidth: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pdfme/schemas",
3
- "version": "4.4.2",
3
+ "version": "4.5.0-dev.2",
4
4
  "sideEffects": false,
5
5
  "author": "hand-dot",
6
6
  "license": "MIT",
package/src/index.ts CHANGED
@@ -14,16 +14,19 @@ const tableBeta = table;
14
14
  const builtInPlugins = { Text: text };
15
15
 
16
16
  export {
17
+ // TODO remove
18
+ readOnlyText,
19
+ readOnlyImage,
20
+ readOnlySvg,
21
+ // schemas
17
22
  multiVariableText,
18
23
  text,
19
- readOnlyText,
20
24
  image,
21
- readOnlyImage,
22
25
  svg,
23
- readOnlySvg,
24
26
  barcodes,
25
27
  line,
26
28
  tableBeta,
29
+ table,
27
30
  rectangle,
28
31
  ellipse,
29
32
  // utils
@@ -26,10 +26,6 @@ export interface TableSchema extends Schema {
26
26
  head: string[];
27
27
  headWidthPercentages: number[];
28
28
 
29
- __bodyRange?: { start: number; end?: number };
30
-
31
- __isSplit?: boolean;
32
-
33
29
  tableStyles: {
34
30
  borderColor: string;
35
31
  borderWidth: number;