@liascript/exporter 2.6.6--0.11.0 → 2.6.7--0.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 +14 -2
- package/dist/assets/indexeddb/Beaker.becbdce1.js +1 -0
- package/dist/assets/indexeddb/Beaker.fb6f1ed7.js +1 -0
- package/dist/assets/indexeddb/Gun.b4a8b12a.js +1 -0
- package/dist/assets/indexeddb/Gun.dfece915.js +1 -0
- package/dist/assets/indexeddb/{Jitsi.8033a133.js → Jitsi.1c0a2389.js} +1 -1
- package/dist/assets/indexeddb/Jitsi.4f241ff6.js +1 -0
- package/dist/assets/indexeddb/index.7555c632.js +1 -0
- package/dist/assets/indexeddb/index.9d0c93a8.css +1 -0
- package/dist/assets/indexeddb/index.c9e0eee5.js +1 -0
- package/dist/assets/indexeddb/index.cd20f880.js +1 -0
- package/dist/assets/indexeddb/index.fdc63b6b.js +1 -0
- package/dist/assets/indexeddb/index.html +1 -1
- package/dist/assets/scorm1.2/Beaker.becbdce1.js +1 -0
- package/dist/assets/scorm1.2/Beaker.fb6f1ed7.js +1 -0
- package/dist/assets/scorm1.2/Gun.b4a8b12a.js +1 -0
- package/dist/assets/scorm1.2/Gun.dfece915.js +1 -0
- package/dist/assets/scorm1.2/{Jitsi.8033a133.js → Jitsi.1c0a2389.js} +1 -1
- package/dist/assets/scorm1.2/Jitsi.4f241ff6.js +1 -0
- package/dist/assets/scorm1.2/index.43be91bb.js +1 -0
- package/dist/assets/scorm1.2/index.7555c632.js +1 -0
- package/dist/assets/scorm1.2/index.9d0c93a8.css +1 -0
- package/dist/assets/scorm1.2/index.c9e0eee5.js +1 -0
- package/dist/assets/scorm1.2/index.f7835cb5.js +1 -0
- package/dist/assets/scorm1.2/index.html +1 -1
- package/dist/assets/scorm2004/Beaker.becbdce1.js +1 -0
- package/dist/assets/scorm2004/Beaker.fb6f1ed7.js +1 -0
- package/dist/assets/scorm2004/Gun.b4a8b12a.js +1 -0
- package/dist/assets/scorm2004/Gun.dfece915.js +1 -0
- package/dist/assets/scorm2004/{Jitsi.8033a133.js → Jitsi.1c0a2389.js} +1 -1
- package/dist/assets/scorm2004/Jitsi.4f241ff6.js +1 -0
- package/dist/assets/scorm2004/index.138ccbc7.js +1 -0
- package/dist/assets/scorm2004/index.7555c632.js +1 -0
- package/dist/assets/scorm2004/index.9d0c93a8.css +1 -0
- package/dist/assets/scorm2004/index.c9e0eee5.js +1 -0
- package/dist/assets/scorm2004/index.f55780b6.js +1 -0
- package/dist/assets/scorm2004/index.html +1 -1
- package/dist/assets/web/Beaker.becbdce1.js +1 -0
- package/dist/assets/web/Beaker.fb6f1ed7.js +1 -0
- package/dist/assets/web/Gun.b4a8b12a.js +1 -0
- package/dist/assets/web/Gun.dfece915.js +1 -0
- package/dist/assets/web/{Jitsi.8033a133.js → Jitsi.1c0a2389.js} +1 -1
- package/dist/assets/web/Jitsi.4f241ff6.js +1 -0
- package/dist/assets/web/index.01978564.js +1 -0
- package/dist/assets/web/index.7555c632.js +1 -0
- package/dist/assets/web/index.9d0c93a8.css +1 -0
- package/dist/assets/web/index.c28ff9a6.js +1 -0
- package/dist/assets/web/index.c9e0eee5.js +1 -0
- package/dist/assets/web/index.html +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
- package/src/export/android.ts +22 -0
- package/src/export/helper.ts +8 -2
- package/src/export/ims.ts +21 -0
- package/src/export/pdf.ts +68 -0
- package/src/export/scorm12.ts +35 -2
- package/src/export/scorm2004.ts +13 -1
- package/src/index.ts +18 -119
- package/dist/assets/indexeddb/Beaker.109d4501.js +0 -1
- package/dist/assets/indexeddb/Beaker.cad85351.js +0 -1
- package/dist/assets/indexeddb/Gun.3d0f8b5c.js +0 -1
- package/dist/assets/indexeddb/Gun.8d521e41.js +0 -1
- package/dist/assets/indexeddb/Jitsi.7c705568.js +0 -1
- package/dist/assets/indexeddb/index.3e300789.js +0 -1
- package/dist/assets/indexeddb/index.9bace6c1.js +0 -1
- package/dist/assets/indexeddb/index.9c382600.css +0 -1
- package/dist/assets/indexeddb/index.bd52f66c.js +0 -1
- package/dist/assets/indexeddb/index.cf54bb07.js +0 -1
- package/dist/assets/scorm1.2/Beaker.109d4501.js +0 -1
- package/dist/assets/scorm1.2/Beaker.cad85351.js +0 -1
- package/dist/assets/scorm1.2/Gun.3d0f8b5c.js +0 -1
- package/dist/assets/scorm1.2/Gun.8d521e41.js +0 -1
- package/dist/assets/scorm1.2/Jitsi.7c705568.js +0 -1
- package/dist/assets/scorm1.2/index.73b34686.js +0 -1
- package/dist/assets/scorm1.2/index.9bace6c1.js +0 -1
- package/dist/assets/scorm1.2/index.9c382600.css +0 -1
- package/dist/assets/scorm1.2/index.bd52f66c.js +0 -1
- package/dist/assets/scorm1.2/index.f180d4ec.js +0 -1
- package/dist/assets/scorm2004/Beaker.109d4501.js +0 -1
- package/dist/assets/scorm2004/Beaker.cad85351.js +0 -1
- package/dist/assets/scorm2004/Gun.3d0f8b5c.js +0 -1
- package/dist/assets/scorm2004/Gun.8d521e41.js +0 -1
- package/dist/assets/scorm2004/Jitsi.7c705568.js +0 -1
- package/dist/assets/scorm2004/index.70023c6e.js +0 -1
- package/dist/assets/scorm2004/index.9bace6c1.js +0 -1
- package/dist/assets/scorm2004/index.9c382600.css +0 -1
- package/dist/assets/scorm2004/index.aa80d76c.js +0 -1
- package/dist/assets/scorm2004/index.bd52f66c.js +0 -1
- package/dist/assets/web/Beaker.109d4501.js +0 -1
- package/dist/assets/web/Beaker.cad85351.js +0 -1
- package/dist/assets/web/Gun.3d0f8b5c.js +0 -1
- package/dist/assets/web/Gun.8d521e41.js +0 -1
- package/dist/assets/web/Jitsi.7c705568.js +0 -1
- package/dist/assets/web/index.9bace6c1.js +0 -1
- package/dist/assets/web/index.9c382600.css +0 -1
- package/dist/assets/web/index.bd52f66c.js +0 -1
- package/dist/assets/web/index.dd7c6355.js +0 -1
- package/dist/assets/web/index.fe7e12cf.js +0 -1
package/package.json
CHANGED
package/src/export/android.ts
CHANGED
|
@@ -4,6 +4,28 @@ const path = require('path')
|
|
|
4
4
|
const fs = require('fs-extra')
|
|
5
5
|
const { exec } = require('child_process')
|
|
6
6
|
|
|
7
|
+
export function help() {
|
|
8
|
+
console.log('\nAndroid settings:')
|
|
9
|
+
console.log('')
|
|
10
|
+
console.log(
|
|
11
|
+
'--android-sdk Specify sdk.dir which is required for building.'
|
|
12
|
+
)
|
|
13
|
+
console.log(
|
|
14
|
+
'--android-appName Name of the App (Main-title is used as default).'
|
|
15
|
+
)
|
|
16
|
+
console.log(
|
|
17
|
+
'--android-appId Required to identify your App reverse url such as io.github.liascript'
|
|
18
|
+
)
|
|
19
|
+
console.log('--android-icon Optional icon with 1024x1024 px')
|
|
20
|
+
console.log(
|
|
21
|
+
'--android-splash Optional splash image with 2732x2732 px'
|
|
22
|
+
)
|
|
23
|
+
console.log(
|
|
24
|
+
'--android-splashDuration Duration for splash-screen default 0 milliseconds'
|
|
25
|
+
)
|
|
26
|
+
console.log('--android-preview Open course in Android-Studio')
|
|
27
|
+
}
|
|
28
|
+
|
|
7
29
|
export async function exporter(
|
|
8
30
|
argument: {
|
|
9
31
|
input: string
|
package/src/export/helper.ts
CHANGED
|
@@ -72,8 +72,14 @@ export function injectResponsivevoice(key: string, into: string): string {
|
|
|
72
72
|
* @param into - old index.html content
|
|
73
73
|
* @returns - new index.html content
|
|
74
74
|
*/
|
|
75
|
-
export function inject(
|
|
76
|
-
|
|
75
|
+
export function inject(
|
|
76
|
+
element: string,
|
|
77
|
+
into: string,
|
|
78
|
+
head: boolean = false
|
|
79
|
+
): string {
|
|
80
|
+
return head
|
|
81
|
+
? into.replace('<head>', '<head>' + element)
|
|
82
|
+
: into.replace('</head>', element + '</head>')
|
|
77
83
|
}
|
|
78
84
|
|
|
79
85
|
export function isURL(uri: string) {
|
package/src/export/ims.ts
CHANGED
|
@@ -4,6 +4,27 @@ import * as RDF from './rdf'
|
|
|
4
4
|
const path = require('path')
|
|
5
5
|
const fs = require('fs-extra')
|
|
6
6
|
|
|
7
|
+
export function help() {
|
|
8
|
+
console.log('\nIMS settings:')
|
|
9
|
+
console.log('')
|
|
10
|
+
console.log(
|
|
11
|
+
'--ims-indexeddb',
|
|
12
|
+
' Use IndexedDB to store data persistently'
|
|
13
|
+
)
|
|
14
|
+
|
|
15
|
+
console.log('\nWEB settings:')
|
|
16
|
+
console.log('')
|
|
17
|
+
console.log(
|
|
18
|
+
'--web-iframe Use an iframed version to hide the course URL.'
|
|
19
|
+
)
|
|
20
|
+
console.log(
|
|
21
|
+
'--web-indexeddb This will allow to store data within the browser using indexeddb, you can optionally pass a unique key (by default one is generated randomly).'
|
|
22
|
+
)
|
|
23
|
+
console.log(
|
|
24
|
+
'--web-zip By default the result is not zipped, you can change this with this parameter.'
|
|
25
|
+
)
|
|
26
|
+
}
|
|
27
|
+
|
|
7
28
|
export async function exporter(
|
|
8
29
|
argument: {
|
|
9
30
|
input: string
|
package/src/export/pdf.ts
CHANGED
|
@@ -3,6 +3,74 @@ import * as helper from './helper'
|
|
|
3
3
|
const path = require('path')
|
|
4
4
|
const puppeteer = require('puppeteer')
|
|
5
5
|
|
|
6
|
+
export function help() {
|
|
7
|
+
console.log('\nPDF settings:\n')
|
|
8
|
+
console.log(
|
|
9
|
+
'--pdf-stylesheet Inject an local CSS for changing the appearance.'
|
|
10
|
+
)
|
|
11
|
+
console.log(
|
|
12
|
+
'--pdf-theme LiaScript themes: default, turquoise, blue, red, yellow'
|
|
13
|
+
)
|
|
14
|
+
console.log(
|
|
15
|
+
'--pdf-timeout Set an additional time horizon to wait until finished.'
|
|
16
|
+
)
|
|
17
|
+
console.log(
|
|
18
|
+
'\nhttps://github.com/puppeteer/puppeteer/blob/main/docs/api.md#pagepdfoptions\n'
|
|
19
|
+
)
|
|
20
|
+
console.log(
|
|
21
|
+
'--pdf-preview Open preview-browser (default false), print not possible'
|
|
22
|
+
)
|
|
23
|
+
console.log(
|
|
24
|
+
'--pdf-scale Scale of the webpage rendering. Defaults to 1. Scale amount must be between 0.1 and 2.'
|
|
25
|
+
)
|
|
26
|
+
console.log(
|
|
27
|
+
'--pdf-displayHeaderFooter Display header and footer. Defaults to false.'
|
|
28
|
+
)
|
|
29
|
+
console.log(
|
|
30
|
+
'--pdf-headerTemplate HTML template for the print header, inject classes date, title, url, pageNumber, totalPages'
|
|
31
|
+
)
|
|
32
|
+
|
|
33
|
+
console.log(
|
|
34
|
+
'--pdf-footerTemplate HTML template for the print footer. Should use the same format as the headerTemplate'
|
|
35
|
+
)
|
|
36
|
+
console.log(
|
|
37
|
+
'--pdf-printBackground Print background graphics. Defaults to false'
|
|
38
|
+
)
|
|
39
|
+
console.log(
|
|
40
|
+
'--pdf-landscape Paper orientation. Defaults to false.'
|
|
41
|
+
)
|
|
42
|
+
console.log(
|
|
43
|
+
'--pdf-pageRanges Paper ranges to print, e.g., "1-5, 8, 11-13"'
|
|
44
|
+
)
|
|
45
|
+
console.log(
|
|
46
|
+
'--pdf-format Paper format. If set, takes priority over width or height options. Defaults to a4.'
|
|
47
|
+
)
|
|
48
|
+
console.log(
|
|
49
|
+
'--pdf-width Paper width, accepts values labeled with units.'
|
|
50
|
+
)
|
|
51
|
+
console.log(
|
|
52
|
+
'--pdf-height Paper height, accepts values labeled with units.'
|
|
53
|
+
)
|
|
54
|
+
console.log(
|
|
55
|
+
'--pdf-margin-top Top margin, accepts values labeled with units.'
|
|
56
|
+
)
|
|
57
|
+
console.log(
|
|
58
|
+
'--pdf-margin-right Right margin, accepts values labeled with units.'
|
|
59
|
+
)
|
|
60
|
+
console.log(
|
|
61
|
+
'--pdf-margin-bottom Bottom margin, accepts values labeled with units.'
|
|
62
|
+
)
|
|
63
|
+
console.log(
|
|
64
|
+
'--pdf-margin-left Left margin, accepts values labeled with units. '
|
|
65
|
+
)
|
|
66
|
+
console.log(
|
|
67
|
+
'--pdf-preferCSSPageSize Give any CSS @page size declared in the page priority over what is declared in width and height or format options.'
|
|
68
|
+
)
|
|
69
|
+
console.log(
|
|
70
|
+
'--pdf-omitBackground Hides default white background and allows capturing screenshots with transparency. Defaults to true. '
|
|
71
|
+
)
|
|
72
|
+
}
|
|
73
|
+
|
|
6
74
|
export async function exporter(
|
|
7
75
|
argument: {
|
|
8
76
|
input: string
|
package/src/export/scorm12.ts
CHANGED
|
@@ -4,7 +4,27 @@ import * as RDF from './rdf'
|
|
|
4
4
|
const scormPackager = require('@liascript/simple-scorm-packager')
|
|
5
5
|
const path = require('path')
|
|
6
6
|
const fs = require('fs-extra')
|
|
7
|
-
|
|
7
|
+
|
|
8
|
+
export function help() {
|
|
9
|
+
console.log('\nSCORM settings:\n')
|
|
10
|
+
console.log('--scorm-organization', ' set the organization title')
|
|
11
|
+
console.log(
|
|
12
|
+
'--scorm-masteryScore',
|
|
13
|
+
' set the scorm masteryScore (a value between 0 -- 100), default is 0'
|
|
14
|
+
)
|
|
15
|
+
console.log(
|
|
16
|
+
'--scorm-typicalDuration',
|
|
17
|
+
' set the scorm duration, default is PT0H5M0S'
|
|
18
|
+
)
|
|
19
|
+
console.log(
|
|
20
|
+
'--scorm-iframe',
|
|
21
|
+
' use an iframe, when a SCORM starting parameter is not working'
|
|
22
|
+
)
|
|
23
|
+
console.log(
|
|
24
|
+
'--scorm-embed',
|
|
25
|
+
' embed the Markdown into the JS code, use in Moodle 4 to handle restrictions with dynamic loading'
|
|
26
|
+
)
|
|
27
|
+
}
|
|
8
28
|
|
|
9
29
|
export async function exporter(
|
|
10
30
|
argument: {
|
|
@@ -21,6 +41,7 @@ export async function exporter(
|
|
|
21
41
|
'scorm-masteryScore'?: string
|
|
22
42
|
'scorm-typicalDuration'?: string
|
|
23
43
|
'scorm-iframe'?: boolean
|
|
44
|
+
'scorm-embed'?: string
|
|
24
45
|
},
|
|
25
46
|
json
|
|
26
47
|
) {
|
|
@@ -64,6 +85,15 @@ export async function exporter(
|
|
|
64
85
|
)
|
|
65
86
|
}
|
|
66
87
|
|
|
88
|
+
if (argument['scorm-embed']) {
|
|
89
|
+
console.warn('WWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWW', argument['scorm-embed'])
|
|
90
|
+
index = helper.inject('<script src="course.js"></script>', index, true)
|
|
91
|
+
await helper.writeFile(
|
|
92
|
+
path.join(tmpPath, 'course.js'),
|
|
93
|
+
'window["liascript_course"] = ' + JSON.stringify(argument['scorm-embed'])
|
|
94
|
+
)
|
|
95
|
+
}
|
|
96
|
+
|
|
67
97
|
try {
|
|
68
98
|
index = helper.inject(jsonLD, index)
|
|
69
99
|
await helper.writeFile(path.join(tmpPath, 'index.html'), index)
|
|
@@ -84,7 +114,10 @@ export async function exporter(
|
|
|
84
114
|
language: json.lia.definition.language,
|
|
85
115
|
masteryScore: argument['scorm-masteryScore'] || 0,
|
|
86
116
|
startingPage: argument['scorm-iframe'] ? 'start.html' : 'index.html',
|
|
87
|
-
startingParameters:
|
|
117
|
+
startingParameters:
|
|
118
|
+
argument['scorm-iframe'] || argument['embed']
|
|
119
|
+
? undefined
|
|
120
|
+
: argument.readme,
|
|
88
121
|
source: path.join(tmp, 'pro'),
|
|
89
122
|
package: {
|
|
90
123
|
version: json.lia.definition.version,
|
package/src/export/scorm2004.ts
CHANGED
|
@@ -21,6 +21,7 @@ export async function exporter(
|
|
|
21
21
|
'scorm-masteryScore'?: string
|
|
22
22
|
'scorm-typicalDuration'?: string
|
|
23
23
|
'scorm-iframe'?: boolean
|
|
24
|
+
'scorm-embed'?: string
|
|
24
25
|
},
|
|
25
26
|
json
|
|
26
27
|
) {
|
|
@@ -64,6 +65,14 @@ export async function exporter(
|
|
|
64
65
|
)
|
|
65
66
|
}
|
|
66
67
|
|
|
68
|
+
if (argument['scorm-embed']) {
|
|
69
|
+
index = helper.inject('<script src="course.js"></script>', index, true)
|
|
70
|
+
await helper.writeFile(
|
|
71
|
+
path.join(tmpPath, 'course.js'),
|
|
72
|
+
'window["liascript_course"] = ' + JSON.stringify(argument['scorm-embed'])
|
|
73
|
+
)
|
|
74
|
+
}
|
|
75
|
+
|
|
67
76
|
try {
|
|
68
77
|
index = helper.inject(jsonLD, index)
|
|
69
78
|
await helper.writeFile(path.join(tmpPath, 'index.html'), index)
|
|
@@ -84,7 +93,10 @@ export async function exporter(
|
|
|
84
93
|
language: json.lia.definition.language,
|
|
85
94
|
masteryScore: argument['scorm-masteryScore'] || 0,
|
|
86
95
|
startingPage: argument['scorm-iframe'] ? 'start.html' : 'index.html',
|
|
87
|
-
startingParameters:
|
|
96
|
+
startingParameters:
|
|
97
|
+
argument['scorm-iframe'] || argument['embed']
|
|
98
|
+
? undefined
|
|
99
|
+
: argument.readme,
|
|
88
100
|
source: path.join(tmp, 'pro'),
|
|
89
101
|
package: {
|
|
90
102
|
version: json.lia.definition.version,
|
package/src/index.ts
CHANGED
|
@@ -22,7 +22,7 @@ import fetch from 'node-fetch'
|
|
|
22
22
|
|
|
23
23
|
// -------------------------------Main Execution-------------------------------
|
|
24
24
|
if (argv.v || argv.version) {
|
|
25
|
-
console.log('version: 2.6.
|
|
25
|
+
console.log('version: 2.6.7--0.11.0')
|
|
26
26
|
} else if (argv.h || argv.help) {
|
|
27
27
|
help()
|
|
28
28
|
} else if (argv.i || argv.input) {
|
|
@@ -37,6 +37,9 @@ var collection: any
|
|
|
37
37
|
|
|
38
38
|
async function run(argument) {
|
|
39
39
|
var app = Elm.Worker.init({ flags: { cmd: '' } })
|
|
40
|
+
|
|
41
|
+
var embed = undefined
|
|
42
|
+
|
|
40
43
|
app.ports.output.subscribe(function (event) {
|
|
41
44
|
let [ok, string] = event
|
|
42
45
|
|
|
@@ -59,10 +62,16 @@ async function run(argument) {
|
|
|
59
62
|
break
|
|
60
63
|
}
|
|
61
64
|
case 'scorm1.2': {
|
|
65
|
+
if (argument['scorm-embed']) {
|
|
66
|
+
argument['scorm-embed'] = embed
|
|
67
|
+
}
|
|
62
68
|
SCORM12.exporter(argument, JSON.parse(string))
|
|
63
69
|
break
|
|
64
70
|
}
|
|
65
71
|
case 'scorm2004': {
|
|
72
|
+
if (argument['scorm-embed']) {
|
|
73
|
+
argument['scorm-embed'] = embed
|
|
74
|
+
}
|
|
66
75
|
SCORM2004.exporter(argument, JSON.parse(string))
|
|
67
76
|
break
|
|
68
77
|
}
|
|
@@ -140,6 +149,9 @@ async function run(argument) {
|
|
|
140
149
|
}
|
|
141
150
|
} else if (!helper.isURL(argument.input)) {
|
|
142
151
|
const data = fs.readFileSync(argument.input, 'utf8')
|
|
152
|
+
|
|
153
|
+
embed = data
|
|
154
|
+
|
|
143
155
|
app.ports.input.send([format, data])
|
|
144
156
|
} else if (argument.format === 'pdf') {
|
|
145
157
|
PDF.exporter(argument, {})
|
|
@@ -187,127 +199,13 @@ function help() {
|
|
|
187
199
|
|
|
188
200
|
console.log('\n-k', '--key', ' responsive voice key ')
|
|
189
201
|
|
|
190
|
-
|
|
191
|
-
console.log('')
|
|
192
|
-
console.log('--scorm-organization', ' set the organization title')
|
|
193
|
-
console.log(
|
|
194
|
-
'--scorm-masteryScore',
|
|
195
|
-
' set the scorm masteryScore (a value between 0 -- 100), default is 0'
|
|
196
|
-
)
|
|
197
|
-
console.log(
|
|
198
|
-
'--scorm-typicalDuration',
|
|
199
|
-
' set the scorm duration, default is PT0H5M0S'
|
|
200
|
-
)
|
|
201
|
-
|
|
202
|
-
console.log(
|
|
203
|
-
'--scorm-iframe',
|
|
204
|
-
' use an iframe, when a SCORM starting parameter is not working'
|
|
205
|
-
)
|
|
206
|
-
|
|
207
|
-
console.log('\nIMS settings:')
|
|
208
|
-
console.log('')
|
|
209
|
-
console.log(
|
|
210
|
-
'--ims-indexeddb',
|
|
211
|
-
' Use IndexedDB to store data persistently'
|
|
212
|
-
)
|
|
202
|
+
SCORM12.help()
|
|
213
203
|
|
|
214
|
-
|
|
215
|
-
console.log('')
|
|
216
|
-
console.log(
|
|
217
|
-
'--web-iframe Use an iframed version to hide the course URL.'
|
|
218
|
-
)
|
|
219
|
-
console.log(
|
|
220
|
-
'--web-indexeddb This will allow to store data within the browser using indexeddb, you can optionally pass a unique key (by default one is generated randomly).'
|
|
221
|
-
)
|
|
222
|
-
console.log(
|
|
223
|
-
'--web-zip By default the result is not zipped, you can change this with this parameter.'
|
|
224
|
-
)
|
|
204
|
+
IMS.help()
|
|
225
205
|
|
|
226
|
-
|
|
227
|
-
console.log('')
|
|
228
|
-
console.log(
|
|
229
|
-
'--android-sdk Specify sdk.dir which is required for building.'
|
|
230
|
-
)
|
|
231
|
-
console.log(
|
|
232
|
-
'--android-appName Name of the App (Main-title is used as default).'
|
|
233
|
-
)
|
|
234
|
-
console.log(
|
|
235
|
-
'--android-appId Required to identify your App reverse url such as io.github.liascript'
|
|
236
|
-
)
|
|
237
|
-
console.log('--android-icon Optional icon with 1024x1024 px')
|
|
238
|
-
console.log(
|
|
239
|
-
'--android-splash Optional splash image with 2732x2732 px'
|
|
240
|
-
)
|
|
241
|
-
console.log(
|
|
242
|
-
'--android-splashDuration Duration for splash-screen default 0 milliseconds'
|
|
243
|
-
)
|
|
244
|
-
console.log('--android-preview Open course in Android-Studio')
|
|
206
|
+
ANDROID.help()
|
|
245
207
|
|
|
246
|
-
|
|
247
|
-
console.log(
|
|
248
|
-
'--pdf-stylesheet Inject an local CSS for changing the appearance.'
|
|
249
|
-
)
|
|
250
|
-
console.log(
|
|
251
|
-
'--pdf-theme LiaScript themes: default, turquoise, blue, red, yellow'
|
|
252
|
-
)
|
|
253
|
-
console.log(
|
|
254
|
-
'--pdf-timeout Set an additional time horizon to wait until finished.'
|
|
255
|
-
)
|
|
256
|
-
console.log(
|
|
257
|
-
'\nhttps://github.com/puppeteer/puppeteer/blob/main/docs/api.md#pagepdfoptions\n'
|
|
258
|
-
)
|
|
259
|
-
console.log(
|
|
260
|
-
'--pdf-preview Open preview-browser (default false), print not possible'
|
|
261
|
-
)
|
|
262
|
-
console.log(
|
|
263
|
-
'--pdf-scale Scale of the webpage rendering. Defaults to 1. Scale amount must be between 0.1 and 2.'
|
|
264
|
-
)
|
|
265
|
-
console.log(
|
|
266
|
-
'--pdf-displayHeaderFooter Display header and footer. Defaults to false.'
|
|
267
|
-
)
|
|
268
|
-
console.log(
|
|
269
|
-
'--pdf-headerTemplate HTML template for the print header, inject classes date, title, url, pageNumber, totalPages'
|
|
270
|
-
)
|
|
271
|
-
|
|
272
|
-
console.log(
|
|
273
|
-
'--pdf-footerTemplate HTML template for the print footer. Should use the same format as the headerTemplate'
|
|
274
|
-
)
|
|
275
|
-
console.log(
|
|
276
|
-
'--pdf-printBackground Print background graphics. Defaults to false'
|
|
277
|
-
)
|
|
278
|
-
console.log(
|
|
279
|
-
'--pdf-landscape Paper orientation. Defaults to false.'
|
|
280
|
-
)
|
|
281
|
-
console.log(
|
|
282
|
-
'--pdf-pageRanges Paper ranges to print, e.g., "1-5, 8, 11-13"'
|
|
283
|
-
)
|
|
284
|
-
console.log(
|
|
285
|
-
'--pdf-format Paper format. If set, takes priority over width or height options. Defaults to a4.'
|
|
286
|
-
)
|
|
287
|
-
console.log(
|
|
288
|
-
'--pdf-width Paper width, accepts values labeled with units.'
|
|
289
|
-
)
|
|
290
|
-
console.log(
|
|
291
|
-
'--pdf-height Paper height, accepts values labeled with units.'
|
|
292
|
-
)
|
|
293
|
-
console.log(
|
|
294
|
-
'--pdf-margin-top Top margin, accepts values labeled with units.'
|
|
295
|
-
)
|
|
296
|
-
console.log(
|
|
297
|
-
'--pdf-margin-right Right margin, accepts values labeled with units.'
|
|
298
|
-
)
|
|
299
|
-
console.log(
|
|
300
|
-
'--pdf-margin-bottom Bottom margin, accepts values labeled with units.'
|
|
301
|
-
)
|
|
302
|
-
console.log(
|
|
303
|
-
'--pdf-margin-left Left margin, accepts values labeled with units. '
|
|
304
|
-
)
|
|
305
|
-
console.log(
|
|
306
|
-
'--pdf-preferCSSPageSize Give any CSS @page size declared in the page priority over what is declared in width and height or format options.'
|
|
307
|
-
)
|
|
308
|
-
console.log(
|
|
309
|
-
'--pdf-omitBackground Hides default white background and allows capturing screenshots with transparency. Defaults to true. '
|
|
310
|
-
)
|
|
208
|
+
PDF.help()
|
|
311
209
|
|
|
312
210
|
PROJECT.help()
|
|
313
211
|
|
|
@@ -337,6 +235,7 @@ function parseArguments() {
|
|
|
337
235
|
'scorm-masteryScore': argv['scorm-masteryScore'],
|
|
338
236
|
'scorm-typicalDuration': argv['scorm-typicalDuration'],
|
|
339
237
|
'scorm-iframe': argv['scorm-iframe'],
|
|
238
|
+
'scorm-embed': argv['scorm-embed'],
|
|
340
239
|
|
|
341
240
|
// special IMS cases
|
|
342
241
|
'ims-indexeddb': argv['ims-indexeddb'],
|