@pie-element/ebsr 12.3.4-next.3 → 13.0.0-beta.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/configure/lib/defaults.js +23 -36
- package/configure/lib/defaults.js.map +1 -1
- package/configure/lib/index.js +114 -202
- package/configure/lib/index.js.map +1 -1
- package/configure/lib/main.js +188 -271
- package/configure/lib/main.js.map +1 -1
- package/configure/node_modules/@pie-element/multiple-choice/CHANGELOG.json +1972 -0
- package/configure/node_modules/@pie-element/multiple-choice/CHANGELOG.md +4213 -0
- package/configure/node_modules/@pie-element/multiple-choice/PRINT.md +35 -0
- package/configure/node_modules/@pie-element/multiple-choice/README.md +56 -0
- package/configure/node_modules/@pie-element/multiple-choice/choice.png +0 -0
- package/configure/node_modules/@pie-element/multiple-choice/configure/CHANGELOG.json +1387 -0
- package/configure/node_modules/@pie-element/multiple-choice/configure/CHANGELOG.md +3351 -0
- package/configure/node_modules/@pie-element/multiple-choice/configure/lib/__tests__/root.test.js +248 -0
- package/configure/node_modules/@pie-element/multiple-choice/configure/lib/defaults.js +200 -0
- package/configure/node_modules/@pie-element/multiple-choice/configure/lib/defaults.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/configure/lib/index.js +211 -0
- package/configure/node_modules/@pie-element/multiple-choice/configure/lib/index.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/configure/lib/main.js +477 -0
- package/configure/node_modules/@pie-element/multiple-choice/configure/lib/main.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/configure/lib/utils.js +18 -0
- package/configure/node_modules/@pie-element/multiple-choice/configure/lib/utils.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/configure/package.json +22 -0
- package/configure/node_modules/@pie-element/multiple-choice/controller/CHANGELOG.json +527 -0
- package/configure/node_modules/@pie-element/multiple-choice/controller/CHANGELOG.md +2316 -0
- package/configure/node_modules/@pie-element/multiple-choice/controller/lib/__tests__/index.test.js +520 -0
- package/configure/node_modules/@pie-element/multiple-choice/controller/lib/__tests__/utils.test.js +8 -0
- package/configure/node_modules/@pie-element/multiple-choice/controller/lib/defaults.js +33 -0
- package/configure/node_modules/@pie-element/multiple-choice/controller/lib/defaults.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/controller/lib/index.js +251 -0
- package/configure/node_modules/@pie-element/multiple-choice/controller/lib/index.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/controller/lib/utils.js +16 -0
- package/configure/node_modules/@pie-element/multiple-choice/controller/lib/utils.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/controller/package.json +15 -0
- package/configure/node_modules/@pie-element/multiple-choice/docs/config-schema.json +2993 -0
- package/configure/node_modules/@pie-element/multiple-choice/docs/config-schema.json.md +2217 -0
- package/configure/node_modules/@pie-element/multiple-choice/docs/demo/config.js +8 -0
- package/configure/node_modules/@pie-element/multiple-choice/docs/demo/generate.js +61 -0
- package/configure/node_modules/@pie-element/multiple-choice/docs/demo/index.html +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/docs/demo/pie.manifest.json +11 -0
- package/configure/node_modules/@pie-element/multiple-choice/docs/demo/session.js +7 -0
- package/configure/node_modules/@pie-element/multiple-choice/docs/pie-schema.json +1332 -0
- package/configure/node_modules/@pie-element/multiple-choice/docs/pie-schema.json.md +1015 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/__tests__/choice-input-test.js +117 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/__tests__/index-test.js +151 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/__tests__/key-events-test.js +95 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/__tests__/multiple-choice-test.js +223 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/__tests__/session-updater-test.js +70 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/choice-input.js +370 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/choice-input.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/choice.js +197 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/choice.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/feedback-tick.js +130 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/feedback-tick.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/index.js +292 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/index.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/main.js +54 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/main.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/multiple-choice.js +386 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/multiple-choice.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/print.js +92 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/print.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/session-updater.js +37 -0
- package/configure/node_modules/@pie-element/multiple-choice/lib/session-updater.js.map +1 -0
- package/configure/node_modules/@pie-element/multiple-choice/package.json +39 -0
- package/configure/package.json +9 -6
- package/configure/src/__tests__/index.test.js +99 -108
- package/configure/src/index.js +13 -6
- package/configure/src/main.jsx +14 -18
- package/controller/lib/defaults.js +20 -32
- package/controller/lib/defaults.js.map +1 -1
- package/controller/lib/index.js +224 -349
- package/controller/lib/index.js.map +1 -1
- package/controller/lib/utils.js +4 -18
- package/controller/lib/utils.js.map +1 -1
- package/controller/package.json +3 -3
- package/lib/index.js +113 -181
- package/lib/index.js.map +1 -1
- package/lib/print.js +120 -204
- package/lib/print.js.map +1 -1
- package/package.json +5 -13
- package/src/__tests__/index.test.js +18 -5
- package/configure/src/__tests__/__snapshots__/index.test.js.snap +0 -83
- package/esm/configure.js +0 -12003
- package/esm/configure.js.map +0 -1
- package/esm/controller.js +0 -3358
- package/esm/controller.js.map +0 -1
- package/esm/element.js +0 -2203
- package/esm/element.js.map +0 -1
- package/esm/package.json +0 -3
- package/esm/print.js +0 -4092
- package/esm/print.js.map +0 -1
- package/module/configure.js +0 -1
- package/module/controller.js +0 -6469
- package/module/demo.js +0 -77
- package/module/element.js +0 -1
- package/module/index.html +0 -21
- package/module/manifest.json +0 -14
- package/module/print-demo.js +0 -115
- package/module/print.html +0 -18
- package/module/print.js +0 -1
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# print how to
|
|
2
|
+
|
|
3
|
+
Brief guide on how to build pie-element print modules. Each element can have their own print module. It needs to be defined in the package.json `exports` map.
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
These modules will be published as part of the npm package.
|
|
7
|
+
|
|
8
|
+
We will then have a new element that 3rd parties can use to load up these elements:
|
|
9
|
+
|
|
10
|
+
```html
|
|
11
|
+
<pie-print config={} options={}></pie-print>
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
This is being developed in another repo: https://github.com/key-data-systems/pie-print-support
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
## how to run a single element that will recompile when there are changes (no HMR):
|
|
19
|
+
|
|
20
|
+
`yarn pslb serve --config pslb/pslb.config.js --package @pie-element/multiple-choice --logLevel info`
|
|
21
|
+
|
|
22
|
+
Then go to:
|
|
23
|
+
|
|
24
|
+
http://localhost:7752/multiple-choice/module/index.html
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
## how to build
|
|
28
|
+
|
|
29
|
+
You prob won't need this but for your edification:
|
|
30
|
+
|
|
31
|
+
`yarn pslb --config pslb/pslb.config.js --package @pie-element/multiple-choice --logLevel info`
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
# @pie-element/multiple-choice
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
A [pie][pie]choice component.
|
|
5
|
+
|
|
6
|
+

|
|
7
|
+
|
|
8
|
+
## Usage
|
|
9
|
+
|
|
10
|
+
To use this pie, you need to configure it within an Assessment Item. This means that you'll need to add it to the `index.html` and `config.json` files.
|
|
11
|
+
|
|
12
|
+
```html
|
|
13
|
+
<multiple-choice pie-id="1"></multiple-choice>
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
```javascript
|
|
17
|
+
{
|
|
18
|
+
elements: {
|
|
19
|
+
'multiple-choice': '@pie-element/multiple-choice@^1.0.0'
|
|
20
|
+
},
|
|
21
|
+
models: [
|
|
22
|
+
{
|
|
23
|
+
id : "1",
|
|
24
|
+
element: 'multiple-choice',
|
|
25
|
+
prompt : "1 + 1 equals?",
|
|
26
|
+
// more configuration...
|
|
27
|
+
}
|
|
28
|
+
]
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
### Pie Demo
|
|
32
|
+
There is a demo in `docs/demo` that you can run to see an example of it's usage.
|
|
33
|
+
|
|
34
|
+
To preview it in that context you'll need the [pie][pie] tool.
|
|
35
|
+
|
|
36
|
+
```shell
|
|
37
|
+
npm install -g pie
|
|
38
|
+
cd multiple-choice/docs/demo
|
|
39
|
+
pie serve #will build and serve the pie... then go to http://localhost:4000
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## Test
|
|
43
|
+
|
|
44
|
+
```shell
|
|
45
|
+
npm test # run client and controller tests
|
|
46
|
+
npm run client-test # run client tests
|
|
47
|
+
npm run controller-test # run controller tests
|
|
48
|
+
```
|
|
49
|
+
## Release
|
|
50
|
+
|
|
51
|
+
```shell
|
|
52
|
+
gulp release
|
|
53
|
+
git checkout master
|
|
54
|
+
npm publish
|
|
55
|
+
```
|
|
56
|
+
[pie]: http://npmjs.org/package/pie
|
|
Binary file
|