paperlint 14.0.0 → 14.2.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/dist/skills/build-label-page/scripts/label-page-core.d.ts +105 -25
- package/dist/skills/build-label-page/scripts/label-page-presets.d.ts +10 -0
- package/package.json +1 -1
- package/skills/build-label-page/SKILL.md +20 -2
- package/skills/build-label-page/SKILL.md.spec.ts +19 -1
- package/skills/build-label-page/references/closed-choice-generator.md +171 -5
- package/skills/build-label-page/scripts/fixtures/blocks-items.json +214 -0
- package/skills/build-label-page/scripts/fixtures/linter-config-witness-items.json +448 -0
- package/skills/build-label-page/scripts/label-page-answerers.test.ts +381 -0
- package/skills/build-label-page/scripts/label-page-blocks.test.ts +335 -0
- package/skills/build-label-page/scripts/label-page-browser.test.ts +637 -2
- package/skills/build-label-page/scripts/label-page-core.js +360 -70
- package/skills/build-label-page/scripts/label-page-core.test.ts +78 -11
- package/skills/build-label-page/scripts/label-page-core.ts +585 -107
- package/skills/build-label-page/scripts/label-page-html.test.ts +22 -0
- package/skills/build-label-page/scripts/label-page-presets.js +222 -0
- package/skills/build-label-page/scripts/label-page-presets.test.ts +175 -0
- package/skills/build-label-page/scripts/label-page-presets.ts +257 -0
- package/skills/build-label-page/scripts/label-page.js +13 -2
- package/skills/build-label-page/scripts/label-page.ts +13 -2
- package/skills/build-label-page/scripts/page-template.html +438 -44
|
@@ -41,6 +41,11 @@
|
|
|
41
41
|
* "seed": 7, fixes the order; change it and every id changes
|
|
42
42
|
* "groups": {"python": "Python"},
|
|
43
43
|
* "labeller_knows": ["python"], optional: items of other groups are not put on the page
|
|
44
|
+
* "answerers": ["author", "second"], optional, 2 or more: each answers under their own name;
|
|
45
|
+
* documents become `<answerer>~<id>`; an item's own
|
|
46
|
+
* `answerers` (a subset) shows it to those only
|
|
47
|
+
* "min_seconds": 30, optional: an answer saves only after its card was on
|
|
48
|
+
* screen that long; stored as `seconds`
|
|
44
49
|
* "familiarity": true, optional: a "how well do you know" question per group;
|
|
45
50
|
* left out, none is asked (an approval page)
|
|
46
51
|
* "familiarity_question": "How well do you know {group}?", optional
|
|
@@ -49,8 +54,8 @@
|
|
|
49
54
|
* "icon": "✅"}, icon: optional
|
|
50
55
|
* {"value": "no", "label": "No", "example": "another real case",
|
|
51
56
|
* "icon": "❌", "ask_why": "What is wrong with it?"}]}],
|
|
52
|
-
* ask_why: optional; the answer is
|
|
53
|
-
* reason is
|
|
57
|
+
* ask_why: optional; the answer is not saved until a
|
|
58
|
+
* reason is typed. In any shown text, backticks render
|
|
54
59
|
* as code.
|
|
55
60
|
* "practice": [{"body": "…", "expected": {"label": "yes"}, "why": "one line"}, …], 3 or more;
|
|
56
61
|
* a practice card may carry rules, unit, readings, file
|
|
@@ -66,6 +71,12 @@
|
|
|
66
71
|
* requirement marked in it; id (never shown) tells two
|
|
67
72
|
* places with the same words apart. kind approval requires
|
|
68
73
|
* unit and rules; kind witness rules, readings and file.
|
|
74
|
+
* Content blocks (situation, excerpt, references, more,
|
|
75
|
+
* table, repeat) and page `labels`: optional on any kind
|
|
76
|
+
* (references/closed-choice-generator.md, and
|
|
77
|
+
* scripts/fixtures/blocks-items.json for a whole page);
|
|
78
|
+
* "preset": "<name>" maps a preset's own card fields onto
|
|
79
|
+
* them (scripts/label-page-presets.ts).
|
|
69
80
|
* }
|
|
70
81
|
*
|
|
71
82
|
* TypeScript, compiled beside itself to `label-page.js` by `npm run build`: a consumer runs the skill
|
|
@@ -41,6 +41,11 @@
|
|
|
41
41
|
* "seed": 7, fixes the order; change it and every id changes
|
|
42
42
|
* "groups": {"python": "Python"},
|
|
43
43
|
* "labeller_knows": ["python"], optional: items of other groups are not put on the page
|
|
44
|
+
* "answerers": ["author", "second"], optional, 2 or more: each answers under their own name;
|
|
45
|
+
* documents become `<answerer>~<id>`; an item's own
|
|
46
|
+
* `answerers` (a subset) shows it to those only
|
|
47
|
+
* "min_seconds": 30, optional: an answer saves only after its card was on
|
|
48
|
+
* screen that long; stored as `seconds`
|
|
44
49
|
* "familiarity": true, optional: a "how well do you know" question per group;
|
|
45
50
|
* left out, none is asked (an approval page)
|
|
46
51
|
* "familiarity_question": "How well do you know {group}?", optional
|
|
@@ -49,8 +54,8 @@
|
|
|
49
54
|
* "icon": "✅"}, icon: optional
|
|
50
55
|
* {"value": "no", "label": "No", "example": "another real case",
|
|
51
56
|
* "icon": "❌", "ask_why": "What is wrong with it?"}]}],
|
|
52
|
-
* ask_why: optional; the answer is
|
|
53
|
-
* reason is
|
|
57
|
+
* ask_why: optional; the answer is not saved until a
|
|
58
|
+
* reason is typed. In any shown text, backticks render
|
|
54
59
|
* as code.
|
|
55
60
|
* "practice": [{"body": "…", "expected": {"label": "yes"}, "why": "one line"}, …], 3 or more;
|
|
56
61
|
* a practice card may carry rules, unit, readings, file
|
|
@@ -66,6 +71,12 @@
|
|
|
66
71
|
* requirement marked in it; id (never shown) tells two
|
|
67
72
|
* places with the same words apart. kind approval requires
|
|
68
73
|
* unit and rules; kind witness rules, readings and file.
|
|
74
|
+
* Content blocks (situation, excerpt, references, more,
|
|
75
|
+
* table, repeat) and page `labels`: optional on any kind
|
|
76
|
+
* (references/closed-choice-generator.md, and
|
|
77
|
+
* scripts/fixtures/blocks-items.json for a whole page);
|
|
78
|
+
* "preset": "<name>" maps a preset's own card fields onto
|
|
79
|
+
* them (scripts/label-page-presets.ts).
|
|
69
80
|
* }
|
|
70
81
|
*
|
|
71
82
|
* TypeScript, compiled beside itself to `label-page.js` by `npm run build`: a consumer runs the skill
|