tpmkms_4wp 8.9.1-beta.2 → 8.9.1-beta.21

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.
Files changed (80) hide show
  1. package/common/animals.instance.json +348 -68
  2. package/common/articles.js +20 -4
  3. package/common/articles.test.json +338 -0
  4. package/common/asking.js +3 -3
  5. package/common/asking.test.json +41 -0
  6. package/common/avatar.js +1 -1
  7. package/common/characters.js +1 -1
  8. package/common/colors.instance.json +608 -113
  9. package/common/comparable.instance.json +60 -12
  10. package/common/comparable.js +2 -2
  11. package/common/concept.js +2 -2
  12. package/common/conjunction.js +1 -1
  13. package/common/countable.js +3 -9
  14. package/common/countable.test.json +0 -586
  15. package/common/crew.instance.json +520 -392
  16. package/common/currency.js +2 -2
  17. package/common/dialogues.js +28 -11
  18. package/common/dimension.instance.json +16 -8
  19. package/common/dimension.js +2 -2
  20. package/common/edible.instance.json +595 -229
  21. package/common/emotions.instance.json +20 -4
  22. package/common/errors.js +3 -1
  23. package/common/events.js +1 -1
  24. package/common/fastfood.instance.json +2095 -1498
  25. package/common/fastfood.js +16 -10
  26. package/common/formulas.instance.json +16 -5
  27. package/common/formulas.js +1 -1
  28. package/common/formulas.test.json +461 -10
  29. package/common/gdefaults.js +27 -14
  30. package/common/help.js +4 -4
  31. package/common/help.test.json +4 -4
  32. package/common/helpers/concept.js +5 -5
  33. package/common/helpers/conjunction.js +1 -1
  34. package/common/helpers/formulas.js +4 -4
  35. package/common/helpers/frankenhash.js +4 -4
  36. package/common/helpers/meta.js +4 -4
  37. package/common/helpers/ordering.js +2 -2
  38. package/common/helpers/properties.js +17 -17
  39. package/common/helpers.js +17 -1
  40. package/common/hierarchy.js +3 -3
  41. package/common/javascript.js +1 -1
  42. package/common/kirk.instance.json +20 -4
  43. package/common/length.instance.json +300 -80
  44. package/common/math.instance.json +16 -5
  45. package/common/math.js +1 -1
  46. package/common/meta.js +5 -5
  47. package/common/nameable.js +1 -1
  48. package/common/negation.js +1 -1
  49. package/common/numbers.js +1 -1
  50. package/common/ordering.instance.json +41 -11
  51. package/common/ordinals.js +9 -3
  52. package/common/ordinals.test.json +327 -0
  53. package/common/people.instance.json +228 -80
  54. package/common/people.js +1 -1
  55. package/common/percentages.js +1 -1
  56. package/common/pipboy.instance.json +334 -180
  57. package/common/pipboy.js +6 -6
  58. package/common/pokemon.instance.json +304 -57
  59. package/common/pos.js +16 -6
  60. package/common/pressure.instance.json +64 -23
  61. package/common/properties.instance.json +20 -4
  62. package/common/properties.js +6 -6
  63. package/common/punctuation.js +1 -1
  64. package/common/reports.instance.json +34 -12
  65. package/common/reports.js +9 -9
  66. package/common/scorekeeper.js +5 -5
  67. package/common/sdefaults.js +2 -2
  68. package/common/sizeable.js +2 -2
  69. package/common/spock.instance.json +20 -4
  70. package/common/stm.js +6 -6
  71. package/common/tell.js +1 -1
  72. package/common/temperature.instance.json +64 -24
  73. package/common/tester.js +1 -1
  74. package/common/ui.instance.json +21 -5
  75. package/common/weight.instance.json +261 -109
  76. package/common/wp.instance.json +6621 -404
  77. package/common/wp.js +199 -41
  78. package/common/wp.test.json +109575 -3828
  79. package/common/yesno.js +1 -1
  80. package/package.json +11 -6
@@ -275,7 +275,7 @@ const template = {
275
275
  { context: [['meal', 0], ['list', 0], ['meal', 0], ['comboMeal', 0]], ordered: true, choose: [0,1,2] },
276
276
  // { context: [['crispy_chicken_club', 0], ['chicken_club', 0], ['chicken_sandwich', 0]], choose: [0] },
277
277
  { context: [['breakfast_baconator', 0], ['breakfast_meal', 0]], choose: [0] },
278
- { context: [['list', 0], ['articlePOS',0], ['smoothie_ingredient', 0], ['smoothie', 0]], ordered: true, choose: [1,2] },
278
+ { context: [['list', 0], ['article',0], ['smoothie_ingredient', 0], ['smoothie', 0]], ordered: true, choose: [1,2] },
279
279
  ]
280
280
  },
281
281
  // { stop: true },
@@ -323,7 +323,7 @@ const template = {
323
323
 
324
324
  const hasDrink = (isA, item) => {
325
325
  let hasDrink = false
326
- for (let modification of (item.modifications || [])) {
326
+ for (const modification of (item.modifications || [])) {
327
327
  if (isA(modification.id, 'drink')) {
328
328
  hasDrink = true
329
329
  break
@@ -385,7 +385,7 @@ const template = {
385
385
  const { api, context } = args
386
386
  if (isMany(context)) {
387
387
  let count = getCount(context) || Number.MAX_SAFE_INTEGER
388
- for (let item of needsDrink) {
388
+ for (const item of needsDrink) {
389
389
  if (count < 1) {
390
390
  break
391
391
  }
@@ -534,8 +534,19 @@ class API {
534
534
  return [...this._objects.items]
535
535
  }
536
536
 
537
+ fixUpItemId(item) {
538
+ if (item.id == 'coke') {
539
+ item.id = 'coca_cola'
540
+ }
541
+
542
+ if (item.id == 'fry') {
543
+ item.id = 'french_fry'
544
+ }
545
+ }
546
+
537
547
  addDrink(item_id, drink) {
538
548
  const item = this.toItem(item_id)
549
+ this.fixUpItemId(drink)
539
550
  item.modifications.push(drink)
540
551
  item.needsDrink = false
541
552
  }
@@ -598,7 +609,7 @@ class API {
598
609
 
599
610
  if (item.combo) {
600
611
  item.needsDrink = true
601
- for (let modification of item.modifications || []) {
612
+ for (const modification of item.modifications || []) {
602
613
  // TODO check for awailable
603
614
  if (this.args.isA(modification.id, 'drink')) {
604
615
  item.needsDrink = false
@@ -606,13 +617,8 @@ class API {
606
617
  }
607
618
  }
608
619
 
609
- if (item.id == 'coke') {
610
- item.id = 'coca_cola'
611
- }
612
620
 
613
- if (item.id == 'fry') {
614
- item.id = 'french_fry'
615
- }
621
+ this.fixUpItemId(item)
616
622
 
617
623
  return [
618
624
  "hamburger",
@@ -115,7 +115,7 @@
115
115
  "hierarchy": [
116
116
  [
117
117
  "a",
118
- "articlePOS",
118
+ "article",
119
119
  false
120
120
  ],
121
121
  [
@@ -129,8 +129,8 @@
129
129
  false
130
130
  ],
131
131
  [
132
- "articlePOS",
133
- "articlePOS",
132
+ "article",
133
+ "article",
134
134
  false
135
135
  ],
136
136
  [
@@ -248,6 +248,11 @@
248
248
  "theAble",
249
249
  false
250
250
  ],
251
+ [
252
+ "distributable",
253
+ "queryable",
254
+ false
255
+ ],
251
256
  [
252
257
  "divideByExpression",
253
258
  "mathematicalExpression",
@@ -263,6 +268,11 @@
263
268
  "queryable",
264
269
  false
265
270
  ],
271
+ [
272
+ "each",
273
+ "article",
274
+ false
275
+ ],
266
276
  [
267
277
  "evaluate",
268
278
  "verb",
@@ -270,7 +280,7 @@
270
280
  ],
271
281
  [
272
282
  "every",
273
- "quantifier",
283
+ "article",
274
284
  false
275
285
  ],
276
286
  [
@@ -780,7 +790,7 @@
780
790
  ],
781
791
  [
782
792
  "the",
783
- "articlePOS",
793
+ "article",
784
794
  false
785
795
  ],
786
796
  [
@@ -1009,6 +1019,7 @@
1009
1019
  },
1010
1020
  "dead": true,
1011
1021
  "level": 2,
1022
+ "context_index": 1,
1012
1023
  "topLevel": true,
1013
1024
  "touchedBy": [
1014
1025
  "formulas#call2"
@@ -91,7 +91,7 @@ class API {
91
91
  }
92
92
  */
93
93
 
94
- let config = {
94
+ const config = {
95
95
  name: 'formulas',
96
96
  operators: [
97
97
  // TODO notations like (([arg1:]) [op] ([arg2:nameOfArg2}|word1])) -> just make the bridge + operators. put this in the bridge def / also calculate generators