@deckflow/office2html 0.3.5 → 0.3.7
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.
- package/LICENSE +4 -4
- package/README.md +31 -14
- package/index.d.ts +1 -26
- package/index.js +1 -36
- package/package.json +5 -8
package/LICENSE
CHANGED
|
@@ -5,10 +5,10 @@ Copyright (c) 2026 Deckflow. All Rights Reserved.
|
|
|
5
5
|
版权所有 (c) 2026 Deckflow。保留一切权利。
|
|
6
6
|
|
|
7
7
|
This software and associated documentation files (the "Software"), including
|
|
8
|
-
the npm packages @deckflow/
|
|
8
|
+
the npm packages @deckflow/deck2html and its platform-specific optional
|
|
9
9
|
dependencies, are proprietary and confidential.
|
|
10
10
|
|
|
11
|
-
本软件及相关文档(统称「软件」),包括 npm 包 @deckflow/
|
|
11
|
+
本软件及相关文档(统称「软件」),包括 npm 包 @deckflow/deck2html
|
|
12
12
|
及其各平台可选依赖子包,均为专有且保密的信息。
|
|
13
13
|
|
|
14
14
|
Unless you have obtained prior written authorization from the copyright holder,
|
|
@@ -53,12 +53,12 @@ without separate written authorization:
|
|
|
53
53
|
2. Use through @deckflow/render
|
|
54
54
|
通过 @deckflow/render 使用
|
|
55
55
|
End users may rely on the Software only as functionality provided by
|
|
56
|
-
@deckflow/render. Direct standalone installation of @deckflow/
|
|
56
|
+
@deckflow/render. Direct standalone installation of @deckflow/deck2html
|
|
57
57
|
(or its platform packages), or direct use of its CLI or programmatic
|
|
58
58
|
APIs outside the @deckflow/render dependency tree, remains prohibited
|
|
59
59
|
unless separately authorized in writing.
|
|
60
60
|
终端用户仅可将本软件作为 @deckflow/render 所提供功能的一部分加以使用。
|
|
61
|
-
在 @deckflow/render 依赖树之外单独安装 @deckflow/
|
|
61
|
+
在 @deckflow/render 依赖树之外单独安装 @deckflow/deck2html
|
|
62
62
|
(或其平台子包),或直接调用其 CLI 或编程接口,仍须另行获得书面授权。
|
|
63
63
|
|
|
64
64
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
package/README.md
CHANGED
|
@@ -1,14 +1,39 @@
|
|
|
1
|
-
# @deckflow/office2html
|
|
1
|
+
# @deckflow/office2html (deprecated)
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
**This package is deprecated.** Use [`@deckflow/deck2html`](https://www.npmjs.com/package/@deckflow/deck2html) instead.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
`@deckflow/office2html` is a thin compatibility shim that re-exports `@deckflow/deck2html`. Existing installs and the `office2html` CLI binary continue to work, but new projects should depend on the renamed package.
|
|
6
|
+
|
|
7
|
+
## Migrate
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
npm uninstall @deckflow/office2html
|
|
11
|
+
npm install @deckflow/deck2html
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
```bash
|
|
15
|
+
# before
|
|
16
|
+
npx office2html deck.pptx -o ./out
|
|
17
|
+
|
|
18
|
+
# after
|
|
19
|
+
npx deck2html deck.pptx -o ./out
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
```js
|
|
23
|
+
// before
|
|
24
|
+
const { getBinaryPath } = require('@deckflow/office2html');
|
|
25
|
+
|
|
26
|
+
// after
|
|
27
|
+
const { getBinaryPath } = require('@deckflow/deck2html');
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
## Install (compat)
|
|
6
31
|
|
|
7
32
|
```bash
|
|
8
33
|
npm install @deckflow/office2html
|
|
9
34
|
```
|
|
10
35
|
|
|
11
|
-
Do not omit optional dependencies (`--omit=optional` / `--no-optional`)
|
|
36
|
+
This installs `@deckflow/deck2html` (and its platform optional dependencies) transitively. Do not omit optional dependencies (`--omit=optional` / `--no-optional`).
|
|
12
37
|
|
|
13
38
|
## Usage
|
|
14
39
|
|
|
@@ -23,18 +48,10 @@ const { getBinaryPath } = require('@deckflow/office2html');
|
|
|
23
48
|
// spawn the native CLI at getBinaryPath()
|
|
24
49
|
```
|
|
25
50
|
|
|
26
|
-
## Supported platforms
|
|
27
|
-
|
|
28
|
-
| Package | OS | CPU |
|
|
29
|
-
|---|---|---|
|
|
30
|
-
| `@deckflow/office2html-darwin-arm64` | macOS | arm64 |
|
|
31
|
-
| `@deckflow/office2html-darwin-x64` | macOS | x64 |
|
|
32
|
-
| `@deckflow/office2html-linux-x64` | Linux | x64 |
|
|
33
|
-
| `@deckflow/office2html-win32-x64` | Windows | x64 |
|
|
34
|
-
|
|
35
51
|
## Links
|
|
36
52
|
|
|
37
|
-
-
|
|
53
|
+
- Replacement: https://www.npmjs.com/package/@deckflow/deck2html
|
|
54
|
+
- This package: https://www.npmjs.com/package/@deckflow/office2html
|
|
38
55
|
|
|
39
56
|
## License
|
|
40
57
|
|
package/index.d.ts
CHANGED
|
@@ -1,26 +1 @@
|
|
|
1
|
-
export
|
|
2
|
-
/** Output directory (CLI -o/--output). */
|
|
3
|
-
output: string;
|
|
4
|
-
verbose?: boolean;
|
|
5
|
-
noPlayer?: boolean;
|
|
6
|
-
notes?: boolean;
|
|
7
|
-
includeHiddenSlides?: boolean;
|
|
8
|
-
/** Emit slide masters under masters/ (not in player navigation). */
|
|
9
|
-
includeMasters?: boolean;
|
|
10
|
-
/** Emit slide layouts under layouts/ (not in player navigation). */
|
|
11
|
-
includeLayouts?: boolean;
|
|
12
|
-
/** 1-based page filter, e.g. "1,2,5-10". */
|
|
13
|
-
pages?: string;
|
|
14
|
-
noLazySlides?: boolean;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
export interface ConvertResult {
|
|
18
|
-
indexHtmlPath: string;
|
|
19
|
-
exitCode: number;
|
|
20
|
-
stdout: string;
|
|
21
|
-
stderr: string;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
export function getBinaryPath(): string;
|
|
25
|
-
export function convert(pptxPath: string, options: ConvertOptions): Promise<ConvertResult>;
|
|
26
|
-
export function convertSync(pptxPath: string, options: ConvertOptions): ConvertResult;
|
|
1
|
+
export * from '@deckflow/deck2html';
|
package/index.js
CHANGED
|
@@ -1,38 +1,3 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
'darwin arm64': '@deckflow/office2html-darwin-arm64',
|
|
5
|
-
'darwin x64': '@deckflow/office2html-darwin-x64',
|
|
6
|
-
'linux x64': '@deckflow/office2html-linux-x64',
|
|
7
|
-
'win32 x64': '@deckflow/office2html-win32-x64',
|
|
8
|
-
};
|
|
9
|
-
|
|
10
|
-
function pkgForCurrentPlatform() {
|
|
11
|
-
const key = `${process.platform} ${process.arch}`;
|
|
12
|
-
const pkg = knownPackages[key];
|
|
13
|
-
if (!pkg) {
|
|
14
|
-
throw new Error(
|
|
15
|
-
`Unsupported platform: ${key}. Supported: ${Object.keys(knownPackages).join(', ')}`,
|
|
16
|
-
);
|
|
17
|
-
}
|
|
18
|
-
return pkg;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
let platformModule;
|
|
22
|
-
try {
|
|
23
|
-
const pkg = pkgForCurrentPlatform();
|
|
24
|
-
require.resolve(pkg);
|
|
25
|
-
platformModule = require(pkg);
|
|
26
|
-
} catch (err) {
|
|
27
|
-
const pkg = pkgForCurrentPlatform();
|
|
28
|
-
const hint =
|
|
29
|
-
'Install with optional dependencies enabled (avoid --omit=optional / --no-optional).';
|
|
30
|
-
if (err && err.code === 'MODULE_NOT_FOUND') {
|
|
31
|
-
throw new Error(
|
|
32
|
-
`Platform package "${pkg}" is not installed for ${process.platform} ${process.arch}. ${hint}`,
|
|
33
|
-
);
|
|
34
|
-
}
|
|
35
|
-
throw err;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
module.exports = platformModule;
|
|
3
|
+
module.exports = require('@deckflow/deck2html');
|
package/package.json
CHANGED
|
@@ -1,13 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@deckflow/office2html",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.7",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE",
|
|
5
|
-
"description": "
|
|
6
|
-
"
|
|
7
|
-
"@deckflow/
|
|
8
|
-
"@deckflow/office2html-darwin-x64": "0.3.5",
|
|
9
|
-
"@deckflow/office2html-linux-x64": "0.3.5",
|
|
10
|
-
"@deckflow/office2html-win32-x64": "0.3.5"
|
|
5
|
+
"description": "Deprecated alias for @deckflow/deck2html (proprietary; authorized use via @deckflow/render)",
|
|
6
|
+
"dependencies": {
|
|
7
|
+
"@deckflow/deck2html": "^0.3.6"
|
|
11
8
|
},
|
|
12
9
|
"main": "index.js",
|
|
13
10
|
"types": "index.d.ts",
|
|
@@ -27,4 +24,4 @@
|
|
|
27
24
|
"default": "./index.js"
|
|
28
25
|
}
|
|
29
26
|
}
|
|
30
|
-
}
|
|
27
|
+
}
|