@gmb/bitmark-parser-generator 5.2.0 → 5.3.1
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/browser/bitmark-parser-generator.min.js +1 -1
- package/dist/browser/bundle-report.html +2 -2
- package/dist/browser/cjs/index.cjs +39 -1
- package/dist/browser/cjs/index.cjs.map +1 -1
- package/dist/browser/cjs/index.d.cts +9 -0
- package/dist/browser/esm/index.d.ts +9 -0
- package/dist/browser/esm/index.js +39 -1
- package/dist/browser/esm/index.js.map +1 -1
- package/dist/cli/main.js +266 -69
- package/dist/cli/main.js.map +1 -1
- package/dist/index.cjs +229 -32
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +9 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.js +229 -32
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -261,6 +261,7 @@ declare const BitType: {
|
|
|
261
261
|
readonly flashcard1: "flashcard-1";
|
|
262
262
|
readonly focusImage: "focus-image";
|
|
263
263
|
readonly footNote: "foot-note";
|
|
264
|
+
readonly formFreeText: "form-free-text";
|
|
264
265
|
readonly formula: "formula";
|
|
265
266
|
readonly gapText: "gap-text";
|
|
266
267
|
readonly gapTextInstructionGrouped: "gap-text-instruction-grouped";
|
|
@@ -273,6 +274,8 @@ declare const BitType: {
|
|
|
273
274
|
readonly handInFeedbackExpert: "hand-in-feedback-expert";
|
|
274
275
|
readonly handInFeedbackSelf: "hand-in-feedback-self";
|
|
275
276
|
readonly handInFile: "hand-in-file";
|
|
277
|
+
readonly handInFreeText: "hand-in-free-text";
|
|
278
|
+
readonly handInFreeTextExpert: "hand-in-free-text-expert";
|
|
276
279
|
readonly handInLocation: "hand-in-location";
|
|
277
280
|
readonly handInPhoto: "hand-in-photo";
|
|
278
281
|
readonly handInScan: "hand-in-scan";
|
|
@@ -868,6 +871,7 @@ declare const ConfigKey: {
|
|
|
868
871
|
readonly property_platformMargin: "@platformMargin";
|
|
869
872
|
readonly property_platformBorderRadius: "@platformBorderRadius";
|
|
870
873
|
readonly property_platformSelectionBorderRadius: "@platformSelectionBorderRadius";
|
|
874
|
+
readonly property_platformLogoMaxHeight: "@platformLogoMaxHeight";
|
|
871
875
|
readonly property_platformNeedsShadow: "@platformNeedsShadow";
|
|
872
876
|
readonly property_platformSeparatorColor: "@platformSeparatorColor";
|
|
873
877
|
readonly property_platformTextSelectionColor: "@platformTextSelectionColor";
|
|
@@ -1795,6 +1799,7 @@ interface BitJson {
|
|
|
1795
1799
|
platformName: string;
|
|
1796
1800
|
platformIcon: ImageResourceWrapperJson;
|
|
1797
1801
|
platformLogo: ImageResourceWrapperJson;
|
|
1802
|
+
platformLogoMaxHeight: number;
|
|
1798
1803
|
platformPrimaryColor: string;
|
|
1799
1804
|
platformSecondaryColor: string;
|
|
1800
1805
|
platformBackgroundColor: string;
|
|
@@ -2407,6 +2412,7 @@ interface Bit {
|
|
|
2407
2412
|
platformName?: Property;
|
|
2408
2413
|
platformIcon?: ImageResourceWrapperJson;
|
|
2409
2414
|
platformLogo?: ImageResourceWrapperJson;
|
|
2415
|
+
platformLogoMaxHeight?: Property;
|
|
2410
2416
|
platformPrimaryColor?: Property;
|
|
2411
2417
|
platformSecondaryColor?: Property;
|
|
2412
2418
|
platformBackgroundColor?: Property;
|
|
@@ -2925,6 +2931,8 @@ declare const NodeType: {
|
|
|
2925
2931
|
readonly platformIconValue: "platformIconValue";
|
|
2926
2932
|
readonly platformLogo: "platformLogo";
|
|
2927
2933
|
readonly platformLogoValue: "platformLogoValue";
|
|
2934
|
+
readonly platformLogoMaxHeight: "platformLogoMaxHeight";
|
|
2935
|
+
readonly platformLogoMaxHeightValue: "platformLogoMaxHeightValue";
|
|
2928
2936
|
readonly platformPrimaryColor: "platformPrimaryColor";
|
|
2929
2937
|
readonly platformPrimaryColorValue: "platformPrimaryColorValue";
|
|
2930
2938
|
readonly platformSecondaryColor: "platformSecondaryColor";
|
|
@@ -4210,6 +4218,7 @@ declare class Builder extends BaseBuilder {
|
|
|
4210
4218
|
platformName?: string;
|
|
4211
4219
|
platformIcon?: Partial<ImageResourceWrapperJson>;
|
|
4212
4220
|
platformLogo?: Partial<ImageResourceWrapperJson>;
|
|
4221
|
+
platformLogoMaxHeight?: number;
|
|
4213
4222
|
platformPrimaryColor?: string;
|
|
4214
4223
|
platformSecondaryColor?: string;
|
|
4215
4224
|
platformBackgroundColor?: string;
|
|
@@ -261,6 +261,7 @@ declare const BitType: {
|
|
|
261
261
|
readonly flashcard1: "flashcard-1";
|
|
262
262
|
readonly focusImage: "focus-image";
|
|
263
263
|
readonly footNote: "foot-note";
|
|
264
|
+
readonly formFreeText: "form-free-text";
|
|
264
265
|
readonly formula: "formula";
|
|
265
266
|
readonly gapText: "gap-text";
|
|
266
267
|
readonly gapTextInstructionGrouped: "gap-text-instruction-grouped";
|
|
@@ -273,6 +274,8 @@ declare const BitType: {
|
|
|
273
274
|
readonly handInFeedbackExpert: "hand-in-feedback-expert";
|
|
274
275
|
readonly handInFeedbackSelf: "hand-in-feedback-self";
|
|
275
276
|
readonly handInFile: "hand-in-file";
|
|
277
|
+
readonly handInFreeText: "hand-in-free-text";
|
|
278
|
+
readonly handInFreeTextExpert: "hand-in-free-text-expert";
|
|
276
279
|
readonly handInLocation: "hand-in-location";
|
|
277
280
|
readonly handInPhoto: "hand-in-photo";
|
|
278
281
|
readonly handInScan: "hand-in-scan";
|
|
@@ -868,6 +871,7 @@ declare const ConfigKey: {
|
|
|
868
871
|
readonly property_platformMargin: "@platformMargin";
|
|
869
872
|
readonly property_platformBorderRadius: "@platformBorderRadius";
|
|
870
873
|
readonly property_platformSelectionBorderRadius: "@platformSelectionBorderRadius";
|
|
874
|
+
readonly property_platformLogoMaxHeight: "@platformLogoMaxHeight";
|
|
871
875
|
readonly property_platformNeedsShadow: "@platformNeedsShadow";
|
|
872
876
|
readonly property_platformSeparatorColor: "@platformSeparatorColor";
|
|
873
877
|
readonly property_platformTextSelectionColor: "@platformTextSelectionColor";
|
|
@@ -1795,6 +1799,7 @@ interface BitJson {
|
|
|
1795
1799
|
platformName: string;
|
|
1796
1800
|
platformIcon: ImageResourceWrapperJson;
|
|
1797
1801
|
platformLogo: ImageResourceWrapperJson;
|
|
1802
|
+
platformLogoMaxHeight: number;
|
|
1798
1803
|
platformPrimaryColor: string;
|
|
1799
1804
|
platformSecondaryColor: string;
|
|
1800
1805
|
platformBackgroundColor: string;
|
|
@@ -2407,6 +2412,7 @@ interface Bit {
|
|
|
2407
2412
|
platformName?: Property;
|
|
2408
2413
|
platformIcon?: ImageResourceWrapperJson;
|
|
2409
2414
|
platformLogo?: ImageResourceWrapperJson;
|
|
2415
|
+
platformLogoMaxHeight?: Property;
|
|
2410
2416
|
platformPrimaryColor?: Property;
|
|
2411
2417
|
platformSecondaryColor?: Property;
|
|
2412
2418
|
platformBackgroundColor?: Property;
|
|
@@ -2925,6 +2931,8 @@ declare const NodeType: {
|
|
|
2925
2931
|
readonly platformIconValue: "platformIconValue";
|
|
2926
2932
|
readonly platformLogo: "platformLogo";
|
|
2927
2933
|
readonly platformLogoValue: "platformLogoValue";
|
|
2934
|
+
readonly platformLogoMaxHeight: "platformLogoMaxHeight";
|
|
2935
|
+
readonly platformLogoMaxHeightValue: "platformLogoMaxHeightValue";
|
|
2928
2936
|
readonly platformPrimaryColor: "platformPrimaryColor";
|
|
2929
2937
|
readonly platformPrimaryColorValue: "platformPrimaryColorValue";
|
|
2930
2938
|
readonly platformSecondaryColor: "platformSecondaryColor";
|
|
@@ -4210,6 +4218,7 @@ declare class Builder extends BaseBuilder {
|
|
|
4210
4218
|
platformName?: string;
|
|
4211
4219
|
platformIcon?: Partial<ImageResourceWrapperJson>;
|
|
4212
4220
|
platformLogo?: Partial<ImageResourceWrapperJson>;
|
|
4221
|
+
platformLogoMaxHeight?: number;
|
|
4213
4222
|
platformPrimaryColor?: string;
|
|
4214
4223
|
platformSecondaryColor?: string;
|
|
4215
4224
|
platformBackgroundColor?: string;
|
|
@@ -270,6 +270,7 @@ var BitType = {
|
|
|
270
270
|
flashcard1: "flashcard-1",
|
|
271
271
|
focusImage: "focus-image",
|
|
272
272
|
footNote: "foot-note",
|
|
273
|
+
formFreeText: "form-free-text",
|
|
273
274
|
formula: "formula",
|
|
274
275
|
gapText: "gap-text",
|
|
275
276
|
gapTextInstructionGrouped: "gap-text-instruction-grouped",
|
|
@@ -282,6 +283,8 @@ var BitType = {
|
|
|
282
283
|
handInFeedbackExpert: "hand-in-feedback-expert",
|
|
283
284
|
handInFeedbackSelf: "hand-in-feedback-self",
|
|
284
285
|
handInFile: "hand-in-file",
|
|
286
|
+
handInFreeText: "hand-in-free-text",
|
|
287
|
+
handInFreeTextExpert: "hand-in-free-text-expert",
|
|
285
288
|
handInLocation: "hand-in-location",
|
|
286
289
|
handInPhoto: "hand-in-photo",
|
|
287
290
|
handInScan: "hand-in-scan",
|
|
@@ -1294,6 +1297,7 @@ var propertyKeys = {
|
|
|
1294
1297
|
property_platformMargin: "@platformMargin",
|
|
1295
1298
|
property_platformBorderRadius: "@platformBorderRadius",
|
|
1296
1299
|
property_platformSelectionBorderRadius: "@platformSelectionBorderRadius",
|
|
1300
|
+
property_platformLogoMaxHeight: "@platformLogoMaxHeight",
|
|
1297
1301
|
property_platformNeedsShadow: "@platformNeedsShadow",
|
|
1298
1302
|
property_platformSeparatorColor: "@platformSeparatorColor",
|
|
1299
1303
|
property_platformTextSelectionColor: "@platformTextSelectionColor",
|
|
@@ -8736,6 +8740,11 @@ var BITS = {
|
|
|
8736
8740
|
],
|
|
8737
8741
|
maxCount: 1
|
|
8738
8742
|
},
|
|
8743
|
+
{
|
|
8744
|
+
key: ConfigKey.property_platformLogoMaxHeight,
|
|
8745
|
+
description: "Maximum height for the platform logo",
|
|
8746
|
+
format: TagFormat.number
|
|
8747
|
+
},
|
|
8739
8748
|
{
|
|
8740
8749
|
key: ConfigKey.group_platformStylesCommon,
|
|
8741
8750
|
description: "Common platform styles"
|
|
@@ -9430,6 +9439,11 @@ var BITS = {
|
|
|
9430
9439
|
baseBitType: BitType._standard,
|
|
9431
9440
|
description: "Footnote bit, used to create footnotes in articles or books"
|
|
9432
9441
|
},
|
|
9442
|
+
[BitType.formFreeText]: {
|
|
9443
|
+
since: "5.3.0",
|
|
9444
|
+
baseBitType: BitType.interview,
|
|
9445
|
+
description: "Form free text bit, used to create free text forms in articles or books"
|
|
9446
|
+
},
|
|
9433
9447
|
[BitType.groupBorn]: {
|
|
9434
9448
|
since: "1.3.0",
|
|
9435
9449
|
baseBitType: BitType._standard,
|
|
@@ -9489,6 +9503,16 @@ var BITS = {
|
|
|
9489
9503
|
}
|
|
9490
9504
|
]
|
|
9491
9505
|
},
|
|
9506
|
+
[BitType.handInFreeText]: {
|
|
9507
|
+
since: "5.3.0",
|
|
9508
|
+
baseBitType: BitType.interview,
|
|
9509
|
+
description: "Hand in free text bit, used to create free text submission sections in articles or books"
|
|
9510
|
+
},
|
|
9511
|
+
[BitType.handInFreeTextExpert]: {
|
|
9512
|
+
since: "5.3.0",
|
|
9513
|
+
baseBitType: BitType.interview,
|
|
9514
|
+
description: "Hand in free text expert bit, used to create free text expert submission sections in articles or books"
|
|
9515
|
+
},
|
|
9492
9516
|
[BitType.handInLocation]: {
|
|
9493
9517
|
since: "1.5.15",
|
|
9494
9518
|
baseBitType: BitType._standard,
|
|
@@ -10232,7 +10256,7 @@ var instance2 = new Config();
|
|
|
10232
10256
|
// src/generated/package_info.ts
|
|
10233
10257
|
var PACKAGE_INFO = {
|
|
10234
10258
|
"name": "@gmb/bitmark-parser-generator",
|
|
10235
|
-
"version": "5.
|
|
10259
|
+
"version": "5.3.1",
|
|
10236
10260
|
"author": "Get More Brain Ltd",
|
|
10237
10261
|
"license": "ISC",
|
|
10238
10262
|
"description": "A bitmark parser and generator using Peggy.js"
|
|
@@ -10974,6 +10998,8 @@ var NodeType = {
|
|
|
10974
10998
|
platformIconValue: "platformIconValue",
|
|
10975
10999
|
platformLogo: "platformLogo",
|
|
10976
11000
|
platformLogoValue: "platformLogoValue",
|
|
11001
|
+
platformLogoMaxHeight: "platformLogoMaxHeight",
|
|
11002
|
+
platformLogoMaxHeightValue: "platformLogoMaxHeightValue",
|
|
10977
11003
|
platformPrimaryColor: "platformPrimaryColor",
|
|
10978
11004
|
platformPrimaryColorValue: "platformPrimaryColorValue",
|
|
10979
11005
|
platformSecondaryColor: "platformSecondaryColor",
|
|
@@ -24762,6 +24788,12 @@ var Builder = class extends BaseBuilder {
|
|
|
24762
24788
|
),
|
|
24763
24789
|
platformIcon: this.toImageResource(context, data.platformIcon),
|
|
24764
24790
|
platformLogo: this.toImageResource(context, data.platformLogo),
|
|
24791
|
+
platformLogoMaxHeight: this.toAstProperty(
|
|
24792
|
+
bitType,
|
|
24793
|
+
ConfigKey.property_platformLogoMaxHeight,
|
|
24794
|
+
data.platformLogoMaxHeight,
|
|
24795
|
+
options
|
|
24796
|
+
),
|
|
24765
24797
|
platformPrimaryColor: this.toAstProperty(
|
|
24766
24798
|
bitType,
|
|
24767
24799
|
ConfigKey.property_platformPrimaryColor,
|
|
@@ -30516,6 +30548,9 @@ var JsonGenerator = class extends AstWalkerGenerator {
|
|
|
30516
30548
|
if (instance2.isOfBitType(bitType, BitType.platformBrandTarget)) {
|
|
30517
30549
|
if (bitJson.platformBrandTarget == null) bitJson.platformBrandTarget = "none";
|
|
30518
30550
|
}
|
|
30551
|
+
if (instance2.isOfBitType(bitType, BitType.platformHeader)) {
|
|
30552
|
+
if (bitJson.platformLogoMaxHeight == null) bitJson.platformLogoMaxHeight = 40;
|
|
30553
|
+
}
|
|
30519
30554
|
if (isTopLevelExample) {
|
|
30520
30555
|
if (bitJson.isExample == null) bitJson.isExample = false;
|
|
30521
30556
|
} else {
|
|
@@ -32785,6 +32820,9 @@ function parseFeedback(_context, _bitType, cardSet) {
|
|
|
32785
32820
|
const choice = {
|
|
32786
32821
|
choice: tfTags.choice,
|
|
32787
32822
|
requireReason: tfTags.isCorrect,
|
|
32823
|
+
item: tfTags.item,
|
|
32824
|
+
lead: tfTags.lead,
|
|
32825
|
+
instruction: tfTags.instruction,
|
|
32788
32826
|
__isDefaultExample,
|
|
32789
32827
|
example
|
|
32790
32828
|
};
|