guanwei 1.1.2 → 1.1.3

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 (53) hide show
  1. package/README.en.md +5 -2
  2. package/README.md +6 -3
  3. package/dist/assets/index-C3wrtpPY.css +1 -0
  4. package/dist/assets/{index-C7ql6zvs.js → index-CAyAIgw8.js} +25 -25
  5. package/dist/assets/index-CAyAIgw8.js.map +1 -0
  6. package/dist/index.html +2 -2
  7. package/package.json +2 -2
  8. package/server/src/data/db.json +147 -0
  9. package/server/src/index.ts +27 -4
  10. package/server/src/routes/tarot.ts +4 -4
  11. package/server/src/routes/users.ts +42 -7
  12. package/server/src/services/divineStore.ts +1 -5
  13. package/server/src/services/promptBuilder.ts +2 -2
  14. package/server/src/types/index.ts +2 -104
  15. package/{src → shared/core}/data/lifeContext.ts +2 -8
  16. package/{src → shared/core}/data/spreads.ts +1 -1
  17. package/{src → shared/core}/data/tarotCards.ts +1 -1
  18. package/shared/core/engine/bazi.ts +0 -1
  19. package/shared/core/engine/calendar.ts +1 -1
  20. package/{server/src/utils → shared/core/engine}/semanticAnalyzer.ts +9 -46
  21. package/{server/src/utils → shared/core/engine}/tarotEngine.ts +6 -6
  22. package/shared/core/engine/ziwei.ts +3 -2
  23. package/shared/core/engine/ziweiInterpret.ts +0 -3
  24. package/shared/core/types.ts +157 -0
  25. package/src/arts/registry.ts +1 -1
  26. package/src/components/QuestionFields.tsx +0 -1
  27. package/src/components/ReportView.tsx +0 -1
  28. package/src/components/TimeShichenInput.tsx +1 -0
  29. package/src/components/arts/BaziArt.tsx +0 -10
  30. package/src/components/arts/LiurenArt.tsx +1 -1
  31. package/src/components/arts/LiuyaoArt.tsx +0 -1
  32. package/src/components/arts/MeihuaArt.tsx +0 -1
  33. package/src/components/arts/QimenArt.tsx +0 -1
  34. package/src/components/arts/TarotArt.tsx +2 -2
  35. package/src/components/arts/XiaoliurenArt.tsx +1 -2
  36. package/src/components/arts/ZiweiArt.tsx +2 -15
  37. package/src/pages/AuthPage.tsx +4 -6
  38. package/src/pages/DemoPage.tsx +1 -2
  39. package/src/pages/HistoryPage.tsx +10 -9
  40. package/src/pages/ModulePage.tsx +6 -32
  41. package/src/pages/SpreadLibrary.tsx +1 -1
  42. package/src/pages/TarotPage.tsx +7 -9
  43. package/src/services/api.ts +4 -4
  44. package/src/stores/useDivinationStore.ts +1 -1
  45. package/src/types/index.ts +2 -104
  46. package/tsconfig.json +5 -5
  47. package/dist/assets/index-C7ql6zvs.js.map +0 -1
  48. package/dist/assets/index-DQx62TUr.css +0 -1
  49. package/server/src/data/lifeContext.ts +0 -423
  50. package/server/src/data/spreads.ts +0 -255
  51. package/server/src/data/tarotCards.ts +0 -2353
  52. package/src/utils/semanticAnalyzer.ts +0 -555
  53. package/src/utils/tarotEngine.ts +0 -849
@@ -1,104 +1,2 @@
1
- export interface TarotCard {
2
- id: number;
3
- name: string;
4
- nameEn: string;
5
- arcana: 'major' | 'minor';
6
- suit?: 'wands' | 'cups' | 'swords' | 'pentacles';
7
- number?: number;
8
- keywords: string[];
9
- meanings: {
10
- upright: string;
11
- reversed: string;
12
- };
13
- deepMeaning: {
14
- coreTheme: string;
15
- psychological: string;
16
- spiritual: string;
17
- shadow: string;
18
- lifeAreas: {
19
- love: string;
20
- career: string;
21
- wealth: string;
22
- health: string;
23
- growth: string;
24
- };
25
- advice: string;
26
- warning: string;
27
- };
28
- imageSymbols: string[];
29
- story: string;
30
- astrology: {
31
- zodiac?: string;
32
- planet?: string;
33
- element?: string;
34
- };
35
- kabbalah: {
36
- path?: number;
37
- sephirah?: string;
38
- };
39
- alchemy: {
40
- stage?: string;
41
- element?: string;
42
- };
43
- numerology: {
44
- number: number;
45
- meaning: string;
46
- };
47
- image: string;
48
- }
49
-
50
- export interface SpreadPosition {
51
- id: number;
52
- name: string;
53
- description: string;
54
- x: number;
55
- y: number;
56
- }
57
-
58
- export interface Spread {
59
- id: string;
60
- name: string;
61
- description: string;
62
- positions: SpreadPosition[];
63
- category: 'basic' | 'advanced' | 'custom';
64
- scene?: string[];
65
- isCustom?: boolean;
66
- }
67
-
68
- export interface DrawnCard {
69
- cardId: number;
70
- isReversed: boolean;
71
- positionId: number;
72
- }
73
-
74
- export interface DivinationRecord {
75
- id: string;
76
- type: 'tarot' | 'combo' | 'ziwei' | 'bazi' | 'astrology';
77
- question: string;
78
- category: string;
79
- spreadId?: string;
80
- cards?: DrawnCard[];
81
- comboMethod?: string;
82
- comboResult?: string;
83
- interpretation: string;
84
- timestamp: number;
85
- }
86
-
87
- export interface ComboResult {
88
- method: 'xiaoliuren' | 'daliuren' | 'liuyao' | 'meihua' | 'qimen';
89
- methodName: string;
90
- result: string;
91
- detail: string;
92
- relationToTarot: string;
93
- }
94
-
95
- export type QuestionCategory = 'love' | 'career' | 'wealth' | 'health' | 'study' | 'family' | 'friendship' | 'spiritual' | 'travel' | 'general';
96
-
97
- export interface TarotReading {
98
- question: string;
99
- category: QuestionCategory;
100
- spreadId: string;
101
- cards: DrawnCard[];
102
- interpretation: string;
103
- comboResult?: ComboResult;
104
- }
1
+ // 类型桥(单一副本):全部类型收敛于 shared/core/types.ts,此处仅 re-export 保持旧导入路径兼容
2
+ export * from '@core/types';
package/tsconfig.json CHANGED
@@ -16,10 +16,10 @@
16
16
  "moduleDetection": "force",
17
17
  "noEmit": true,
18
18
  "jsx": "react-jsx",
19
- "strict": false,
20
- "noUnusedLocals": false,
21
- "noUnusedParameters": false,
22
- "noFallthroughCasesInSwitch": false,
19
+ "strict": true,
20
+ "noUnusedLocals": true,
21
+ "noUnusedParameters": true,
22
+ "noFallthroughCasesInSwitch": true,
23
23
  "noUncheckedSideEffectImports": false,
24
24
  "forceConsistentCasingInFileNames": false,
25
25
  "ignoreDeprecations": "5.0",
@@ -37,4 +37,4 @@
37
37
  "src",
38
38
  "api"
39
39
  ]
40
- }
40
+ }