@vivliostyle/cli 4.8.4 → 4.11.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.
- package/README.md +1 -1
- package/dist/browser.js +2 -3
- package/dist/browser.js.map +1 -1
- package/dist/build.d.ts.map +1 -1
- package/dist/build.js +52 -49
- package/dist/build.js.map +1 -1
- package/dist/builder.d.ts +2 -2
- package/dist/builder.d.ts.map +1 -1
- package/dist/builder.js +15 -5
- package/dist/builder.js.map +1 -1
- package/dist/commands/build.js +3 -1
- package/dist/commands/build.js.map +1 -1
- package/dist/commands/build.parser.js +1 -1
- package/dist/commands/init.js +3 -1
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/preview.js +3 -1
- package/dist/commands/preview.js.map +1 -1
- package/dist/config.d.ts +3 -3
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +31 -4
- package/dist/config.js.map +1 -1
- package/dist/container.d.ts +0 -1
- package/dist/container.d.ts.map +1 -1
- package/dist/container.js +1 -6
- package/dist/container.js.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/init.d.ts.map +1 -1
- package/dist/init.js +15 -1
- package/dist/init.js.map +1 -1
- package/dist/pdf.d.ts.map +1 -1
- package/dist/pdf.js +3 -3
- package/dist/pdf.js.map +1 -1
- package/dist/postprocess.d.ts.map +1 -1
- package/dist/postprocess.js +1 -1
- package/dist/postprocess.js.map +1 -1
- package/dist/preview.d.ts.map +1 -1
- package/dist/preview.js +5 -3
- package/dist/preview.js.map +1 -1
- package/dist/schema/{pubManifest.schema.d.ts → pubManifest.d.ts} +3 -2
- package/dist/schema/{pubManifest.schema.d.ts.map → pubManifest.d.ts.map} +1 -1
- package/dist/schema/{pubManifest.schema.js → pubManifest.js} +3 -3
- package/dist/schema/pubManifest.js.map +1 -0
- package/dist/schema/publication.schema.d.ts +104 -0
- package/dist/schema/publication.schema.d.ts.map +1 -0
- package/dist/schema/publication.schema.js +9 -0
- package/dist/schema/publication.schema.js.map +1 -0
- package/dist/schema/{vivliostyle.config.schema.json → vivliostyle/vivliostyleConfig.schema.json} +103 -19
- package/dist/schema/vivliostyle.d.ts +3 -0
- package/dist/schema/vivliostyle.d.ts.map +1 -0
- package/dist/schema/vivliostyle.js +9 -0
- package/dist/schema/vivliostyle.js.map +1 -0
- package/dist/schema/vivliostyleConfig.schema.d.ts +147 -0
- package/dist/schema/vivliostyleConfig.schema.d.ts.map +1 -0
- package/dist/schema/vivliostyleConfig.schema.js +9 -0
- package/dist/schema/vivliostyleConfig.schema.js.map +1 -0
- package/dist/util.d.ts +9 -2
- package/dist/util.d.ts.map +1 -1
- package/dist/util.js +87 -10
- package/dist/util.js.map +1 -1
- package/package.json +6 -5
- package/dist/schema/pubManifest.schema.js.map +0 -1
package/dist/schema/{vivliostyle.config.schema.json → vivliostyle/vivliostyleConfig.schema.json}
RENAMED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"type": "string",
|
|
5
5
|
"minLength": 1
|
|
6
6
|
},
|
|
7
|
-
"
|
|
7
|
+
"articleEntryObject": {
|
|
8
8
|
"type": "object",
|
|
9
9
|
"properties": {
|
|
10
10
|
"path": { "type": "string" },
|
|
@@ -34,6 +34,12 @@
|
|
|
34
34
|
"required": ["rel"],
|
|
35
35
|
"additionalProperties": false
|
|
36
36
|
},
|
|
37
|
+
"entryObject": {
|
|
38
|
+
"oneOf": [
|
|
39
|
+
{ "$ref": "#/definitions/contentsEntryObject" },
|
|
40
|
+
{ "$ref": "#/definitions/articleEntryObject" }
|
|
41
|
+
]
|
|
42
|
+
},
|
|
37
43
|
"output": {
|
|
38
44
|
"type": "string",
|
|
39
45
|
"minLength": 1
|
|
@@ -41,11 +47,26 @@
|
|
|
41
47
|
"outputObject": {
|
|
42
48
|
"type": "object",
|
|
43
49
|
"properties": {
|
|
44
|
-
"path": {
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
50
|
+
"path": {
|
|
51
|
+
"description": "Specify output file name or directory [<title>.pdf].",
|
|
52
|
+
"type": "string"
|
|
53
|
+
},
|
|
54
|
+
"format": {
|
|
55
|
+
"description": "Specify output format.",
|
|
56
|
+
"type": "string"
|
|
57
|
+
},
|
|
58
|
+
"renderMode": {
|
|
59
|
+
"description": "if docker is set, Vivliostyle try to render PDF on Docker container [local].",
|
|
60
|
+
"type": "string",
|
|
61
|
+
"enum": ["local", "docker"]
|
|
62
|
+
},
|
|
63
|
+
"preflight": {
|
|
64
|
+
"description": "Apply the process to generate PDF for printing.",
|
|
65
|
+
"type": "string",
|
|
66
|
+
"enum": ["press-ready", "press-ready-local"]
|
|
67
|
+
},
|
|
48
68
|
"preflightOption": {
|
|
69
|
+
"description": "Options for preflight process (ex: gray-scale, enforce-outline). Please refer the document of press-ready for further information. https://github.com/vibranthq/press-ready",
|
|
49
70
|
"type": "array",
|
|
50
71
|
"items": { "type": "string" }
|
|
51
72
|
}
|
|
@@ -53,7 +74,22 @@
|
|
|
53
74
|
"required": ["path"],
|
|
54
75
|
"additionalProperties": false
|
|
55
76
|
},
|
|
56
|
-
"
|
|
77
|
+
"vfmReplaceRule": {
|
|
78
|
+
"type": "object",
|
|
79
|
+
"properties": {
|
|
80
|
+
"test": {
|
|
81
|
+
"type": "object",
|
|
82
|
+
"tsType": "RegExp"
|
|
83
|
+
},
|
|
84
|
+
"match": {
|
|
85
|
+
"instanceOf": "Function",
|
|
86
|
+
"tsType": "(result: RegExpMatchArray, h: any) => Object | string"
|
|
87
|
+
}
|
|
88
|
+
},
|
|
89
|
+
"required": ["test", "match"],
|
|
90
|
+
"additionalProperties": false
|
|
91
|
+
},
|
|
92
|
+
"vivliostyleConfigEntry": {
|
|
57
93
|
"type": "object",
|
|
58
94
|
"properties": {
|
|
59
95
|
"title": {
|
|
@@ -82,27 +118,29 @@
|
|
|
82
118
|
]
|
|
83
119
|
},
|
|
84
120
|
"entry": {
|
|
121
|
+
"description": "Entry file(s) of document.",
|
|
85
122
|
"oneOf": [
|
|
123
|
+
{ "$ref": "#/definitions/entry" },
|
|
124
|
+
{ "$ref": "#/definitions/articleEntryObject" },
|
|
86
125
|
{
|
|
87
126
|
"type": "array",
|
|
88
127
|
"items": {
|
|
89
128
|
"oneOf": [
|
|
90
129
|
{ "$ref": "#/definitions/entry" },
|
|
91
|
-
{ "$ref": "#/definitions/entryObject" }
|
|
92
|
-
{ "$ref": "#/definitions/contentsEntryObject" }
|
|
130
|
+
{ "$ref": "#/definitions/entryObject" }
|
|
93
131
|
]
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
{ "$ref": "#/definitions/entryObject" }
|
|
132
|
+
},
|
|
133
|
+
"uniqueItems": true
|
|
134
|
+
}
|
|
98
135
|
]
|
|
99
136
|
},
|
|
100
137
|
"entryContext": {
|
|
138
|
+
"description": "Directory of referencing entry file(s).",
|
|
101
139
|
"type": "string",
|
|
102
|
-
"description": "",
|
|
103
140
|
"minLength": 1
|
|
104
141
|
},
|
|
105
142
|
"output": {
|
|
143
|
+
"description": "Options about outputs.",
|
|
106
144
|
"oneOf": [
|
|
107
145
|
{
|
|
108
146
|
"type": "array",
|
|
@@ -132,14 +170,16 @@
|
|
|
132
170
|
]
|
|
133
171
|
},
|
|
134
172
|
"size": {
|
|
173
|
+
"description": "Output pdf size [Letter]. preset: A5, A4, A3, B5, B4, JIS-B5, JIS-B4, letter, legal, ledger. custom(comma separated): 182mm,257mm or 8.5in,11in.",
|
|
135
174
|
"type": "string",
|
|
136
|
-
"description": "",
|
|
137
175
|
"minLength": 1
|
|
138
176
|
},
|
|
139
177
|
"pressReady": {
|
|
178
|
+
"description": "Make generated PDF compatible with press ready PDF/X-1a [false]. This option is equivalent with \"preflight\": \"press-ready\"",
|
|
140
179
|
"type": "boolean"
|
|
141
180
|
},
|
|
142
181
|
"language": {
|
|
182
|
+
"description": "Language",
|
|
143
183
|
"type": "string",
|
|
144
184
|
"minLength": 1
|
|
145
185
|
},
|
|
@@ -166,38 +206,82 @@
|
|
|
166
206
|
"minLength": 1
|
|
167
207
|
},
|
|
168
208
|
"timeout": {
|
|
209
|
+
"description": "Timeout limit for waiting Vivliostyle process [120000]",
|
|
169
210
|
"type": "number",
|
|
170
211
|
"minimum": 0
|
|
171
212
|
},
|
|
172
213
|
"vfm": {
|
|
214
|
+
"description": "Option for convert Markdown to a stringify (HTML).",
|
|
173
215
|
"type": "object",
|
|
174
216
|
"properties": {
|
|
217
|
+
"style": {
|
|
218
|
+
"description": "Custom stylesheet path/URL.",
|
|
219
|
+
"type": ["string", "array"],
|
|
220
|
+
"items": {
|
|
221
|
+
"type": "string"
|
|
222
|
+
}
|
|
223
|
+
},
|
|
224
|
+
"partial": {
|
|
225
|
+
"description": "Output markdown fragments.",
|
|
226
|
+
"type": "boolean"
|
|
227
|
+
},
|
|
228
|
+
"title": {
|
|
229
|
+
"description": "Document title (ignored in partial mode).",
|
|
230
|
+
"type": "string"
|
|
231
|
+
},
|
|
232
|
+
"language": {
|
|
233
|
+
"description": "Document language (ignored in partial mode).",
|
|
234
|
+
"type": "string"
|
|
235
|
+
},
|
|
236
|
+
"replace": {
|
|
237
|
+
"description": "Replacement handler for HTML string.",
|
|
238
|
+
"type": "array",
|
|
239
|
+
"items": {
|
|
240
|
+
"$ref": "#/definitions/vfmReplaceRule"
|
|
241
|
+
}
|
|
242
|
+
},
|
|
175
243
|
"hardLineBreaks": {
|
|
244
|
+
"description": "Add `<br>` at the position of hard line breaks, without needing spaces.",
|
|
176
245
|
"type": "boolean"
|
|
177
246
|
},
|
|
178
247
|
"disableFormatHtml": {
|
|
248
|
+
"description": "Disable automatic HTML format.",
|
|
249
|
+
"type": "boolean"
|
|
250
|
+
},
|
|
251
|
+
"math": {
|
|
252
|
+
"description": "Enable math syntax.",
|
|
179
253
|
"type": "boolean"
|
|
180
254
|
}
|
|
181
|
-
}
|
|
182
|
-
"additionalProperties": false
|
|
255
|
+
}
|
|
183
256
|
},
|
|
184
257
|
"image": {
|
|
258
|
+
"description": "Specify a docker image to render.",
|
|
185
259
|
"type": "string",
|
|
186
260
|
"minLength": 1
|
|
187
261
|
},
|
|
188
262
|
"http": {
|
|
263
|
+
"description": "Launch an HTTP server hosting contents instead of file protocol. It is useful that requires CORS such as external web fonts.",
|
|
189
264
|
"type": "boolean"
|
|
190
265
|
},
|
|
191
266
|
"viewer": {
|
|
267
|
+
"description": "Specify a URL of displaying viewer instead of vivliostyle-cli's one. It is useful that using own viewer that has staging features. (ex: https://vivliostyle.vercel.app/)",
|
|
192
268
|
"type": "string",
|
|
193
269
|
"minLength": 1
|
|
194
270
|
}
|
|
195
|
-
}
|
|
271
|
+
},
|
|
272
|
+
"required": ["entry"]
|
|
196
273
|
}
|
|
197
274
|
},
|
|
198
|
-
"
|
|
275
|
+
"oneOf": [
|
|
199
276
|
{
|
|
200
|
-
"$ref": "#/definitions/
|
|
277
|
+
"$ref": "#/definitions/vivliostyleConfigEntry"
|
|
278
|
+
},
|
|
279
|
+
{
|
|
280
|
+
"type": "array",
|
|
281
|
+
"items": {
|
|
282
|
+
"$ref": "#/definitions/vivliostyleConfigEntry"
|
|
283
|
+
},
|
|
284
|
+
"minItems": 1
|
|
201
285
|
}
|
|
202
286
|
]
|
|
203
287
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"vivliostyle.d.ts","sourceRoot":"","sources":["../../src/schema/vivliostyle.ts"],"names":[],"mappings":"AAAA,OAAO,uBAAuB,MAAM,6CAA6C,CAAC;AAClF,OAAO,EAAE,uBAAuB,EAAE,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.vivliostyleConfigSchema = void 0;
|
|
7
|
+
const vivliostyleConfig_schema_json_1 = __importDefault(require("./vivliostyle/vivliostyleConfig.schema.json"));
|
|
8
|
+
exports.vivliostyleConfigSchema = vivliostyleConfig_schema_json_1.default;
|
|
9
|
+
//# sourceMappingURL=vivliostyle.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"vivliostyle.js","sourceRoot":"","sources":["../../src/schema/vivliostyle.ts"],"names":[],"mappings":";;;;;;AAAA,gHAAkF;AACzE,kCADF,uCAAuB,CACE"}
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was automatically generated by json-schema-to-typescript.
|
|
3
|
+
* DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file,
|
|
4
|
+
* and run json-schema-to-typescript to regenerate this file.
|
|
5
|
+
*/
|
|
6
|
+
export declare type VivliostyleConfigSchema = VivliostyleConfigEntry | [VivliostyleConfigEntry, ...VivliostyleConfigEntry[]];
|
|
7
|
+
export declare type Entry = string;
|
|
8
|
+
export declare type EntryObject = ContentsEntryObject | ArticleEntryObject;
|
|
9
|
+
export declare type Output = string;
|
|
10
|
+
export interface VivliostyleConfigEntry {
|
|
11
|
+
/**
|
|
12
|
+
* Title
|
|
13
|
+
*/
|
|
14
|
+
title?: string;
|
|
15
|
+
/**
|
|
16
|
+
* Author
|
|
17
|
+
*/
|
|
18
|
+
author?: string;
|
|
19
|
+
/**
|
|
20
|
+
* Theme package path or URL of css file.
|
|
21
|
+
*/
|
|
22
|
+
theme?: string;
|
|
23
|
+
/**
|
|
24
|
+
* Entry file(s) of document.
|
|
25
|
+
*/
|
|
26
|
+
entry: Entry | ArticleEntryObject | (Entry | EntryObject)[];
|
|
27
|
+
/**
|
|
28
|
+
* Directory of referencing entry file(s).
|
|
29
|
+
*/
|
|
30
|
+
entryContext?: string;
|
|
31
|
+
/**
|
|
32
|
+
* Options about outputs.
|
|
33
|
+
*/
|
|
34
|
+
output?: (Output | OutputObject)[] | Output | OutputObject;
|
|
35
|
+
workspaceDir?: string;
|
|
36
|
+
includeAssets?: Entry[] | Entry;
|
|
37
|
+
/**
|
|
38
|
+
* Output pdf size [Letter]. preset: A5, A4, A3, B5, B4, JIS-B5, JIS-B4, letter, legal, ledger. custom(comma separated): 182mm,257mm or 8.5in,11in.
|
|
39
|
+
*/
|
|
40
|
+
size?: string;
|
|
41
|
+
/**
|
|
42
|
+
* Make generated PDF compatible with press ready PDF/X-1a [false]. This option is equivalent with "preflight": "press-ready"
|
|
43
|
+
*/
|
|
44
|
+
pressReady?: boolean;
|
|
45
|
+
/**
|
|
46
|
+
* Language
|
|
47
|
+
*/
|
|
48
|
+
language?: string;
|
|
49
|
+
readingProgression?: 'ltr' | 'rtl';
|
|
50
|
+
toc?: boolean | string;
|
|
51
|
+
tocTitle?: string;
|
|
52
|
+
cover?: string;
|
|
53
|
+
/**
|
|
54
|
+
* Timeout limit for waiting Vivliostyle process [120000]
|
|
55
|
+
*/
|
|
56
|
+
timeout?: number;
|
|
57
|
+
/**
|
|
58
|
+
* Option for convert Markdown to a stringify (HTML).
|
|
59
|
+
*/
|
|
60
|
+
vfm?: {
|
|
61
|
+
/**
|
|
62
|
+
* Custom stylesheet path/URL.
|
|
63
|
+
*/
|
|
64
|
+
style?: string | string[];
|
|
65
|
+
/**
|
|
66
|
+
* Output markdown fragments.
|
|
67
|
+
*/
|
|
68
|
+
partial?: boolean;
|
|
69
|
+
/**
|
|
70
|
+
* Document title (ignored in partial mode).
|
|
71
|
+
*/
|
|
72
|
+
title?: string;
|
|
73
|
+
/**
|
|
74
|
+
* Document language (ignored in partial mode).
|
|
75
|
+
*/
|
|
76
|
+
language?: string;
|
|
77
|
+
/**
|
|
78
|
+
* Replacement handler for HTML string.
|
|
79
|
+
*/
|
|
80
|
+
replace?: VfmReplaceRule[];
|
|
81
|
+
/**
|
|
82
|
+
* Add `<br>` at the position of hard line breaks, without needing spaces.
|
|
83
|
+
*/
|
|
84
|
+
hardLineBreaks?: boolean;
|
|
85
|
+
/**
|
|
86
|
+
* Disable automatic HTML format.
|
|
87
|
+
*/
|
|
88
|
+
disableFormatHtml?: boolean;
|
|
89
|
+
/**
|
|
90
|
+
* Enable math syntax.
|
|
91
|
+
*/
|
|
92
|
+
math?: boolean;
|
|
93
|
+
[k: string]: unknown;
|
|
94
|
+
};
|
|
95
|
+
/**
|
|
96
|
+
* Specify a docker image to render.
|
|
97
|
+
*/
|
|
98
|
+
image?: string;
|
|
99
|
+
/**
|
|
100
|
+
* Launch an HTTP server hosting contents instead of file protocol. It is useful that requires CORS such as external web fonts.
|
|
101
|
+
*/
|
|
102
|
+
http?: boolean;
|
|
103
|
+
/**
|
|
104
|
+
* Specify a URL of displaying viewer instead of vivliostyle-cli's one. It is useful that using own viewer that has staging features. (ex: https://vivliostyle.vercel.app/)
|
|
105
|
+
*/
|
|
106
|
+
viewer?: string;
|
|
107
|
+
[k: string]: unknown;
|
|
108
|
+
}
|
|
109
|
+
export interface ArticleEntryObject {
|
|
110
|
+
path: string;
|
|
111
|
+
title?: string;
|
|
112
|
+
theme?: string;
|
|
113
|
+
encodingFormat?: string;
|
|
114
|
+
rel?: string | string[];
|
|
115
|
+
}
|
|
116
|
+
export interface ContentsEntryObject {
|
|
117
|
+
rel: 'contents';
|
|
118
|
+
title?: string;
|
|
119
|
+
theme?: string;
|
|
120
|
+
}
|
|
121
|
+
export interface OutputObject {
|
|
122
|
+
/**
|
|
123
|
+
* Specify output file name or directory [<title>.pdf].
|
|
124
|
+
*/
|
|
125
|
+
path: string;
|
|
126
|
+
/**
|
|
127
|
+
* Specify output format.
|
|
128
|
+
*/
|
|
129
|
+
format?: string;
|
|
130
|
+
/**
|
|
131
|
+
* if docker is set, Vivliostyle try to render PDF on Docker container [local].
|
|
132
|
+
*/
|
|
133
|
+
renderMode?: 'local' | 'docker';
|
|
134
|
+
/**
|
|
135
|
+
* Apply the process to generate PDF for printing.
|
|
136
|
+
*/
|
|
137
|
+
preflight?: 'press-ready' | 'press-ready-local';
|
|
138
|
+
/**
|
|
139
|
+
* Options for preflight process (ex: gray-scale, enforce-outline). Please refer the document of press-ready for further information. https://github.com/vibranthq/press-ready
|
|
140
|
+
*/
|
|
141
|
+
preflightOption?: string[];
|
|
142
|
+
}
|
|
143
|
+
export interface VfmReplaceRule {
|
|
144
|
+
test: RegExp;
|
|
145
|
+
match: (result: RegExpMatchArray, h: any) => Object | string;
|
|
146
|
+
}
|
|
147
|
+
//# sourceMappingURL=vivliostyleConfig.schema.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"vivliostyleConfig.schema.d.ts","sourceRoot":"","sources":["../../src/schema/vivliostyleConfig.schema.ts"],"names":[],"mappings":"AACA;;;;GAIG;AAEH,oBAAY,uBAAuB,GAC/B,sBAAsB,GACtB,CAAC,sBAAsB,EAAE,GAAG,sBAAsB,EAAE,CAAC,CAAC;AAC1D,oBAAY,KAAK,GAAG,MAAM,CAAC;AAC3B,oBAAY,WAAW,GAAG,mBAAmB,GAAG,kBAAkB,CAAC;AACnE,oBAAY,MAAM,GAAG,MAAM,CAAC;AAE5B,MAAM,WAAW,sBAAsB;IACrC;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,KAAK,EAAE,KAAK,GAAG,kBAAkB,GAAG,CAAC,KAAK,GAAG,WAAW,CAAC,EAAE,CAAC;IAC5D;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;OAEG;IACH,MAAM,CAAC,EAAE,CAAC,MAAM,GAAG,YAAY,CAAC,EAAE,GAAG,MAAM,GAAG,YAAY,CAAC;IAC3D,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,aAAa,CAAC,EAAE,KAAK,EAAE,GAAG,KAAK,CAAC;IAChC;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB;;OA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,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AACD,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IACb;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;OAEG;IACH,UAAU,CAAC,EAAE,OAAO,GAAG,QAAQ,CAAC;IAChC;;OAEG;IACH,SAAS,CAAC,EAAE,aAAa,GAAG,mBAAmB,CAAC;IAChD;;OAEG;IACH,eAAe,CAAC,EAAE,MAAM,EAAE,CAAC;CAC5B;AACD,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,CAAC,MAAM,EAAE,gBAAgB,EAAE,CAAC,EAAE,GAAG,KAAK,MAAM,GAAG,MAAM,CAAC;CAC9D"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/**
|
|
4
|
+
* This file was automatically generated by json-schema-to-typescript.
|
|
5
|
+
* DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file,
|
|
6
|
+
* and run json-schema-to-typescript to regenerate this file.
|
|
7
|
+
*/
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
//# sourceMappingURL=vivliostyleConfig.schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"vivliostyleConfig.schema.js","sourceRoot":"","sources":["../../src/schema/vivliostyleConfig.schema.ts"],"names":[],"mappings":";AAAA,oBAAoB;AACpB;;;;GAIG"}
|
package/dist/util.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
|
+
import { ErrorObject } from 'ajv';
|
|
2
3
|
import debugConstructor from 'debug';
|
|
3
4
|
import fs from 'fs';
|
|
4
5
|
export declare const debug: debugConstructor.Debugger;
|
|
@@ -11,13 +12,19 @@ export declare function logUpdate(...obj: string[]): void;
|
|
|
11
12
|
export declare function logSuccess(...obj: string[]): void;
|
|
12
13
|
export declare function logError(...obj: string[]): void;
|
|
13
14
|
export declare function logInfo(...obj: string[]): void;
|
|
14
|
-
export declare
|
|
15
|
+
export declare class DetailError extends Error {
|
|
16
|
+
detail: string | undefined;
|
|
17
|
+
constructor(message: string | undefined, detail: string | undefined);
|
|
18
|
+
}
|
|
19
|
+
export declare function gracefulError<T extends Error>(err: T): void;
|
|
20
|
+
export declare function filterRelevantAjvErrors(allErrors: ErrorObject[]): ErrorObject[];
|
|
15
21
|
export declare function readJSON(path: string): any;
|
|
16
|
-
export declare function
|
|
22
|
+
export declare function statFileSync(filePath: string): fs.Stats;
|
|
17
23
|
export declare function inflateZip(filePath: string, dest: string): Promise<void>;
|
|
18
24
|
export declare function useTmpDirectory(): Promise<[string, () => void]>;
|
|
19
25
|
export declare function touchTmpFile(path: string): Promise<() => void>;
|
|
20
26
|
export declare function pathStartsWith(path1: string, path2: string): boolean;
|
|
21
27
|
export declare function isUrlString(str: string): boolean;
|
|
22
28
|
export declare function findAvailablePort(): Promise<number>;
|
|
29
|
+
export declare function checkContainerEnvironment(): boolean;
|
|
23
30
|
//# sourceMappingURL=util.d.ts.map
|
package/dist/util.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../src/util.ts"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../src/util.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,KAAK,CAAC;AAElC,OAAO,gBAAgB,MAAM,OAAO,CAAC;AACrC,OAAO,EAAE,MAAM,IAAI,CAAC;AASpB,eAAO,MAAM,KAAK,2BAA6B,CAAC;AAChD,eAAO,MAAM,GAAG,QAAiC,CAAC;AAUlD,eAAO,IAAI,kBAAkB,EAAE,CAAC,MAAM,IAAI,CAAC,EA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G,EAAE,MAAM,GAAG,OAAO,CAEhD;AAED,wBAAgB,iBAAiB,IAAI,OAAO,CAAC,MAAM,CAAC,CAGnD;AAED,wBAAgB,yBAAyB,IAAI,OAAO,CAEnD"}
|
package/dist/util.js
CHANGED
|
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.findAvailablePort = exports.isUrlString = exports.pathStartsWith = exports.touchTmpFile = exports.useTmpDirectory = exports.inflateZip = exports.
|
|
6
|
+
exports.checkContainerEnvironment = exports.findAvailablePort = exports.isUrlString = exports.pathStartsWith = exports.touchTmpFile = exports.useTmpDirectory = exports.inflateZip = exports.statFileSync = exports.readJSON = exports.filterRelevantAjvErrors = exports.gracefulError = exports.DetailError = exports.logInfo = exports.logError = exports.logSuccess = exports.logUpdate = exports.log = exports.stopLogging = exports.startLogging = exports.beforeExitHandlers = exports.cwd = exports.debug = void 0;
|
|
7
7
|
const chalk_1 = __importDefault(require("chalk"));
|
|
8
8
|
const debug_1 = __importDefault(require("debug"));
|
|
9
9
|
const fs_1 = __importDefault(require("fs"));
|
|
@@ -16,7 +16,13 @@ const upath_1 = __importDefault(require("upath"));
|
|
|
16
16
|
const util_1 = __importDefault(require("util"));
|
|
17
17
|
exports.debug = debug_1.default('vs-cli');
|
|
18
18
|
exports.cwd = upath_1.default.normalize(process.cwd());
|
|
19
|
-
const ora = ora_1.default({
|
|
19
|
+
const ora = ora_1.default({
|
|
20
|
+
color: 'blue',
|
|
21
|
+
spinner: 'circle',
|
|
22
|
+
// Prevent stream output in docker so that not to spawn process
|
|
23
|
+
// In other environment, check TTY context
|
|
24
|
+
isEnabled: checkContainerEnvironment() ? false : undefined,
|
|
25
|
+
});
|
|
20
26
|
exports.beforeExitHandlers = [];
|
|
21
27
|
const exitSignals = ['exit', 'SIGINT', 'SIGTERM', 'SIGHUP'];
|
|
22
28
|
exitSignals.forEach((sig) => {
|
|
@@ -34,7 +40,8 @@ exitSignals.forEach((sig) => {
|
|
|
34
40
|
});
|
|
35
41
|
});
|
|
36
42
|
function startLogging(text) {
|
|
37
|
-
|
|
43
|
+
// If text is not set, erase previous log with space character
|
|
44
|
+
ora.start(text !== null && text !== void 0 ? text : ' ');
|
|
38
45
|
}
|
|
39
46
|
exports.startLogging = startLogging;
|
|
40
47
|
function stopLogging(text, symbol) {
|
|
@@ -50,7 +57,12 @@ function log(...obj) {
|
|
|
50
57
|
}
|
|
51
58
|
exports.log = log;
|
|
52
59
|
function logUpdate(...obj) {
|
|
53
|
-
ora.
|
|
60
|
+
if (ora.isSpinning) {
|
|
61
|
+
ora.text = obj.join(' ');
|
|
62
|
+
}
|
|
63
|
+
else {
|
|
64
|
+
ora.info(obj.join(' '));
|
|
65
|
+
}
|
|
54
66
|
}
|
|
55
67
|
exports.logUpdate = logUpdate;
|
|
56
68
|
function logSuccess(...obj) {
|
|
@@ -65,10 +77,19 @@ function logInfo(...obj) {
|
|
|
65
77
|
ora.info(obj.join(' '));
|
|
66
78
|
}
|
|
67
79
|
exports.logInfo = logInfo;
|
|
80
|
+
class DetailError extends Error {
|
|
81
|
+
constructor(message, detail) {
|
|
82
|
+
super(message);
|
|
83
|
+
this.detail = detail;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
exports.DetailError = DetailError;
|
|
68
87
|
function gracefulError(err) {
|
|
69
|
-
const message = err
|
|
70
|
-
?
|
|
71
|
-
:
|
|
88
|
+
const message = err instanceof DetailError
|
|
89
|
+
? `${chalk_1.default.red.bold('Error:')} ${err.message}\n${err.detail}`
|
|
90
|
+
: err.stack
|
|
91
|
+
? err.stack.replace(/^Error:/, chalk_1.default.red.bold('Error:'))
|
|
92
|
+
: `${chalk_1.default.red.bold('Error:')} ${err.message}`;
|
|
72
93
|
if (ora.isSpinning) {
|
|
73
94
|
ora.fail(message);
|
|
74
95
|
}
|
|
@@ -80,6 +101,58 @@ If you think this is a bug, please report at https://github.com/vivliostyle/vivl
|
|
|
80
101
|
process.exit(1);
|
|
81
102
|
}
|
|
82
103
|
exports.gracefulError = gracefulError;
|
|
104
|
+
// Filter errors for human readability
|
|
105
|
+
// ref. https://github.com/atlassian/better-ajv-errors/issues/76
|
|
106
|
+
function filterRelevantAjvErrors(allErrors) {
|
|
107
|
+
function split(items, splitFn) {
|
|
108
|
+
return [items.filter(splitFn), items.filter((error) => !splitFn(error))];
|
|
109
|
+
}
|
|
110
|
+
function removeShadowingErrors(singleErrors, metaErrors) {
|
|
111
|
+
return singleErrors.filter((error) => {
|
|
112
|
+
if (metaErrors.some((metaError) => error.dataPath.startsWith(metaError.dataPath))) {
|
|
113
|
+
return !singleErrors.some((otherError) => otherError.dataPath.startsWith(error.dataPath) &&
|
|
114
|
+
otherError.dataPath.length > error.dataPath.length);
|
|
115
|
+
}
|
|
116
|
+
else {
|
|
117
|
+
return true;
|
|
118
|
+
}
|
|
119
|
+
});
|
|
120
|
+
}
|
|
121
|
+
function mergeTypeErrorsByPath(typeErrors) {
|
|
122
|
+
const typeErrorsByPath = typeErrors.reduce((acc, error) => {
|
|
123
|
+
var _a;
|
|
124
|
+
const key = error.dataPath;
|
|
125
|
+
return {
|
|
126
|
+
...acc,
|
|
127
|
+
[key]: [...((_a = acc[key]) !== null && _a !== void 0 ? _a : []), error],
|
|
128
|
+
};
|
|
129
|
+
}, {});
|
|
130
|
+
return Object.values(typeErrorsByPath).map(mergeTypeErrors);
|
|
131
|
+
function mergeTypeErrors(typeErrors) {
|
|
132
|
+
const params = {
|
|
133
|
+
type: typeErrors.map((error) => error.params.type).join(','),
|
|
134
|
+
};
|
|
135
|
+
return {
|
|
136
|
+
...typeErrors[0],
|
|
137
|
+
params,
|
|
138
|
+
};
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
const META_SCHEMA_KEYWORDS = Object.freeze(['anyOf', 'allOf', 'oneOf']);
|
|
142
|
+
// Split the meta errors from what I call "single errors" (the real errors)
|
|
143
|
+
const [metaErrors, singleErrors] = split(allErrors, (error) => META_SCHEMA_KEYWORDS.includes(error.keyword));
|
|
144
|
+
// Filter out the single errors we want to show
|
|
145
|
+
const nonShadowedSingleErrors = removeShadowingErrors(singleErrors, metaErrors);
|
|
146
|
+
// We're handling type errors differently, split them out
|
|
147
|
+
const [typeErrors, nonTypeErrors] = split(nonShadowedSingleErrors, (error) => error.keyword === 'type');
|
|
148
|
+
// Filter out the type errors that already have other errors as well.
|
|
149
|
+
// For example when setting `logLevel: 4`, we don't want to see the error specifying that logLevel should be a string,
|
|
150
|
+
// if the other error already specified that it should be one of the enum values.
|
|
151
|
+
const nonShadowingTypeErrors = typeErrors.filter((typeError) => !nonTypeErrors.some((nonTypeError) => nonTypeError.dataPath === typeError.dataPath));
|
|
152
|
+
const typeErrorsMerged = mergeTypeErrorsByPath(nonShadowingTypeErrors);
|
|
153
|
+
return [...nonTypeErrors, ...typeErrorsMerged];
|
|
154
|
+
}
|
|
155
|
+
exports.filterRelevantAjvErrors = filterRelevantAjvErrors;
|
|
83
156
|
function readJSON(path) {
|
|
84
157
|
try {
|
|
85
158
|
return JSON.parse(fs_1.default.readFileSync(path, 'utf8'));
|
|
@@ -89,9 +162,9 @@ function readJSON(path) {
|
|
|
89
162
|
}
|
|
90
163
|
}
|
|
91
164
|
exports.readJSON = readJSON;
|
|
92
|
-
|
|
165
|
+
function statFileSync(filePath) {
|
|
93
166
|
try {
|
|
94
|
-
return
|
|
167
|
+
return fs_1.default.statSync(filePath);
|
|
95
168
|
}
|
|
96
169
|
catch (err) {
|
|
97
170
|
if (err.code === 'ENOENT') {
|
|
@@ -100,7 +173,7 @@ async function statFile(filePath) {
|
|
|
100
173
|
throw err;
|
|
101
174
|
}
|
|
102
175
|
}
|
|
103
|
-
exports.
|
|
176
|
+
exports.statFileSync = statFileSync;
|
|
104
177
|
async function inflateZip(filePath, dest) {
|
|
105
178
|
return await new Promise((res, rej) => {
|
|
106
179
|
try {
|
|
@@ -169,4 +242,8 @@ function findAvailablePort() {
|
|
|
169
242
|
return portfinder_1.default.getPortPromise();
|
|
170
243
|
}
|
|
171
244
|
exports.findAvailablePort = findAvailablePort;
|
|
245
|
+
function checkContainerEnvironment() {
|
|
246
|
+
return fs_1.default.existsSync('/opt/vivliostyle-cli/.vs-cli-version');
|
|
247
|
+
}
|
|
248
|
+
exports.checkContainerEnvironment = checkContainerEnvironment;
|
|
172
249
|
//# sourceMappingURL=util.js.map
|
package/dist/util.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"util.js","sourceRoot":"","sources":["../src/util.ts"],"names":[],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"util.js","sourceRoot":"","sources":["../src/util.ts"],"names":[],"mappings":";;;;;;AACA,kDAA0B;AAC1B,kDAAqC;AACrC,4CAAoB;AACpB,sEAAwC;AACxC,8CAAiC;AACjC,4DAAoC;AACpC,sDAA8B;AAC9B,8CAAsB;AACtB,kDAA0B;AAC1B,gDAAwB;AAEX,QAAA,KAAK,GAAG,eAAgB,CAAC,QAAQ,CAAC,CAAC;AACnC,QAAA,GAAG,GAAG,eAAK,CAAC,SAAS,CAAC,OAAO,CAAC,GAAG,EAAE,CAAC,CAAC;AAElD,MAAM,GAAG,GAAG,aAAc,CAAC;IACzB,KAAK,EAAE,MAAM;IACb,OAAO,EAAE,QAAQ;IACjB,+DAA+D;IAC/D,0CAA0C;IAC1C,SAAS,EAAE,yBAAyB,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS;CAC3D,CAAC,CAAC;AAEQ,QAAA,kBAAkB,GAAmB,EAAE,CAAC;AACnD,MAAM,WAAW,GAAG,CAAC,MAAM,EAAE,QAAQ,EAAE,SAAS,EAAE,QAAQ,CAAC,CAAC;AAC5D,WAAW,CAAC,OAAO,CAAC,CAAC,GAAG,EAAE,EAAE;IAC1B,OAAO,CAAC,EAAE,CAAC,GA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