kaabalah 6.4.3 → 6.5.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/ifa/index.js CHANGED
@@ -1,13 +1,13 @@
1
1
  'use strict';
2
2
 
3
- var chunk3WVZRLPG_js = require('../chunk-3WVZRLPG.js');
3
+ var chunk2WCC2KCJ_js = require('../chunk-2WCC2KCJ.js');
4
4
  require('../chunk-FM7WUVZV.js');
5
5
 
6
6
 
7
7
 
8
8
  Object.defineProperty(exports, "calculateOdu", {
9
9
  enumerable: true,
10
- get: function () { return chunk3WVZRLPG_js.calculateOdu; }
10
+ get: function () { return chunk2WCC2KCJ_js.calculateOdu; }
11
11
  });
12
12
  //# sourceMappingURL=index.js.map
13
13
  //# sourceMappingURL=index.js.map
@@ -1,4 +1,4 @@
1
- export { calculateOdu } from '../chunk-YTZCZRJG.mjs';
1
+ export { calculateOdu } from '../chunk-URDMOQRN.mjs';
2
2
  import '../chunk-WY6NIR2V.mjs';
3
3
  //# sourceMappingURL=index.mjs.map
4
4
  //# sourceMappingURL=index.mjs.map
package/dist/index.d.mts CHANGED
@@ -6,4 +6,4 @@ export { OduNumbers, calculateOdu } from './ifa/index.mjs';
6
6
  export { MASTER_NUMBERS, NumerologyData, NumerologyData as NumerologyModuleTypes, calculateChallenges, calculateCycles, calculateFibonacciCycle, calculateKaabalisticLifePath, calculatePersonalCycles, calculatePersonalMonths, calculatePersonalPeriods, calculatePersonalYear, calculateStraightAcrossReductionLifePath, getDateEnergies, isMasterNumber, reduceToSingle, reduceToSingleWithSteps } from './numerology/index.mjs';
7
7
  export { AstrologyTreeChartInput, BuildKaabalisticMapDataInput, GematriaTreeInput, HouseNumber, HouseThemeAxis, HouseThemeLookup, HouseThemeProfile, HouseThemeScope, KaabalisticAngleCorrespondenceLookup, KaabalisticCorrespondenceLookup, KaabalisticCorrespondenceResult, KaabalisticCorrespondenceSource, KaabalisticCorrespondenceTarget, KaabalisticCountsEntry, KaabalisticHebrewLetterCorrespondenceLookup, KaabalisticItemConnection, KaabalisticMapData, KaabalisticMarkerDescriptor, KaabalisticMarkerKind, KaabalisticMarkerMapping, KaabalisticMarkerSourceType, KaabalisticNodeCorrespondenceLookup, KaabalisticNumberCorrespondenceLookup, KaabalisticPlanetCorrespondenceLookup, KaabalisticSignCorrespondenceLookup, KaabalisticSignLookup, KaabalisticSummaryTarget, KaabalisticSymbolMetadata, KaabalisticTargetId, KaabalisticTargetType, NumerologyTreeInput, OCCULT_THEME_STOPWORDS, OccultThemeCorrespondence, OccultThemeCorrespondences, TarotMajorArchetypeReference, TarotThemeCorrespondences, TarotThemeLookup, TarotThemeProfile, TokenizeOccultThemeTextOptions, buildKaabalisticMapData, getAngleSymbolMetadata, getAstrologyTreeMarkers, getGematriaTreeMarkers, getHouseThemeProfile, getKaabalisticCorrespondenceTargets, getNodeSymbolMetadata, getNumerologyTreeMarkers, getPlanetSymbolMetadata, getTarotThemeProfile, getZodiacSignSymbolMetadata, listAngleSymbolMetadata, listHouseThemeProfiles, listNodeSymbolMetadata, listPlanetSymbolMetadata, listTarotThemeProfiles, listZodiacSignSymbolMetadata, tokenizeOccultThemeText } from './semantic/index.mjs';
8
8
  export { ARKANNUS, DEFAULT_TAROT_TREE_ID, Deck, DrawTarotSpreadOptions, MajorArcana, TAROT_IMAGE_BASE_URL, TAROT_TREE_IDS, TarotArchetype, TarotArchetypeLookup, TarotAssetPathType, TarotAstrologyCorrespondence, TarotAstrologyCorrespondenceType, TarotCard, TarotCardKind, TarotCardProfile, TarotCorrespondenceNode, TarotCorrespondenceNodeType, TarotCorrespondenceProfile, TarotCorrespondenceProfileBase, TarotCourtAstrologyCorrespondenceProfile, TarotCourtRank, TarotDeckDescription, TarotDeckId, TarotDeckMetadata, TarotImageLookup, TarotInquirerGender, TarotMajorCorrespondenceProfile, TarotMinorCorrespondenceProfile, TarotPageCorrespondenceProfile, TarotPathCorrespondence, TarotRepresentation, TarotSpreadCardConstraint, TarotSpreadCardType, TarotSpreadContextKey, TarotSpreadDefinition, TarotSpreadDrawResult, TarotSpreadId, TarotSpreadInquirerRule, TarotSpreadMinorRank, TarotSpreadResolvedSelectionCard, TarotSpreadSelectionCard, TarotSpreadSelectionContext, TarotSpreadSlotDefinition, TarotSpreadSlotMetadata, TarotSpreadValidationErrorCode, TarotSpreadValidationInput, TarotSpreadValidationIssue, TarotSpreadValidationResult, TarotTreeId, drawTarotSpread, getTarotArchetype, getTarotCardByNumber, getTarotCardNumber, getTarotCardProfile, getTarotCorrespondenceProfile, getTarotRepresentation, getTarotRepresentations, getTarotSpread, listTarotDecks, listTarotSpreads, listTarotTrees, majorArcana, resolveTarotImageUrl, shuffleTarotDeck, validateTarotSpreadSelection } from './tarot/index.mjs';
9
- export { TREE_PATH_IDS, TREE_SPHERE_IDS, TREE_SPHERE_NAMES, TREE_SVG_DEFAULT_VIEWBOX, TreeLayout, TreeLayoutCoordinate, TreeLayoutMap, TreeLayoutPath, TreePathId, TreeSphereId, TreeSphereName, TreeSvgCustomPalette, TreeSvgDaathLayer, TreeSvgHighlights, TreeSvgOptions, TreeSvgPalette, TreeSvgViewBox, generateTreeSvg, getTreeLayout } from './visual/index.mjs';
9
+ export { TREE_PATH_IDS, TREE_SPHERE_IDS, TREE_SPHERE_NAMES, TREE_SVG_DEFAULT_VIEWBOX, TreeLayout, TreeLayoutCoordinate, TreeLayoutMap, TreeLayoutPath, TreePathId, TreeRenderActivationState, TreeRenderAnchor, TreeRenderCircleHitTarget, TreeRenderHitTarget, TreeRenderLayer, TreeRenderLineHitTarget, TreeRenderModel, TreeRenderPath, TreeRenderPathGeometry, TreeRenderSphere, TreeRenderSphereGeometry, TreeSphereId, TreeSphereName, TreeSvgCustomPalette, TreeSvgDaathLayer, TreeSvgHighlights, TreeSvgOptions, TreeSvgPalette, TreeSvgViewBox, TreeTargetActivationInput, TreeTargetState, generateTreeSvg, getTreeLayout, getTreeRenderModel } from './visual/index.mjs';
package/dist/index.d.ts CHANGED
@@ -6,4 +6,4 @@ export { OduNumbers, calculateOdu } from './ifa/index.js';
6
6
  export { MASTER_NUMBERS, NumerologyData, NumerologyData as NumerologyModuleTypes, calculateChallenges, calculateCycles, calculateFibonacciCycle, calculateKaabalisticLifePath, calculatePersonalCycles, calculatePersonalMonths, calculatePersonalPeriods, calculatePersonalYear, calculateStraightAcrossReductionLifePath, getDateEnergies, isMasterNumber, reduceToSingle, reduceToSingleWithSteps } from './numerology/index.js';
7
7
  export { AstrologyTreeChartInput, BuildKaabalisticMapDataInput, GematriaTreeInput, HouseNumber, HouseThemeAxis, HouseThemeLookup, HouseThemeProfile, HouseThemeScope, KaabalisticAngleCorrespondenceLookup, KaabalisticCorrespondenceLookup, KaabalisticCorrespondenceResult, KaabalisticCorrespondenceSource, KaabalisticCorrespondenceTarget, KaabalisticCountsEntry, KaabalisticHebrewLetterCorrespondenceLookup, KaabalisticItemConnection, KaabalisticMapData, KaabalisticMarkerDescriptor, KaabalisticMarkerKind, KaabalisticMarkerMapping, KaabalisticMarkerSourceType, KaabalisticNodeCorrespondenceLookup, KaabalisticNumberCorrespondenceLookup, KaabalisticPlanetCorrespondenceLookup, KaabalisticSignCorrespondenceLookup, KaabalisticSignLookup, KaabalisticSummaryTarget, KaabalisticSymbolMetadata, KaabalisticTargetId, KaabalisticTargetType, NumerologyTreeInput, OCCULT_THEME_STOPWORDS, OccultThemeCorrespondence, OccultThemeCorrespondences, TarotMajorArchetypeReference, TarotThemeCorrespondences, TarotThemeLookup, TarotThemeProfile, TokenizeOccultThemeTextOptions, buildKaabalisticMapData, getAngleSymbolMetadata, getAstrologyTreeMarkers, getGematriaTreeMarkers, getHouseThemeProfile, getKaabalisticCorrespondenceTargets, getNodeSymbolMetadata, getNumerologyTreeMarkers, getPlanetSymbolMetadata, getTarotThemeProfile, getZodiacSignSymbolMetadata, listAngleSymbolMetadata, listHouseThemeProfiles, listNodeSymbolMetadata, listPlanetSymbolMetadata, listTarotThemeProfiles, listZodiacSignSymbolMetadata, tokenizeOccultThemeText } from './semantic/index.js';
8
8
  export { ARKANNUS, DEFAULT_TAROT_TREE_ID, Deck, DrawTarotSpreadOptions, MajorArcana, TAROT_IMAGE_BASE_URL, TAROT_TREE_IDS, TarotArchetype, TarotArchetypeLookup, TarotAssetPathType, TarotAstrologyCorrespondence, TarotAstrologyCorrespondenceType, TarotCard, TarotCardKind, TarotCardProfile, TarotCorrespondenceNode, TarotCorrespondenceNodeType, TarotCorrespondenceProfile, TarotCorrespondenceProfileBase, TarotCourtAstrologyCorrespondenceProfile, TarotCourtRank, TarotDeckDescription, TarotDeckId, TarotDeckMetadata, TarotImageLookup, TarotInquirerGender, TarotMajorCorrespondenceProfile, TarotMinorCorrespondenceProfile, TarotPageCorrespondenceProfile, TarotPathCorrespondence, TarotRepresentation, TarotSpreadCardConstraint, TarotSpreadCardType, TarotSpreadContextKey, TarotSpreadDefinition, TarotSpreadDrawResult, TarotSpreadId, TarotSpreadInquirerRule, TarotSpreadMinorRank, TarotSpreadResolvedSelectionCard, TarotSpreadSelectionCard, TarotSpreadSelectionContext, TarotSpreadSlotDefinition, TarotSpreadSlotMetadata, TarotSpreadValidationErrorCode, TarotSpreadValidationInput, TarotSpreadValidationIssue, TarotSpreadValidationResult, TarotTreeId, drawTarotSpread, getTarotArchetype, getTarotCardByNumber, getTarotCardNumber, getTarotCardProfile, getTarotCorrespondenceProfile, getTarotRepresentation, getTarotRepresentations, getTarotSpread, listTarotDecks, listTarotSpreads, listTarotTrees, majorArcana, resolveTarotImageUrl, shuffleTarotDeck, validateTarotSpreadSelection } from './tarot/index.js';
9
- export { TREE_PATH_IDS, TREE_SPHERE_IDS, TREE_SPHERE_NAMES, TREE_SVG_DEFAULT_VIEWBOX, TreeLayout, TreeLayoutCoordinate, TreeLayoutMap, TreeLayoutPath, TreePathId, TreeSphereId, TreeSphereName, TreeSvgCustomPalette, TreeSvgDaathLayer, TreeSvgHighlights, TreeSvgOptions, TreeSvgPalette, TreeSvgViewBox, generateTreeSvg, getTreeLayout } from './visual/index.js';
9
+ export { TREE_PATH_IDS, TREE_SPHERE_IDS, TREE_SPHERE_NAMES, TREE_SVG_DEFAULT_VIEWBOX, TreeLayout, TreeLayoutCoordinate, TreeLayoutMap, TreeLayoutPath, TreePathId, TreeRenderActivationState, TreeRenderAnchor, TreeRenderCircleHitTarget, TreeRenderHitTarget, TreeRenderLayer, TreeRenderLineHitTarget, TreeRenderModel, TreeRenderPath, TreeRenderPathGeometry, TreeRenderSphere, TreeRenderSphereGeometry, TreeSphereId, TreeSphereName, TreeSvgCustomPalette, TreeSvgDaathLayer, TreeSvgHighlights, TreeSvgOptions, TreeSvgPalette, TreeSvgViewBox, TreeTargetActivationInput, TreeTargetState, generateTreeSvg, getTreeLayout, getTreeRenderModel } from './visual/index.js';
package/dist/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
- var chunkEMTVK46M_js = require('./chunk-EMTVK46M.js');
4
- var chunk3WVZRLPG_js = require('./chunk-3WVZRLPG.js');
3
+ var chunkSW5O2BJI_js = require('./chunk-SW5O2BJI.js');
4
+ var chunk2WCC2KCJ_js = require('./chunk-2WCC2KCJ.js');
5
5
  var chunkUG6HZK3Z_js = require('./chunk-UG6HZK3Z.js');
6
6
  var chunk6O7MTBZN_js = require('./chunk-6O7MTBZN.js');
7
7
  var chunkPAKYKIZH_js = require('./chunk-PAKYKIZH.js');
@@ -15,31 +15,35 @@ require('./chunk-FM7WUVZV.js');
15
15
 
16
16
  Object.defineProperty(exports, "TREE_PATH_IDS", {
17
17
  enumerable: true,
18
- get: function () { return chunkEMTVK46M_js.TREE_PATH_IDS; }
18
+ get: function () { return chunkSW5O2BJI_js.TREE_PATH_IDS; }
19
19
  });
20
20
  Object.defineProperty(exports, "TREE_SPHERE_IDS", {
21
21
  enumerable: true,
22
- get: function () { return chunkEMTVK46M_js.TREE_SPHERE_IDS; }
22
+ get: function () { return chunkSW5O2BJI_js.TREE_SPHERE_IDS; }
23
23
  });
24
24
  Object.defineProperty(exports, "TREE_SPHERE_NAMES", {
25
25
  enumerable: true,
26
- get: function () { return chunkEMTVK46M_js.TREE_SPHERE_NAMES; }
26
+ get: function () { return chunkSW5O2BJI_js.TREE_SPHERE_NAMES; }
27
27
  });
28
28
  Object.defineProperty(exports, "TREE_SVG_DEFAULT_VIEWBOX", {
29
29
  enumerable: true,
30
- get: function () { return chunkEMTVK46M_js.TREE_SVG_DEFAULT_VIEWBOX; }
30
+ get: function () { return chunkSW5O2BJI_js.TREE_SVG_DEFAULT_VIEWBOX; }
31
31
  });
32
32
  Object.defineProperty(exports, "generateTreeSvg", {
33
33
  enumerable: true,
34
- get: function () { return chunkEMTVK46M_js.generateTreeSvg; }
34
+ get: function () { return chunkSW5O2BJI_js.generateTreeSvg; }
35
35
  });
36
36
  Object.defineProperty(exports, "getTreeLayout", {
37
37
  enumerable: true,
38
- get: function () { return chunkEMTVK46M_js.getTreeLayout; }
38
+ get: function () { return chunkSW5O2BJI_js.getTreeLayout; }
39
+ });
40
+ Object.defineProperty(exports, "getTreeRenderModel", {
41
+ enumerable: true,
42
+ get: function () { return chunkSW5O2BJI_js.getTreeRenderModel; }
39
43
  });
40
44
  Object.defineProperty(exports, "calculateOdu", {
41
45
  enumerable: true,
42
- get: function () { return chunk3WVZRLPG_js.calculateOdu; }
46
+ get: function () { return chunk2WCC2KCJ_js.calculateOdu; }
43
47
  });
44
48
  Object.defineProperty(exports, "OCCULT_THEME_STOPWORDS", {
45
49
  enumerable: true,
package/dist/index.mjs CHANGED
@@ -1,5 +1,5 @@
1
- export { TREE_PATH_IDS, TREE_SPHERE_IDS, TREE_SPHERE_NAMES, TREE_SVG_DEFAULT_VIEWBOX, generateTreeSvg, getTreeLayout } from './chunk-EVH4J5E2.mjs';
2
- export { calculateOdu } from './chunk-YTZCZRJG.mjs';
1
+ export { TREE_PATH_IDS, TREE_SPHERE_IDS, TREE_SPHERE_NAMES, TREE_SVG_DEFAULT_VIEWBOX, generateTreeSvg, getTreeLayout, getTreeRenderModel } from './chunk-BKNWKD32.mjs';
2
+ export { calculateOdu } from './chunk-URDMOQRN.mjs';
3
3
  export { OCCULT_THEME_STOPWORDS, buildKaabalisticMapData, getAngleSymbolMetadata, getAstrologyTreeMarkers, getGematriaTreeMarkers, getHouseThemeProfile, getKaabalisticCorrespondenceTargets, getNodeSymbolMetadata, getNumerologyTreeMarkers, getPlanetSymbolMetadata, getTarotThemeProfile, getZodiacSignSymbolMetadata, listAngleSymbolMetadata, listHouseThemeProfiles, listNodeSymbolMetadata, listPlanetSymbolMetadata, listTarotThemeProfiles, listZodiacSignSymbolMetadata, tokenizeOccultThemeText } from './chunk-UN7QMOMX.mjs';
4
4
  export { ASTROCARTOGRAPHY_DEFAULT_PLANETS, CalcFlag, DEFAULT_ASPECT_SPECS, DOMICILE_RULERS, EXALTATIONS, HouseSystem, PLANET_AND_NODE_NAMES, Planet, RiseTransitFlag, SIGNS, SLOW_PLANETS, VirtualNodes, closeSwissEph, computeAspects, computeAstrocartographyMap, computeEquatorialPositions, computeGMST, computeHorizonLongitude, computeICLongitude, computeMCLongitude, computeMidpoints, computeSynastryAspects, computeTransitAspects, findHouseOf, findParansAtLatitude, formatDegreeMinutes, geographicAngularDifference, getAnnualProfection, getAspectMatch, getBirthChart, getCompositeChart, getDecan, getDetriment, getDodecatemoria, getDomicileRuler, getEssentialDignity, getExaltation, getFall, getFirdaria, getMonthlyProfections, getOppositeSign, getSolarReturnChart, getSwissEph, getSynastryChart, getTransitChart, getTransitRange, getZodiacPosition, normalizeAngle, queryAstrocartographyLocation, resolveSwissEphRuntimeAssets, shorterArcMidpoint } from './chunk-PWYOHULD.mjs';
5
5
  export { MASTER_NUMBERS, data_exports as NumerologyData, calculateChallenges, calculateCycles, calculateFibonacciCycle, calculateKaabalisticLifePath, calculatePersonalCycles, calculatePersonalMonths, calculatePersonalPeriods, calculatePersonalYear, calculateStraightAcrossReductionLifePath, getDateEnergies, isMasterNumber, reduceToSingle, reduceToSingleWithSteps } from './chunk-6P2CJUTH.mjs';
@@ -10,6 +10,7 @@ interface TreeLayoutCoordinate {
10
10
  x: number;
11
11
  y: number;
12
12
  }
13
+ type TreeTargetState = "active" | "hovered" | "selected" | "inactive";
13
14
  type TreeSphereName = "Kether" | "Chokhmah" | "Binah" | "Daath" | "Chesed" | "Geburah" | "Tiphareth" | "Netzach" | "Hod" | "Yesod" | "Malkuth";
14
15
  type TreeSphereId = NodeId<KaabalahTypes.SPHERE>;
15
16
  type TreePathId = NodeId<KaabalahTypes.PATH>;
@@ -50,6 +51,118 @@ interface TreeSvgHighlights {
50
51
  spheres?: Partial<Record<TreeSphereId, string | string[]>>;
51
52
  specialSphereMode?: "preserve" | "plain";
52
53
  }
54
+ interface TreeTargetActivationInput {
55
+ targetId: TreeSphereId | TreePathId;
56
+ targetType: "sphere" | "path";
57
+ count: number;
58
+ total: number;
59
+ strength?: number;
60
+ state?: TreeTargetState;
61
+ color?: string;
62
+ }
63
+ interface TreeRenderAnchor {
64
+ x: number;
65
+ y: number;
66
+ vertical: "above" | "below";
67
+ }
68
+ interface TreeRenderCircleHitTarget {
69
+ kind: "circle";
70
+ cx: number;
71
+ cy: number;
72
+ r: number;
73
+ }
74
+ interface TreeRenderLineHitTarget {
75
+ kind: "line";
76
+ x1: number;
77
+ y1: number;
78
+ x2: number;
79
+ y2: number;
80
+ strokeWidth: number;
81
+ }
82
+ type TreeRenderHitTarget = TreeRenderCircleHitTarget | TreeRenderLineHitTarget;
83
+ interface TreeRenderActivationState {
84
+ state: TreeTargetState;
85
+ count: number;
86
+ total: number;
87
+ strength: number;
88
+ canonicalColor: string;
89
+ displayColor: string;
90
+ colorOverride?: string;
91
+ mutedColor: string;
92
+ visible: boolean;
93
+ emphasis: number;
94
+ }
95
+ interface TreeRenderSphereGeometry {
96
+ percentages: {
97
+ center: TreeLayoutCoordinate;
98
+ anchor: TreeRenderAnchor;
99
+ };
100
+ viewBoxUnits: {
101
+ center: TreeLayoutCoordinate;
102
+ anchor: TreeRenderAnchor;
103
+ hitTarget: TreeRenderCircleHitTarget;
104
+ };
105
+ radius: {
106
+ viewBoxUnits: number;
107
+ };
108
+ }
109
+ interface TreeRenderPathGeometry {
110
+ percentages: {
111
+ from: TreeLayoutCoordinate;
112
+ to: TreeLayoutCoordinate;
113
+ anchor: TreeRenderAnchor;
114
+ };
115
+ viewBoxUnits: {
116
+ from: TreeLayoutCoordinate;
117
+ to: TreeLayoutCoordinate;
118
+ anchor: TreeRenderAnchor;
119
+ hitTarget: TreeRenderLineHitTarget;
120
+ };
121
+ widths: {
122
+ edge: number;
123
+ main: number;
124
+ highlight: number;
125
+ hitTarget: number;
126
+ };
127
+ }
128
+ interface TreeRenderSphere {
129
+ id: TreeSphereId;
130
+ name: TreeSphereName;
131
+ slug: string;
132
+ canonicalColor: string;
133
+ displayFill: string | string[];
134
+ geometry: TreeRenderSphereGeometry;
135
+ material: {
136
+ kind: "standard" | "special";
137
+ specialSphereName?: Extract<TreeSphereName, "Kether" | "Chokhmah" | "Daath" | "Malkuth">;
138
+ preserveOnActivation: boolean;
139
+ };
140
+ activation: TreeRenderActivationState | null;
141
+ }
142
+ interface TreeRenderPath {
143
+ id: TreePathId;
144
+ geometry: TreeRenderPathGeometry;
145
+ canonicalColor: string;
146
+ displayColor: string;
147
+ activation: TreeRenderActivationState | null;
148
+ }
149
+ interface TreeRenderLayer {
150
+ name: "background" | "paths" | "spheres-behind-paths" | "spheres" | "hit-targets";
151
+ order: number;
152
+ description: string;
153
+ }
154
+ interface TreeRenderModel {
155
+ system: SystemKey;
156
+ viewBox: Required<TreeSvgViewBox>;
157
+ scale: number;
158
+ layout: TreeLayout;
159
+ layerOrder: readonly TreeRenderLayer["name"][];
160
+ layers: readonly TreeRenderLayer[];
161
+ spheres: readonly TreeRenderSphere[];
162
+ paths: readonly TreeRenderPath[];
163
+ sphereById: Record<TreeSphereId, TreeRenderSphere>;
164
+ pathById: Record<TreePathId, TreeRenderPath>;
165
+ }
53
166
  interface TreeSvgOptions {
54
167
  width?: number | string;
55
168
  height?: number | string;
@@ -59,12 +172,14 @@ interface TreeSvgOptions {
59
172
  system?: SystemKey;
60
173
  daathLayer?: TreeSvgDaathLayer;
61
174
  highlights?: TreeSvgHighlights;
175
+ activations?: readonly TreeTargetActivationInput[];
62
176
  }
63
177
  declare const TREE_SVG_DEFAULT_VIEWBOX: Required<TreeSvgViewBox>;
64
178
  declare const TREE_SPHERE_NAMES: readonly ["Kether", "Chokhmah", "Binah", "Daath", "Chesed", "Geburah", "Tiphareth", "Netzach", "Hod", "Yesod", "Malkuth"];
65
179
  declare const TREE_SPHERE_IDS: TreeSphereId[];
66
180
  declare const TREE_PATH_IDS: TreePathId[];
67
181
  declare function getTreeLayout(system?: SystemKey): TreeLayout;
182
+ declare function getTreeRenderModel(options?: TreeSvgOptions): TreeRenderModel;
68
183
  declare function generateTreeSvg(options?: TreeSvgOptions): string;
69
184
 
70
- export { TREE_PATH_IDS, TREE_SPHERE_IDS, TREE_SPHERE_NAMES, TREE_SVG_DEFAULT_VIEWBOX, type TreeLayout, type TreeLayoutCoordinate, type TreeLayoutMap, type TreeLayoutPath, type TreePathId, type TreeSphereId, type TreeSphereName, type TreeSvgCustomPalette, type TreeSvgDaathLayer, type TreeSvgHighlights, type TreeSvgOptions, type TreeSvgPalette, type TreeSvgViewBox, generateTreeSvg, getTreeLayout };
185
+ export { TREE_PATH_IDS, TREE_SPHERE_IDS, TREE_SPHERE_NAMES, TREE_SVG_DEFAULT_VIEWBOX, type TreeLayout, type TreeLayoutCoordinate, type TreeLayoutMap, type TreeLayoutPath, type TreePathId, type TreeRenderActivationState, type TreeRenderAnchor, type TreeRenderCircleHitTarget, type TreeRenderHitTarget, type TreeRenderLayer, type TreeRenderLineHitTarget, type TreeRenderModel, type TreeRenderPath, type TreeRenderPathGeometry, type TreeRenderSphere, type TreeRenderSphereGeometry, type TreeSphereId, type TreeSphereName, type TreeSvgCustomPalette, type TreeSvgDaathLayer, type TreeSvgHighlights, type TreeSvgOptions, type TreeSvgPalette, type TreeSvgViewBox, type TreeTargetActivationInput, type TreeTargetState, generateTreeSvg, getTreeLayout, getTreeRenderModel };
@@ -10,6 +10,7 @@ interface TreeLayoutCoordinate {
10
10
  x: number;
11
11
  y: number;
12
12
  }
13
+ type TreeTargetState = "active" | "hovered" | "selected" | "inactive";
13
14
  type TreeSphereName = "Kether" | "Chokhmah" | "Binah" | "Daath" | "Chesed" | "Geburah" | "Tiphareth" | "Netzach" | "Hod" | "Yesod" | "Malkuth";
14
15
  type TreeSphereId = NodeId<KaabalahTypes.SPHERE>;
15
16
  type TreePathId = NodeId<KaabalahTypes.PATH>;
@@ -50,6 +51,118 @@ interface TreeSvgHighlights {
50
51
  spheres?: Partial<Record<TreeSphereId, string | string[]>>;
51
52
  specialSphereMode?: "preserve" | "plain";
52
53
  }
54
+ interface TreeTargetActivationInput {
55
+ targetId: TreeSphereId | TreePathId;
56
+ targetType: "sphere" | "path";
57
+ count: number;
58
+ total: number;
59
+ strength?: number;
60
+ state?: TreeTargetState;
61
+ color?: string;
62
+ }
63
+ interface TreeRenderAnchor {
64
+ x: number;
65
+ y: number;
66
+ vertical: "above" | "below";
67
+ }
68
+ interface TreeRenderCircleHitTarget {
69
+ kind: "circle";
70
+ cx: number;
71
+ cy: number;
72
+ r: number;
73
+ }
74
+ interface TreeRenderLineHitTarget {
75
+ kind: "line";
76
+ x1: number;
77
+ y1: number;
78
+ x2: number;
79
+ y2: number;
80
+ strokeWidth: number;
81
+ }
82
+ type TreeRenderHitTarget = TreeRenderCircleHitTarget | TreeRenderLineHitTarget;
83
+ interface TreeRenderActivationState {
84
+ state: TreeTargetState;
85
+ count: number;
86
+ total: number;
87
+ strength: number;
88
+ canonicalColor: string;
89
+ displayColor: string;
90
+ colorOverride?: string;
91
+ mutedColor: string;
92
+ visible: boolean;
93
+ emphasis: number;
94
+ }
95
+ interface TreeRenderSphereGeometry {
96
+ percentages: {
97
+ center: TreeLayoutCoordinate;
98
+ anchor: TreeRenderAnchor;
99
+ };
100
+ viewBoxUnits: {
101
+ center: TreeLayoutCoordinate;
102
+ anchor: TreeRenderAnchor;
103
+ hitTarget: TreeRenderCircleHitTarget;
104
+ };
105
+ radius: {
106
+ viewBoxUnits: number;
107
+ };
108
+ }
109
+ interface TreeRenderPathGeometry {
110
+ percentages: {
111
+ from: TreeLayoutCoordinate;
112
+ to: TreeLayoutCoordinate;
113
+ anchor: TreeRenderAnchor;
114
+ };
115
+ viewBoxUnits: {
116
+ from: TreeLayoutCoordinate;
117
+ to: TreeLayoutCoordinate;
118
+ anchor: TreeRenderAnchor;
119
+ hitTarget: TreeRenderLineHitTarget;
120
+ };
121
+ widths: {
122
+ edge: number;
123
+ main: number;
124
+ highlight: number;
125
+ hitTarget: number;
126
+ };
127
+ }
128
+ interface TreeRenderSphere {
129
+ id: TreeSphereId;
130
+ name: TreeSphereName;
131
+ slug: string;
132
+ canonicalColor: string;
133
+ displayFill: string | string[];
134
+ geometry: TreeRenderSphereGeometry;
135
+ material: {
136
+ kind: "standard" | "special";
137
+ specialSphereName?: Extract<TreeSphereName, "Kether" | "Chokhmah" | "Daath" | "Malkuth">;
138
+ preserveOnActivation: boolean;
139
+ };
140
+ activation: TreeRenderActivationState | null;
141
+ }
142
+ interface TreeRenderPath {
143
+ id: TreePathId;
144
+ geometry: TreeRenderPathGeometry;
145
+ canonicalColor: string;
146
+ displayColor: string;
147
+ activation: TreeRenderActivationState | null;
148
+ }
149
+ interface TreeRenderLayer {
150
+ name: "background" | "paths" | "spheres-behind-paths" | "spheres" | "hit-targets";
151
+ order: number;
152
+ description: string;
153
+ }
154
+ interface TreeRenderModel {
155
+ system: SystemKey;
156
+ viewBox: Required<TreeSvgViewBox>;
157
+ scale: number;
158
+ layout: TreeLayout;
159
+ layerOrder: readonly TreeRenderLayer["name"][];
160
+ layers: readonly TreeRenderLayer[];
161
+ spheres: readonly TreeRenderSphere[];
162
+ paths: readonly TreeRenderPath[];
163
+ sphereById: Record<TreeSphereId, TreeRenderSphere>;
164
+ pathById: Record<TreePathId, TreeRenderPath>;
165
+ }
53
166
  interface TreeSvgOptions {
54
167
  width?: number | string;
55
168
  height?: number | string;
@@ -59,12 +172,14 @@ interface TreeSvgOptions {
59
172
  system?: SystemKey;
60
173
  daathLayer?: TreeSvgDaathLayer;
61
174
  highlights?: TreeSvgHighlights;
175
+ activations?: readonly TreeTargetActivationInput[];
62
176
  }
63
177
  declare const TREE_SVG_DEFAULT_VIEWBOX: Required<TreeSvgViewBox>;
64
178
  declare const TREE_SPHERE_NAMES: readonly ["Kether", "Chokhmah", "Binah", "Daath", "Chesed", "Geburah", "Tiphareth", "Netzach", "Hod", "Yesod", "Malkuth"];
65
179
  declare const TREE_SPHERE_IDS: TreeSphereId[];
66
180
  declare const TREE_PATH_IDS: TreePathId[];
67
181
  declare function getTreeLayout(system?: SystemKey): TreeLayout;
182
+ declare function getTreeRenderModel(options?: TreeSvgOptions): TreeRenderModel;
68
183
  declare function generateTreeSvg(options?: TreeSvgOptions): string;
69
184
 
70
- export { TREE_PATH_IDS, TREE_SPHERE_IDS, TREE_SPHERE_NAMES, TREE_SVG_DEFAULT_VIEWBOX, type TreeLayout, type TreeLayoutCoordinate, type TreeLayoutMap, type TreeLayoutPath, type TreePathId, type TreeSphereId, type TreeSphereName, type TreeSvgCustomPalette, type TreeSvgDaathLayer, type TreeSvgHighlights, type TreeSvgOptions, type TreeSvgPalette, type TreeSvgViewBox, generateTreeSvg, getTreeLayout };
185
+ export { TREE_PATH_IDS, TREE_SPHERE_IDS, TREE_SPHERE_NAMES, TREE_SVG_DEFAULT_VIEWBOX, type TreeLayout, type TreeLayoutCoordinate, type TreeLayoutMap, type TreeLayoutPath, type TreePathId, type TreeRenderActivationState, type TreeRenderAnchor, type TreeRenderCircleHitTarget, type TreeRenderHitTarget, type TreeRenderLayer, type TreeRenderLineHitTarget, type TreeRenderModel, type TreeRenderPath, type TreeRenderPathGeometry, type TreeRenderSphere, type TreeRenderSphereGeometry, type TreeSphereId, type TreeSphereName, type TreeSvgCustomPalette, type TreeSvgDaathLayer, type TreeSvgHighlights, type TreeSvgOptions, type TreeSvgPalette, type TreeSvgViewBox, type TreeTargetActivationInput, type TreeTargetState, generateTreeSvg, getTreeLayout, getTreeRenderModel };
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var chunkEMTVK46M_js = require('../chunk-EMTVK46M.js');
3
+ var chunkSW5O2BJI_js = require('../chunk-SW5O2BJI.js');
4
4
  require('../chunk-OKZUVGA3.js');
5
5
  require('../chunk-S6KNERP7.js');
6
6
  require('../chunk-FM7WUVZV.js');
@@ -9,27 +9,31 @@ require('../chunk-FM7WUVZV.js');
9
9
 
10
10
  Object.defineProperty(exports, "TREE_PATH_IDS", {
11
11
  enumerable: true,
12
- get: function () { return chunkEMTVK46M_js.TREE_PATH_IDS; }
12
+ get: function () { return chunkSW5O2BJI_js.TREE_PATH_IDS; }
13
13
  });
14
14
  Object.defineProperty(exports, "TREE_SPHERE_IDS", {
15
15
  enumerable: true,
16
- get: function () { return chunkEMTVK46M_js.TREE_SPHERE_IDS; }
16
+ get: function () { return chunkSW5O2BJI_js.TREE_SPHERE_IDS; }
17
17
  });
18
18
  Object.defineProperty(exports, "TREE_SPHERE_NAMES", {
19
19
  enumerable: true,
20
- get: function () { return chunkEMTVK46M_js.TREE_SPHERE_NAMES; }
20
+ get: function () { return chunkSW5O2BJI_js.TREE_SPHERE_NAMES; }
21
21
  });
22
22
  Object.defineProperty(exports, "TREE_SVG_DEFAULT_VIEWBOX", {
23
23
  enumerable: true,
24
- get: function () { return chunkEMTVK46M_js.TREE_SVG_DEFAULT_VIEWBOX; }
24
+ get: function () { return chunkSW5O2BJI_js.TREE_SVG_DEFAULT_VIEWBOX; }
25
25
  });
26
26
  Object.defineProperty(exports, "generateTreeSvg", {
27
27
  enumerable: true,
28
- get: function () { return chunkEMTVK46M_js.generateTreeSvg; }
28
+ get: function () { return chunkSW5O2BJI_js.generateTreeSvg; }
29
29
  });
30
30
  Object.defineProperty(exports, "getTreeLayout", {
31
31
  enumerable: true,
32
- get: function () { return chunkEMTVK46M_js.getTreeLayout; }
32
+ get: function () { return chunkSW5O2BJI_js.getTreeLayout; }
33
+ });
34
+ Object.defineProperty(exports, "getTreeRenderModel", {
35
+ enumerable: true,
36
+ get: function () { return chunkSW5O2BJI_js.getTreeRenderModel; }
33
37
  });
34
38
  //# sourceMappingURL=index.js.map
35
39
  //# sourceMappingURL=index.js.map
@@ -1,4 +1,4 @@
1
- export { TREE_PATH_IDS, TREE_SPHERE_IDS, TREE_SPHERE_NAMES, TREE_SVG_DEFAULT_VIEWBOX, generateTreeSvg, getTreeLayout } from '../chunk-EVH4J5E2.mjs';
1
+ export { TREE_PATH_IDS, TREE_SPHERE_IDS, TREE_SPHERE_NAMES, TREE_SVG_DEFAULT_VIEWBOX, generateTreeSvg, getTreeLayout, getTreeRenderModel } from '../chunk-BKNWKD32.mjs';
2
2
  import '../chunk-ZKIJAZ6B.mjs';
3
3
  import '../chunk-EFZUZI22.mjs';
4
4
  import '../chunk-WY6NIR2V.mjs';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kaabalah",
3
- "version": "6.4.3",
3
+ "version": "6.5.0",
4
4
  "description": "The de-facto library for any esoteric calculations and tooling",
5
5
  "engines": {
6
6
  "node": ">=18.18.0"
@@ -1,52 +0,0 @@
1
- 'use strict';
2
-
3
- // src/ifa/index.ts
4
- function calculateOdu(date) {
5
- const day = date.getDate().toString().padStart(2, "0");
6
- const month = (date.getMonth() + 1).toString().padStart(2, "0");
7
- const year = date.getFullYear().toString();
8
- const leftNumbers = [
9
- parseInt(day[0]),
10
- // First digit of day
11
- parseInt(month[0]),
12
- // First digit of month
13
- parseInt(year[0]),
14
- // First digit of year
15
- parseInt(year[2])
16
- // Third digit of year
17
- ];
18
- const rightNumbers = [
19
- parseInt(day[1]),
20
- // Second digit of day
21
- parseInt(month[1]),
22
- // Second digit of month
23
- parseInt(year[1]),
24
- // Second digit of year
25
- parseInt(year[3])
26
- // Fourth digit of year
27
- ];
28
- function reduceNumber(num) {
29
- if (num <= 16) return num;
30
- return reduceNumber(num.toString().split("").reduce((a, b) => a + parseInt(b), 0));
31
- }
32
- const rawLeftSum = leftNumbers.reduce((a, b) => a + b, 0);
33
- const rawRightSum = rightNumbers.reduce((a, b) => a + b, 0);
34
- const north = reduceNumber(rawLeftSum);
35
- const south = reduceNumber(rawRightSum);
36
- const east = reduceNumber(north + south);
37
- const west = reduceNumber(north + south + east);
38
- const center = reduceNumber(north + south + east + west);
39
- return {
40
- leftNumbers,
41
- rightNumbers,
42
- north,
43
- south,
44
- east,
45
- west,
46
- center
47
- };
48
- }
49
-
50
- exports.calculateOdu = calculateOdu;
51
- //# sourceMappingURL=chunk-3WVZRLPG.js.map
52
- //# sourceMappingURL=chunk-3WVZRLPG.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/ifa/index.ts"],"names":[],"mappings":";;;AAgBO,SAAS,aAAa,IAAwB,EAAA;AAEnD,EAAM,MAAA,GAAA,GAAM,KAAK,OAAQ,EAAA,CAAE,UAAW,CAAA,QAAA,CAAS,GAAG,GAAG,CAAA;AACrD,EAAM,MAAA,KAAA,GAAA,CAAS,KAAK,QAAS,EAAA,GAAI,GAAG,QAAS,EAAA,CAAE,QAAS,CAAA,CAAA,EAAG,GAAG,CAAA;AAC9D,EAAA,MAAM,IAAO,GAAA,IAAA,CAAK,WAAY,EAAA,CAAE,QAAS,EAAA;AAGzC,EAAA,MAAM,WAAc,GAAA;AAAA,IAClB,QAAA,CAAS,GAAI,CAAA,CAAC,CAAC,CAAA;AAAA;AAAA,IACf,QAAA,CAAS,KAAM,CAAA,CAAC,CAAC,CAAA;AAAA;AAAA,IACjB,QAAA,CAAS,IAAK,CAAA,CAAC,CAAC,CAAA;AAAA;AAAA,IAChB,QAAA,CAAS,IAAK,CAAA,CAAC,CAAC;AAAA;AAAA,GAClB;AAEA,EAAA,MAAM,YAAe,GAAA;AAAA,IACnB,QAAA,CAAS,GAAI,CAAA,CAAC,CAAC,CAAA;AAAA;AAAA,IACf,QAAA,CAAS,KAAM,CAAA,CAAC,CAAC,CAAA;AAAA;AAAA,IACjB,QAAA,CAAS,IAAK,CAAA,CAAC,CAAC,CAAA;AAAA;AAAA,IAChB,QAAA,CAAS,IAAK,CAAA,CAAC,CAAC;AAAA;AAAA,GAClB;AAGA,EAAA,SAAS,aAAa,GAAqB,EAAA;AACzC,IAAI,IAAA,GAAA,IAAO,IAAW,OAAA,GAAA;AACtB,IAAA,OAAO,aAAa,GAAI,CAAA,QAAA,EAAW,CAAA,KAAA,CAAM,EAAE,CAAE,CAAA,MAAA,CAAO,CAAC,CAAA,EAAG,MAAM,CAAI,GAAA,QAAA,CAAS,CAAC,CAAA,EAAG,CAAC,CAAC,CAAA;AAAA;AAInF,EAAM,MAAA,UAAA,GAAa,YAAY,MAAO,CAAA,CAAC,GAAG,CAAM,KAAA,CAAA,GAAI,GAAG,CAAC,CAAA;AACxD,EAAM,MAAA,WAAA,GAAc,aAAa,MAAO,CAAA,CAAC,GAAG,CAAM,KAAA,CAAA,GAAI,GAAG,CAAC,CAAA;AAG1D,EAAM,MAAA,KAAA,GAAQ,aAAa,UAAU,CAAA;AACrC,EAAM,MAAA,KAAA,GAAQ,aAAa,WAAW,CAAA;AACtC,EAAM,MAAA,IAAA,GAAO,YAAa,CAAA,KAAA,GAAQ,KAAK,CAAA;AACvC,EAAA,MAAM,IAAO,GAAA,YAAA,CAAa,KAAQ,GAAA,KAAA,GAAQ,IAAI,CAAA;AAC9C,EAAA,MAAM,MAAS,GAAA,YAAA,CAAa,KAAQ,GAAA,KAAA,GAAQ,OAAO,IAAI,CAAA;AAEvD,EAAO,OAAA;AAAA,IACL,WAAA;AAAA,IACA,YAAA;AAAA,IACA,KAAA;AAAA,IACA,KAAA;AAAA,IACA,IAAA;AAAA,IACA,IAAA;AAAA,IACA;AAAA,GACF;AACF","file":"chunk-3WVZRLPG.js","sourcesContent":["\nexport type OduNumbers = {\n leftNumbers: number[],\n rightNumbers: number[],\n north: number,\n south: number,\n east: number,\n west: number,\n center: number\n}\n\n/**\n * Calculate the Odu numbers based on a date\n * @param date - Date object\n * @returns Odu numbers\n */\nexport function calculateOdu(date: Date): OduNumbers {\n // Format the date into DD/MM/YYYY\n const day = date.getDate().toString().padStart(2, '0');\n const month = (date.getMonth() + 1).toString().padStart(2, '0');\n const year = date.getFullYear().toString();\n\n // Split into left and right columns\n const leftNumbers = [\n parseInt(day[0]), // First digit of day\n parseInt(month[0]), // First digit of month\n parseInt(year[0]), // First digit of year\n parseInt(year[2]) // Third digit of year\n ];\n\n const rightNumbers = [\n parseInt(day[1]), // Second digit of day\n parseInt(month[1]), // Second digit of month\n parseInt(year[1]), // Second digit of year\n parseInt(year[3]) // Fourth digit of year\n ];\n\n // Reduce numbers if they're greater than 16\n function reduceNumber(num: number): number {\n if (num <= 16) return num;\n return reduceNumber(num.toString().split('').reduce((a, b) => a + parseInt(b), 0));\n }\n\n // Calculate initial sums\n const rawLeftSum = leftNumbers.reduce((a, b) => a + b, 0);\n const rawRightSum = rightNumbers.reduce((a, b) => a + b, 0);\n\n // Calculate and reduce each direction\n const north = reduceNumber(rawLeftSum);\n const south = reduceNumber(rawRightSum);\n const east = reduceNumber(north + south);\n const west = reduceNumber(north + south + east);\n const center = reduceNumber(north + south + east + west);\n\n return {\n leftNumbers,\n rightNumbers,\n north,\n south,\n east,\n west,\n center\n };\n}"]}