@senlinz/import-export 0.1.0-beta.11 → 0.1.0-beta.12

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.
@@ -25,8 +25,8 @@ interface ExcelColumnDefinition {
25
25
  bold?: boolean;
26
26
  format?: ExcelCellFormatDefinition;
27
27
  valueFormat?: ExcelCellFormatDefinition[] | ExcelCellFormatDefinition;
28
- dataGroup: string;
29
- dataGroupParent: string;
28
+ dataGroup?: string;
29
+ dataGroupParent?: string;
30
30
  }
31
31
  interface ExcelCellFormatDefinition {
32
32
  rule?: 'default' | 'eq';
@@ -1,6 +1,6 @@
1
1
  export type * from './components.d.ts';
2
2
  import { ExcelDefinition } from './declarations/ExcelDefinition.js';
3
- import { importExcel, exportExcel, downloadExcelTemplate, fromExcel, toExcel, generateExcelTemplate, mapRowData } from './utils.js';
3
+ import { importExcel, exportExcel, downloadExcelTemplate, fromExcel, toExcel, generateExcelTemplate } from './utils.js';
4
4
  declare function getUtils(): {
5
5
  importExcel: typeof importExcel;
6
6
  exportExcel: typeof exportExcel;
@@ -8,9 +8,10 @@ declare function getUtils(): {
8
8
  fromExcel: typeof fromExcel;
9
9
  toExcel: typeof toExcel;
10
10
  generateExcelTemplate: typeof generateExcelTemplate;
11
- mapRowData: typeof mapRowData;
12
11
  };
13
12
  declare function _importExcel<T>(defintion: ExcelDefinition): Promise<T[]>;
14
13
  declare function _exportExcel<T>(defintion: ExcelDefinition, data: T[]): Promise<void>;
14
+ declare function _fromExcel<T>(definition: ExcelDefinition, buffer: Uint8Array): Promise<T[]>;
15
+ declare function _toExcel<T>(definition: ExcelDefinition, data: T[]): Promise<Uint8Array>;
15
16
  declare function _downloadExcelTemplate(defintion: ExcelDefinition): Promise<void>;
16
- export { getUtils, _importExcel as importExcel, _exportExcel as exportExcel, _downloadExcelTemplate as downloadExcelTemplate };
17
+ export { getUtils, _importExcel as importExcel, _exportExcel as exportExcel, _fromExcel as fromExcel, _toExcel as toExcel, _downloadExcelTemplate as downloadExcelTemplate };
@@ -1,13 +1,10 @@
1
1
  import { ExcelDefinition } from './declarations/ExcelDefinition';
2
2
  declare function initializeWasm(): void;
3
3
  declare function fromExcel<T>(definition: ExcelDefinition, buffer: Uint8Array): Promise<T[]>;
4
- declare function mapRowData(item: any, childrenFields: string[]): {
5
- root: any[];
6
- };
7
4
  declare function toExcel<T>(definition: ExcelDefinition, data: T[]): Promise<Uint8Array>;
8
5
  declare function generateExcelTemplate(definition: ExcelDefinition): Promise<Uint8Array>;
9
6
  declare function downloadExcelTemplate(definition: ExcelDefinition): Promise<void>;
10
7
  declare function download(data: Uint8Array | string, name: string, type?: string): void;
11
8
  declare function importExcel<T>(defintion: ExcelDefinition): Promise<T[]>;
12
9
  declare function exportExcel<T>(definition: ExcelDefinition, data: T[]): Promise<void>;
13
- export { importExcel, exportExcel, downloadExcelTemplate, fromExcel, toExcel, generateExcelTemplate, initializeWasm, download, mapRowData };
10
+ export { importExcel, exportExcel, downloadExcelTemplate, fromExcel, toExcel, generateExcelTemplate, initializeWasm, download };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@senlinz/import-export",
3
- "version": "0.1.0-beta.11",
3
+ "version": "0.1.0-beta.12",
4
4
  "description": "Stencil Component for import/export excel files.",
5
5
  "module": "dist/components/index.js",
6
6
  "types": "dist/types/index.d.ts",
@@ -12,11 +12,11 @@
12
12
  "exports": {
13
13
  ".": {
14
14
  "import": "./dist/components/index.js",
15
- "types": "./dist/components/index.d.ts"
15
+ "types": "./dist/types/index.d.ts"
16
16
  },
17
17
  "./components/import-export-studio.js": {
18
18
  "import": "./dist/components/import-export-studio.js",
19
- "types": "./dist/components/import-export-studio.d.ts"
19
+ "types": "./dist/types/components/import-export-studio.d.ts"
20
20
  }
21
21
  },
22
22
  "devDependencies": {
@@ -35,7 +35,7 @@
35
35
  },
36
36
  "dependencies": {
37
37
  "fflate": "^0.8.2",
38
- "@senlinz/import-export-wasm": "0.1.0-beta.11"
38
+ "@senlinz/import-export-wasm": "0.1.0-beta.12"
39
39
  },
40
40
  "keywords": [
41
41
  "stencil",