optolith-database-schema 0.8.1 → 0.10.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.
Files changed (106) hide show
  1. package/CHANGELOG.md +44 -0
  2. package/lib/config.d.ts +2 -0
  3. package/lib/config.js +2 -0
  4. package/lib/main.js +8 -3
  5. package/lib/types/Advantage.d.ts +13 -2
  6. package/lib/types/Disadvantage.d.ts +12 -2
  7. package/lib/types/Profession.d.ts +12 -2
  8. package/lib/types/Talisman.d.ts +6 -6
  9. package/lib/types/_Activatable.d.ts +113 -4
  10. package/lib/types/_Activatable.js +4 -35
  11. package/lib/types/_ActivatableSelectOptionCategory.d.ts +30 -0
  12. package/lib/types/_Identifier.d.ts +9 -0
  13. package/lib/types/_IdentifierGroup.d.ts +2 -2
  14. package/lib/types/equipment/item/Poison.d.ts +21 -1
  15. package/lib/types/equipment/item/Poison.js +1 -0
  16. package/lib/types/equipment/item/Weapon.d.ts +4 -3
  17. package/lib/types/equipment/item/sub/ArmorType.d.ts +3 -3
  18. package/lib/types/magicalActions/MagicalRune.d.ts +82 -16
  19. package/lib/types/prerequisites/DisplayOption.d.ts +14 -0
  20. package/lib/types/prerequisites/PrerequisiteGroups.d.ts +23 -1
  21. package/lib/types/prerequisites/single/AncestorBloodPrerequisite.d.ts +5 -0
  22. package/lib/types/prerequisites/single/AncestorBloodPrerequisite.js +1 -0
  23. package/lib/types/prerequisites/single/RatedMinimumNumberPrerequisite.d.ts +67 -0
  24. package/lib/types/prerequisites/single/RatedMinimumNumberPrerequisite.js +6 -0
  25. package/lib/types/prerequisites/single/RatedPrerequisite.d.ts +0 -55
  26. package/lib/types/prerequisites/single/RatedSumPrerequisite.d.ts +19 -0
  27. package/lib/types/prerequisites/single/RatedSumPrerequisite.js +1 -0
  28. package/lib/types/prerequisites/single/SexualCharacteristicPrerequisite.d.ts +11 -0
  29. package/lib/types/prerequisites/single/SexualCharacteristicPrerequisite.js +5 -0
  30. package/lib/types/prerequisites/single/TextPrerequisite.d.ts +29 -0
  31. package/lib/types/prerequisites/single/TextPrerequisite.js +5 -0
  32. package/lib/types/specialAbility/AdvancedCombatSpecialAbility.d.ts +11 -0
  33. package/lib/types/specialAbility/CeremonialItemSpecialAbility.d.ts +7 -2
  34. package/lib/types/specialAbility/CombatSpecialAbility.d.ts +6 -2
  35. package/lib/types/specialAbility/FatePointSpecialAbility.d.ts +5 -0
  36. package/lib/types/specialAbility/GeneralSpecialAbility.d.ts +12 -2
  37. package/lib/types/specialAbility/KarmaSpecialAbility.d.ts +7 -2
  38. package/lib/types/specialAbility/MagicalSign.d.ts +38 -0
  39. package/lib/types/specialAbility/MagicalSign.js +5 -0
  40. package/lib/types/specialAbility/MagicalSpecialAbility.d.ts +11 -2
  41. package/lib/types/specialAbility/MagicalTradition.d.ts +2 -2
  42. package/lib/types/specialAbility/ProtectiveWardingCircleSpecialAbility.d.ts +6 -0
  43. package/lib/types/specialAbility/SikaryanDrainSpecialAbility.d.ts +5 -0
  44. package/lib/types/specialAbility/VampiricGift.d.ts +7 -2
  45. package/lib/types/traditionArtifacts/ArcaneOrbEnchantment.d.ts +2 -2
  46. package/lib/types/traditionArtifacts/AttireEnchantment.d.ts +2 -2
  47. package/lib/types/traditionArtifacts/BowlEnchantment.d.ts +2 -2
  48. package/lib/types/traditionArtifacts/CauldronEnchantment.d.ts +2 -2
  49. package/lib/types/traditionArtifacts/ChronicleEnchantment.d.ts +2 -2
  50. package/lib/types/traditionArtifacts/DaggerRitual.d.ts +3 -3
  51. package/lib/types/traditionArtifacts/FoolsHatEnchantment.d.ts +2 -2
  52. package/lib/types/traditionArtifacts/InstrumentEnchantment.d.ts +2 -2
  53. package/lib/types/traditionArtifacts/Krallenkettenzauber.d.ts +2 -2
  54. package/lib/types/traditionArtifacts/OrbEnchantment.d.ts +2 -2
  55. package/lib/types/traditionArtifacts/RingEnchantment.d.ts +2 -2
  56. package/lib/types/traditionArtifacts/SickleRitual.d.ts +2 -2
  57. package/lib/types/traditionArtifacts/SpellSwordEnchantment.d.ts +7 -2
  58. package/lib/types/traditionArtifacts/StaffEnchantment.d.ts +13 -3
  59. package/lib/types/traditionArtifacts/ToyEnchantment.d.ts +3 -3
  60. package/lib/types/traditionArtifacts/Trinkhornzauber.d.ts +2 -2
  61. package/lib/types/traditionArtifacts/WandEnchantment.d.ts +2 -7
  62. package/lib/types/traditionArtifacts/WeaponEnchantment.d.ts +4 -3
  63. package/lib/validation/schema.js +2 -2
  64. package/package.json +1 -1
  65. package/schema/Advantage.schema.json +11 -0
  66. package/schema/Disadvantage.schema.json +8 -0
  67. package/schema/Profession.schema.json +8 -0
  68. package/schema/Talisman.schema.json +2 -4
  69. package/schema/_Activatable.schema.json +166 -0
  70. package/schema/_ActivatableSelectOptionCategory.schema.json +141 -0
  71. package/schema/_Identifier.schema.json +18 -0
  72. package/schema/_IdentifierGroup.schema.json +6 -0
  73. package/schema/equipment/item/Poison.schema.json +55 -1
  74. package/schema/equipment/item/Weapon.schema.json +5 -1
  75. package/schema/equipment/item/sub/ArmorType.schema.json +1 -2
  76. package/schema/magicalActions/MagicalRune.schema.json +213 -21
  77. package/schema/prerequisites/DisplayOption.schema.json +4 -0
  78. package/schema/prerequisites/PrerequisiteGroups.schema.json +98 -2
  79. package/schema/prerequisites/single/AncestorBloodPrerequisite.schema.json +14 -0
  80. package/schema/prerequisites/single/RatedMinimumNumberPrerequisite.schema.json +166 -0
  81. package/schema/prerequisites/single/RatedPrerequisite.schema.json +0 -125
  82. package/schema/prerequisites/single/RatedSumPrerequisite.schema.json +33 -0
  83. package/schema/prerequisites/single/SexualCharacteristicPrerequisite.schema.json +26 -0
  84. package/schema/prerequisites/single/TextPrerequisite.schema.json +14 -0
  85. package/schema/specialAbility/AdvancedCombatSpecialAbility.schema.json +8 -0
  86. package/schema/specialAbility/CeremonialItemSpecialAbility.schema.json +4 -0
  87. package/schema/specialAbility/CombatSpecialAbility.schema.json +4 -0
  88. package/schema/specialAbility/CombatStyleSpecialAbility.schema.json +42 -27
  89. package/schema/specialAbility/FatePointSpecialAbility.schema.json +4 -0
  90. package/schema/specialAbility/GeneralSpecialAbility.schema.json +8 -0
  91. package/schema/specialAbility/KarmaSpecialAbility.schema.json +4 -0
  92. package/schema/specialAbility/LiturgicalStyleSpecialAbility.schema.json +42 -27
  93. package/schema/specialAbility/MagicStyleSpecialAbility.schema.json +42 -27
  94. package/schema/specialAbility/MagicalSign.schema.json +72 -0
  95. package/schema/specialAbility/MagicalSpecialAbility.schema.json +8 -0
  96. package/schema/specialAbility/MagicalTradition.schema.json +0 -2
  97. package/schema/specialAbility/ProtectiveWardingCircleSpecialAbility.schema.json +6 -0
  98. package/schema/specialAbility/SikaryanDrainSpecialAbility.schema.json +4 -0
  99. package/schema/specialAbility/SkillStyleSpecialAbility.schema.json +42 -27
  100. package/schema/specialAbility/VampiricGift.schema.json +4 -0
  101. package/schema/traditionArtifacts/DaggerRitual.schema.json +0 -1
  102. package/schema/traditionArtifacts/SpellSwordEnchantment.schema.json +4 -0
  103. package/schema/traditionArtifacts/StaffEnchantment.schema.json +8 -1
  104. package/schema/traditionArtifacts/ToyEnchantment.schema.json +0 -1
  105. package/schema/traditionArtifacts/WandEnchantment.schema.json +1 -9
  106. package/schema/traditionArtifacts/WeaponEnchantment.schema.json +8 -1
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main CombatSpecialAbility
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Combat Special Ability
11
11
  */
@@ -30,6 +30,10 @@ export declare type CombatSpecialAbility = {
30
30
  export declare type CombatSpecialAbilityTranslation = {
31
31
  name: Activatable.Name;
32
32
  name_in_library?: Activatable.NameInLibrary;
33
+ /**
34
+ * A string that is used as a label for an input field.
35
+ */
36
+ input?: Activatable.Input;
33
37
  rules: Activatable.Rules;
34
38
  /**
35
39
  * @deprecated
@@ -28,6 +28,11 @@ export declare type FatePointSpecialAbilityTranslation = {
28
28
  name: Activatable.Name;
29
29
  name_in_library?: Activatable.NameInLibrary;
30
30
  rules: Activatable.Rules;
31
+ /**
32
+ * The AP value. It is only used if the text cannot be generated from the
33
+ * given information.
34
+ */
35
+ ap_value?: Activatable.AdventurePointsValueReplacement;
31
36
  errata?: Errata;
32
37
  };
33
38
  export declare const validateSchema: import("../../validation/schema.js").TypeValidator<FatePointSpecialAbility>;
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main GeneralSpecialAbility
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title General Special Ability
11
11
  */
@@ -27,7 +27,17 @@ export declare type GeneralSpecialAbility = {
27
27
  export declare type GeneralSpecialAbilityTranslation = {
28
28
  name: Activatable.Name;
29
29
  name_in_library?: Activatable.NameInLibrary;
30
+ /**
31
+ * A string that is used as a label for an input field.
32
+ */
33
+ input?: Activatable.Input;
30
34
  rules: Activatable.Rules;
35
+ /**
36
+ * A string that gets appended to the default AP Value text with a preceding
37
+ * space. This always happens if present, even if the generated AP Value text
38
+ * is replaced.
39
+ */
40
+ ap_value_append?: Activatable.AdventurePointsValueAppend;
31
41
  errata?: Errata;
32
42
  };
33
43
  export declare const validateSchema: import("../../validation/schema.js").TypeValidator<GeneralSpecialAbility>;
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main KarmaSpecialAbility
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Karma Special Ability
11
11
  */
@@ -26,6 +26,11 @@ export declare type KarmaSpecialAbilityTranslation = {
26
26
  name: Activatable.Name;
27
27
  name_in_library?: Activatable.NameInLibrary;
28
28
  rules: Activatable.Rules;
29
+ /**
30
+ * The AP value. It is only used if the text cannot be generated from the
31
+ * given information.
32
+ */
33
+ ap_value?: Activatable.AdventurePointsValueReplacement;
29
34
  errata?: Errata;
30
35
  };
31
36
  export declare const validateSchema: import("../../validation/schema.js").TypeValidator<KarmaSpecialAbility>;
@@ -0,0 +1,38 @@
1
+ /**
2
+ * @main MagicalSign
3
+ */
4
+ import { Errata } from "../source/_Erratum.js";
5
+ import { PublicationRefs } from "../source/_PublicationRef.js";
6
+ import * as Activatable from "../_Activatable.js";
7
+ import { LocaleMap } from "../_LocaleMap.js";
8
+ import { GeneralPrerequisites } from "../_Prerequisite.js";
9
+ import { PropertyReference } from "../_SimpleReferences.js";
10
+ /**
11
+ * @title Magical Sign
12
+ */
13
+ export declare type MagicalSign = {
14
+ id: Activatable.Id;
15
+ prerequisites?: GeneralPrerequisites;
16
+ /**
17
+ * The associated magic property.
18
+ */
19
+ property: PropertyReference;
20
+ /**
21
+ * The adventure points value.
22
+ * @integer
23
+ * @minimum 0
24
+ */
25
+ ap_value: number;
26
+ src: PublicationRefs;
27
+ /**
28
+ * All translations for the entry, identified by IETF language tag (BCP47).
29
+ */
30
+ translations: LocaleMap<ProtectiveWardingCircleSpecialAbilityTranslation>;
31
+ };
32
+ export declare type ProtectiveWardingCircleSpecialAbilityTranslation = {
33
+ name: Activatable.Name;
34
+ name_in_library?: Activatable.NameInLibrary;
35
+ effect: Activatable.Effect;
36
+ errata?: Errata;
37
+ };
38
+ export declare const validateSchema: import("../../validation/schema.js").TypeValidator<MagicalSign>;
@@ -0,0 +1,5 @@
1
+ /**
2
+ * @main MagicalSign
3
+ */
4
+ import { validateSchemaCreator } from "../../validation/schema.js";
5
+ export const validateSchema = validateSchemaCreator(import.meta.url);
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main MagicalSpecialAbility
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Magical Special Ability
11
11
  */
@@ -27,7 +27,16 @@ export declare type MagicalSpecialAbility = {
27
27
  export declare type MagicalSpecialAbilityTranslation = {
28
28
  name: Activatable.Name;
29
29
  name_in_library?: Activatable.NameInLibrary;
30
+ /**
31
+ * A string that is used as a label for an input field.
32
+ */
33
+ input?: Activatable.Input;
30
34
  rules: Activatable.Rules;
35
+ /**
36
+ * The AP value. It is only used if the text cannot be generated from the
37
+ * given information.
38
+ */
39
+ ap_value?: Activatable.AdventurePointsValueReplacement;
31
40
  errata?: Errata;
32
41
  };
33
42
  export declare const validateSchema: import("../../validation/schema.js").TypeValidator<MagicalSpecialAbility>;
@@ -53,7 +53,7 @@ export declare type MagicalTradition = {
53
53
  * @maximum 30
54
54
  * @multipleOf 5
55
55
  */
56
- alternative_magical_adventure_points_maximum: number;
56
+ alternative_magical_adventure_points_maximum?: number;
57
57
  /**
58
58
  * Are advantages/disadvantages required to not exclusively apply to arcane
59
59
  * spellworks, but also to the tradition's magical actions or applications?
@@ -67,7 +67,7 @@ export declare type MagicalTradition = {
67
67
  * If arcane spellworks from a different tradition count as arcane spellworks
68
68
  * of this tradition, this is the different tradition's reference.
69
69
  */
70
- use_arcane_spellworks_from_tradition: MagicalTraditionReference;
70
+ use_arcane_spellworks_from_tradition?: MagicalTraditionReference;
71
71
  /**
72
72
  * The Influences for the traditions. Influences are enabled by Focus Rules.
73
73
  * @minItems 2
@@ -16,6 +16,12 @@ export declare type ProtectiveWardingCircleSpecialAbility = {
16
16
  select_options?: Activatable.SelectOptions;
17
17
  maximum?: Activatable.Maximum;
18
18
  prerequisites?: GeneralPrerequisites;
19
+ /**
20
+ * The cost in AE.
21
+ * @integer
22
+ * @minimum 0
23
+ */
24
+ cost: number;
19
25
  ap_value: Activatable.AdventurePointsValue;
20
26
  src: PublicationRefs;
21
27
  /**
@@ -26,6 +26,11 @@ export declare type SikaryanDrainSpecialAbilityTranslation = {
26
26
  name: Activatable.Name;
27
27
  name_in_library?: Activatable.NameInLibrary;
28
28
  rules: Activatable.Rules;
29
+ /**
30
+ * The AP value. It is only used if the text cannot be generated from the
31
+ * given information.
32
+ */
33
+ ap_value?: Activatable.AdventurePointsValueReplacement;
29
34
  errata?: Errata;
30
35
  };
31
36
  export declare const validateSchema: import("../../validation/schema.js").TypeValidator<SikaryanDrainSpecialAbility>;
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main VampiricGift
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Vampiric Gift
11
11
  */
@@ -26,6 +26,11 @@ export declare type VampiricGiftTranslation = {
26
26
  name: Activatable.Name;
27
27
  name_in_library?: Activatable.NameInLibrary;
28
28
  rules: Activatable.Rules;
29
+ /**
30
+ * The AP value. It is only used if the text cannot be generated from the
31
+ * given information.
32
+ */
33
+ ap_value?: Activatable.AdventurePointsValueReplacement;
29
34
  errata?: Errata;
30
35
  };
31
36
  export declare const validateSchema: import("../../validation/schema.js").TypeValidator<VampiricGift>;
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main ArcaneOrbEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Arcane Orb Enchantment
11
11
  */
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main AttireEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Attire Enchantment
11
11
  */
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main BowlEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Bowl Enchantment
11
11
  */
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main CauldronEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Cauldron Enchantment
11
11
  */
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main ChronicleEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Chronicle Enchantment
11
11
  */
@@ -1,12 +1,12 @@
1
1
  /**
2
2
  * @main DaggerRitual
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { ArcaneEnergyCost, BindingCost } from "../_Activatable.js";
8
6
  import { LocaleMap } from "../_LocaleMap.js";
9
7
  import { GeneralPrerequisites } from "../_Prerequisite.js";
8
+ import { Errata } from "../source/_Erratum.js";
9
+ import { PublicationRefs } from "../source/_PublicationRef.js";
10
10
  /**
11
11
  * @title Dagger Ritual
12
12
  */
@@ -17,7 +17,7 @@ export declare type DaggerRitual = {
17
17
  maximum?: Activatable.Maximum;
18
18
  prerequisites?: GeneralPrerequisites;
19
19
  volume: Activatable.Volume;
20
- cost: DaggerRitualCost;
20
+ cost?: DaggerRitualCost;
21
21
  property: Activatable.Property;
22
22
  ap_value: Activatable.AdventurePointsValue;
23
23
  src: PublicationRefs;
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main FoolsHatEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Fool's Hat Enchantment
11
11
  */
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main InstrumentEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Instrument Enchantment
11
11
  */
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main Krallenkettenzauber
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Krallenkettenzauber
11
11
  */
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main OrbEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Orb Enchantment
11
11
  */
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main RingEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Ring Enchantment
11
11
  */
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main SickleRitual
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Sickle Ritual
11
11
  */
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main SpellSwordEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Spell-Sword Enchantment
11
11
  */
@@ -41,6 +41,11 @@ export declare type SpellSwordEnchantmentTranslation = {
41
41
  * @deprecated
42
42
  */
43
43
  bindingCost?: string;
44
+ /**
45
+ * The AP value. It is only used if the text cannot be generated from the
46
+ * given information.
47
+ */
48
+ ap_value?: Activatable.AdventurePointsValueReplacement;
44
49
  errata?: Errata;
45
50
  };
46
51
  export declare const validateSchema: import("../../validation/schema.js").TypeValidator<SpellSwordEnchantment>;
@@ -1,11 +1,12 @@
1
1
  /**
2
2
  * @main StaffEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { ResponsiveTextOptional } from "../_ResponsiveText.js";
8
+ import { Errata } from "../source/_Erratum.js";
9
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
10
  /**
10
11
  * @title Staff Enchantment
11
12
  */
@@ -16,7 +17,7 @@ export declare type StaffEnchantment = {
16
17
  maximum?: Activatable.Maximum;
17
18
  prerequisites?: GeneralPrerequisites;
18
19
  volume: Activatable.Volume;
19
- cost: Activatable.EnchantmentCost;
20
+ cost?: Activatable.EnchantmentCost;
20
21
  property: Activatable.Property;
21
22
  ap_value: Activatable.AdventurePointsValue;
22
23
  src: PublicationRefs;
@@ -37,10 +38,19 @@ export declare type StaffEnchantmentTranslation = {
37
38
  * @deprecated
38
39
  */
39
40
  aeCost?: string;
41
+ /**
42
+ * A note, appended to the generated cost string in parenthesis.
43
+ */
44
+ cost_note?: ResponsiveTextOptional;
40
45
  /**
41
46
  * @deprecated
42
47
  */
43
48
  bindingCost?: string;
49
+ /**
50
+ * The AP value. It is only used if the text cannot be generated from the
51
+ * given information.
52
+ */
53
+ ap_value?: Activatable.AdventurePointsValueReplacement;
44
54
  errata?: Errata;
45
55
  };
46
56
  export declare const validateSchema: import("../../validation/schema.js").TypeValidator<StaffEnchantment>;
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main ToyEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Toy Enchantment
11
11
  */
@@ -16,7 +16,7 @@ export declare type ToyEnchantment = {
16
16
  maximum?: Activatable.Maximum;
17
17
  prerequisites?: GeneralPrerequisites;
18
18
  volume: Activatable.Volume;
19
- cost: Activatable.EnchantmentCost;
19
+ cost?: Activatable.EnchantmentCost;
20
20
  property: Activatable.Property;
21
21
  ap_value: Activatable.AdventurePointsValue;
22
22
  src: PublicationRefs;
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main Trinkhornzauber
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Trinkhornzauber
11
11
  */
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @main WandEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
7
5
  import { LocaleMap } from "../_LocaleMap.js";
8
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
9
9
  /**
10
10
  * @title Wand Enchantment
11
11
  */
@@ -15,7 +15,6 @@ export declare type WandEnchantment = {
15
15
  select_options?: Activatable.SelectOptions;
16
16
  maximum?: Activatable.Maximum;
17
17
  prerequisites?: GeneralPrerequisites;
18
- volume: Activatable.Volume;
19
18
  cost?: Activatable.EnchantmentCost;
20
19
  property: Activatable.Property;
21
20
  ap_value: Activatable.AdventurePointsValue;
@@ -29,10 +28,6 @@ export declare type WandEnchantmentTranslation = {
29
28
  name: Activatable.Name;
30
29
  name_in_library?: Activatable.NameInLibrary;
31
30
  effect: Activatable.Effect;
32
- /**
33
- * @deprecated
34
- */
35
- volume: string;
36
31
  /**
37
32
  * @deprecated
38
33
  */
@@ -1,10 +1,11 @@
1
1
  /**
2
2
  * @main WeaponEnchantment
3
3
  */
4
- import { Errata } from "../source/_Erratum.js";
5
- import { PublicationRefs } from "../source/_PublicationRef.js";
6
4
  import * as Activatable from "../_Activatable.js";
5
+ import { LocaleMap } from "../_LocaleMap.js";
7
6
  import { GeneralPrerequisites } from "../_Prerequisite.js";
7
+ import { Errata } from "../source/_Erratum.js";
8
+ import { PublicationRefs } from "../source/_PublicationRef.js";
8
9
  /**
9
10
  * @title Weapon Enchantment
10
11
  */
@@ -22,7 +23,7 @@ export declare type WeaponEnchantment = {
22
23
  /**
23
24
  * All translations for the entry, identified by IETF language tag (BCP47).
24
25
  */
25
- translations: WeaponEnchantmentTranslation;
26
+ translations: LocaleMap<WeaponEnchantmentTranslation>;
26
27
  };
27
28
  export declare type WeaponEnchantmentTranslation = {
28
29
  name: Activatable.Name;
@@ -1,12 +1,12 @@
1
1
  import { basename, dirname, extname, join, relative, sep } from "path";
2
2
  import { fileURLToPath } from "url";
3
3
  import { libDir } from "../../config/directories.js";
4
+ const baseNamePattern = /^(?:0|[1-9][0-9]*)_(?:[A-Z][a-zA-Z]*|[1-9][0-9]*)(?:-(?:[a-zA-Z]+|[1-9][0-9]*))*\.yml$/;
4
5
  const fileNameError = (fileName) => ({
5
6
  keyword: "filename",
6
7
  instancePath: "",
7
- message: `the file name "${fileName}" does not match the pattern ^[1-9][0-9]*_[A-Z][a-z]*(?:-[a-zA-Z][a-z]*)\\.yml$`
8
+ message: `the file name "${fileName}" does not match the pattern ${baseNamePattern.source}`
8
9
  });
9
- const baseNamePattern = /^[1-9][0-9]*_[A-Z][a-z]*(?:-[a-zA-Z][a-z]*)*\.yml$/;
10
10
  const changeFileExtension = (path, ext) => join(dirname(path), basename(path, extname(path)) + ext);
11
11
  const schemaIdFromSourcePath = (sourcePath) => {
12
12
  const relativePathOfType = relative(libDir, fileURLToPath(sourcePath));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "optolith-database-schema",
3
- "version": "0.8.1",
3
+ "version": "0.10.0",
4
4
  "description": "Definitions and utilities for the flat-file database of Optolith, a character creation tool for the Pen and Paper RPG “The Dark Eye 5”, and its external integrations into other software.",
5
5
  "keywords": [
6
6
  "tde",
@@ -75,6 +75,10 @@
75
75
  "name_in_library": {
76
76
  "$ref": "./_Activatable.schema.json#/$defs/NameInLibrary"
77
77
  },
78
+ "input": {
79
+ "description": "A string that is used as a label for an input field.",
80
+ "$ref": "./_Activatable.schema.json#/$defs/Input"
81
+ },
78
82
  "rules": {
79
83
  "$ref": "./_Activatable.schema.json#/$defs/Rules"
80
84
  },
@@ -83,6 +87,13 @@
83
87
  "type": "string",
84
88
  "minLength": 1
85
89
  },
90
+ "ap_value": {
91
+ "$ref": "./_Activatable.schema.json#/$defs/AdventurePointsValueReplacement"
92
+ },
93
+ "ap_value_append": {
94
+ "description": "A string that gets appended to the default AP Value text with a preceding\nspace. This always happens if present, even if the generated AP Value text\nis replaced.",
95
+ "$ref": "./_Activatable.schema.json#/$defs/AdventurePointsValueAppend"
96
+ },
86
97
  "errata": {
87
98
  "$ref": "./source/_Erratum.schema.json#/$defs/Errata"
88
99
  }